Custom sitemaps are not regenerated.

#1092131
  • Ahmed Elgameel
    Rank Math free

    I use custom sitemaps using the following guide, and it is working as expected.
    https://rankmath.com/kb/custom-sitemaps/

    The only problem that emerged recently is that the cache of the custom sitemaps is not cleared when I click on “Save Changes” on the sitemap settings as before.

    Now, I can’t find a way to clear the cache. When I disable the cache entirely using:
    add_filter(‘rank_math/sitemap/enable_caching’, ‘__return_false’);

    The most updated version is displayed, but when I remove this line again, the old cached sitemap returns. I believe the issue started with the introduction of uing AJAX for saving the settings.

    Can you please fix that asap?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hello,

    We apologize for the issue you are facing with the caching of your custom sitemaps. It seems that the caching behavior is not functioning as expected after saving changes in the sitemap settings.

    To address this, you can try the following steps:

    1. Clear Your Site Cache: If you are using a caching plugin, make sure to clear the cache from that plugin. This often resolves issues with outdated content being displayed.

    2. Check Server-Level Caching: Sometimes server-level caching can interfere with updates. If your hosting provider has caching enabled, you may need to clear that cache as well.

    3. Use the Filter: As you’ve mentioned, using the filter add_filter('rank_math/sitemap/enable_caching', '__return_false'); does show the updated version. You might want to keep this filter temporarily until the issue is resolved.

    4. Check for Plugin Conflicts: There could be a conflict with another plugin that is affecting how the cache is handled. You can use the Health Check plugin to troubleshoot this.

    5. Review AJAX Settings: Since you mentioned that the issue started with AJAX for saving settings, ensure that there are no JavaScript errors in your browser’s console that might be affecting the AJAX functionality.

    If these steps do not resolve the issue, please reply to this ticket with your site URL so we can investigate further. A human agent from our support team will take over and assist you more comprehensively.

    Thank you for bringing this to our attention!

    This is an automated reply from Rank Math Support Bot. Your ticket has been assigned to a human agent and we will get back to you shortly.

    Hello,

    Thank you for your query and we are so sorry about the trouble this must have caused.

    Since the sitemap is still being cached, we recommend keeping the filter code in place and making sure your sitemaps are excluded from any caching plugins as explained here: https://rankmath.com/kb/exclude-sitemaps-from-caching/. Also, please clear any server-level cache that may be storing the old sitemap data.

    This should ensure the most up-to-date version of your custom sitemaps is always displayed.

    Let us know how that goes.

    Looking forward to helping you.

    Hi Jeremy,

    Thank you for your reply.

    I have already done that. The problem is, Rank Math’s sitemap caching is very important to reduce load on server.

    The problem is with Rank Math’s internal sitemap cache, it (no longer) delete custom sitemap cache on saving of sitemap settings like before.

    How to fix that? I don’t want to disable RM’s sitemap cache.

Viewing 3 replies - 1 through 3 (of 3 total)

You must be logged in to reply to this ticket.