• Resolved whitehumorous

    (@whitehumorous)


    Hi, thanks for your great plugin and much appreciated. Recently I need a sitemap to let the crawler to crawl the latest post type page whenever the server cache is refreshed, and I would like to make use of Yoast’s sitemap. However I found out that the sitemap for post type is ordered by modified date in ascending order, based on the 2 lines in the file “class-post-type-sitemap-provider.php” below:

    ORDER BY post_modified_gmt ASC

    ORDER BY {$wpdb->posts}.post_modified ASC LIMIT %d OFFSET %d

    I can directly edit the file, but since the update frequency of Yoast is quite often, may I know is there any filter so that I can change the order from ASC to DESC?

    Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Maybellyne

    (@maybellyne)

    Hello @whitehumorous

    Thanks for reaching out regarding your sitemap.

    We don’t have a filter to sort the order in which URLs are diplayed in the XML sitemap. But of course, you’re free to customize the Yoast SEO plugin to suit your needs.

    And in addition, the ordering is not particularly important as far as Google is concerned; XML sitemaps are not crawled or processed in the same way as conventional URLs or pages.

    Plugin Support Maybellyne

    (@maybellyne)

    This thread was marked resolved due to a lack of activity, but you’re always welcome to re-open the topic. Please read this post before opening a new request.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘XML sitemaps order sorting’ is closed to new replies.