Support » Plugin: Yoast SEO » Sitemap does not include empty taxonomies or categories

  • Resolved adv_user

    (@adv_user)


    I changed it here (From true to false) – lines 71 and 175 – wordpress\wp-content\plugins\wordpress-seo\inc\sitemaps\class-taxonomy-sitemap-provider.php:

    $hide_empty = apply_filters( 'wpseo_sitemap_exclude_empty_terms', false, $taxonomy_names );
    
    $hide_empty = apply_filters( 'wpseo_sitemap_exclude_empty_terms', false, $taxonomy );

    But how do I add this in functions.php from my theme, so I do not miss this change in the next update of the plugin?

    It seems the plugin does not include urls of taxonomies or categories which dont have any posts directly under them.

    Only bottom-level taxonomies and categories which have any post assigned are listed in sitemap.

    There isnt any setting in admin side to make these urls appear either.

    We need to be able to show empty higher level taxonomies/categories in the sitemap. If we can do this through any hooks or modifications which wont go away when the plugin is updated, that also works.

    Because we created a list of 1000 tags that load random posts and we need to include them to optimize SEO, because they are words related to the main content of the site, however in each post we only add 5 keywords so as not to detract from the quality.

    Thanks.

    • This topic was modified 2 years, 7 months ago by adv_user. Reason: Changed (From true to false) - lines 71 and 175 - class-taxonomy-sitemap-provider.php
Viewing 1 replies (of 1 total)
  • Plugin Support benvaassen

    (@benvaassen)

    Hi,

    We’re working on cleaning up these Yoast SEO support forums. Since your thread hasn’t had any activity in the last two weeks, we’ve marked it as resolved.

    Of course, you’re always welcome to open a new topic. We kindly ask you to read this post before doing so.

    Thanks for understanding!

Viewing 1 replies (of 1 total)
  • The topic ‘Sitemap does not include empty taxonomies or categories’ is closed to new replies.