-
Hello,
I recently have been having a big problem with some of my sitemap not preloading for my home page, shop page, product categories, and products, and i was hoping to get some guidance or assistance in troubleshooting. currently if i make any edits to these post types i then have to go an manually open each of these url’s related to cache them
i recently manually created my own sitemap files for products and product categories, because i needed to add hreflang markup to the urls. but, Instead of creating and linking a new sitemap through the guide that i found on your site, i just created a new sitemap file with the same name and placed it in my main directory to overright your files.
This seems to work and is showing in your sitemap tree and the page source markup is the new version, and it is showing in google SC. And, because the home page was affected too, it made me think it might not be related to the sitemaps i created because this should have been normal.
Posts and page post types are ok and dont seem to have the problem.
I was planning to test trying to make a new sitemap just to rule it out, but do you know if this will be the cause, or if there is something else i should look at?
Will the new sitemaps automatically be cleared and preloaded like normal once i set this up? the guide was a little unclear on this and seems to suggest that clearing cache would have to be done with a script?
-
Hello,
I apologize for the issue you are facing with your sitemap preloading in WP Rocket. It seems like you have manually created new sitemap files for products and product categories, which might be causing the preloading issue.
When you manually create sitemap files and overwrite the existing ones, it can lead to caching problems and affect the preloading process. To resolve this issue, I recommend following these steps:
-
Revert to Original Sitemap Files: Instead of overwriting the existing sitemap files, I suggest reverting to the original sitemap files generated by Rank Math. You can follow our guide on how to exclude sitemaps from caching to ensure proper caching settings for your sitemaps.
-
Clear Cache: After reverting to the original sitemap files, make sure to clear the cache in WP Rocket. This will help in preloading the sitemaps correctly.
-
Test with New Sitemap: If the issue persists after reverting to the original sitemap files, you can try creating a new sitemap following our guidelines. However, ensure that you do not overwrite any existing sitemap files this time.
-
Preloading New Sitemaps: Once you set up the new sitemaps correctly, WP Rocket should automatically preload them like normal. Clearing the cache after setting up the new sitemaps should not require a script and can usually be done within the WP Rocket settings.
By following these steps, you should be able to resolve the sitemap preloading issue with WP Rocket. If you need further assistance or encounter any difficulties during the process, feel free to reach out to us for help.
Thank you for bringing this concern to our attention, and we appreciate your patience as we work to resolve this issue for you.
Best regards.
Sources:
Remove Blank Lines From Sitemaps » Rank Math
Rank Math Sitemap Issues and Their Fixes » Rank Math
How to Fix “Incorrect HTTP Header Content-Type” Error in Sitemaps » Rank Math
Why Did My Website Disappear From Google Search? » Rank Mathanother question regarding creating a new sitemap link instead of using the overritten one. I have all of the markup data i want in my sitemap file already, I just need to link it to the rankmath sitemap tree, and also make sure it clears and preloads with wp rocket settings.
this is the turorial i mentioned i found for doing this:
https://rankmath.com/kb/custom-sitemaps/I noticed the scripts look like i have to set out the xml structure for each url again manually. is there a script for just linking to my sitemap file? i use my own XML-creating tool
Kind Regards
Jackhello, thanks for getting back to me and the feedback, it very appreciated. That sounds like it will be the problem then so I will test it tonight.
i cant revert it back until i have the new sitemap created because of the penalties i will get for duplicate pages i think will be bigger than manually caching the pages at the moment.
to make the new sitemap following the steps, do you have an example reference for formatting the label for the php structure to include the following attributes? these weren’t mentioned in the tutorial otherwise the ones mentioned makes sense, but i need at least the hreflang in there to not get hit by SEO duplicate pages
xhtml hreflang
changefreq
priorityRegards
Jackan example url of what im trying to reproduce:
<url><loc>https://petsago.com/pet-shop/en-au/dogs-au/dog-harness-au/dog-harness-heavy-duty-no-pull-no-choke-au/</loc>
<xhtml:link rel=”alternate” hreflang=”en-es” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-au” href=”https://petsago.com/pet-shop/en-au/dogs-au/dog-harness-au/dog-harness-heavy-duty-no-pull-no-choke-au/”/>
<xhtml:link rel=”alternate” hreflang=”en-us” href=”https://petsago.com/pet-shop/en-us/dogs-us/dog-harness-us/dog-harness-heavy-duty-no-pull-no-choke-us/”/>
<xhtml:link rel=”alternate” hreflang=”en-gb” href=”https://petsago.com/pet-shop/en-au/dogs-au/dog-harness-au/dog-harness-heavy-duty-no-pull-no-choke-au/”/>
<xhtml:link rel=”alternate” hreflang=”en-de” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-ie” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-nl” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-it” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-fr” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-pt” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-be” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-cy” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-ee” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-fi” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-gr” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-lv” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-lt” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-lu” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-mt” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-sk” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”en-si” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<xhtml:link rel=”alternate” hreflang=”x-default” href=”https://petsago.com/pet-shop/en-eu/dogs-eu/dog-harness-eu/dog-harness-heavy-duty-no-pull-no-choke-eu/”/>
<lastmod>2024-02-12T08:12:08+00:00</lastmod>
<priority>0.8</priority>
<changefreq>weekly</changefreq>
<image:image><image:title>black dog harness heavy duty no-pull no-choke pet shop</image:title>
<image:caption>black dog harness heavy duty no-pull no-choke from petsago pet shop</image:caption><image:loc>https://petsago.com/wp-content/uploads/2023/11/dog-harness-heavy-duty-no-pull-no-choke-black-petsago-pet-shop.jpg</image:loc></image:image>
<image:image><image:title>blue dog harness heavy duty no-pull no-choke pet shop</image:title>
<image:caption>blue dog harness heavy duty no-pull no-choke from petsago pet shop</image:caption>
<image:loc>https://petsago.com/wp-content/uploads/2023/11/petsago-blue-dog-harness-heavy-duty-no-pull-no-choke.jpg</image:loc></image:image>
<image:image><image:title>green dog harness heavy duty no-pull no-choke pet shop</image:title>
<image:caption>green dog harness heavy duty no-pull no-choke from petsago pet shop</image:caption>
<image:loc>https://petsago.com/wp-content/uploads/2023/11/green-tactical-no-pull-dog-harness-online-pet-shop.jpg</image:loc></image:image>
<image:image><image:title>pink dog harness heavy duty no-pull no-choke pet shop</image:title>
<image:caption>pink dog harness heavy duty no-pull no-choke from petsago pet shop</image:caption>
<image:loc>https://petsago.com/wp-content/uploads/2023/11/dog-harness-heavy-duty-no-pull-no-choke-pink-from-petsago.jpg</image:loc></image:image>
<image:image><image:title>red dog harness heavy duty no-pull no-choke pet shop</image:title>
<image:caption>red dog harness heavy duty no-pull no-choke from petsago pet shop</image:caption>
<image:loc>https://petsago.com/wp-content/uploads/2023/11/tactical-no-pull-no-choke-dog-harness-red-from-petsago.jpg</image:loc></image:image>
<image:image><image:title>orange dog harness heavy duty no-pull no-choke pet shop</image:title>
<image:caption>orange dog harness heavy duty no-pull no-choke from petsago pet shop</image:caption>
<image:loc>https://petsago.com/wp-content/uploads/2023/11/orange-dog-harness-heavy-duty-no-pull-from-petsago-pet-shop.jpg</image:loc></image:image></url>Hi, i was hoping i could get lucky and see if you had time to answer this before the weekend, the above format for the script, is it ok to use these labels for the changefreq and priority? i realise the hreflang is most likely wrong but i haven’t found a reference online yet or in your forums. if you could update it, i would be extremely greatful
If i don’t hear from you before then, have a good weekend and speak soon
Kind Regards
JackHello,
Thank you for contacting Rank Math support, and sorry for the unexpected delays and any inconvenience that might have been caused due to that.
Please note that Rank Math doesn’t handle the hreflang via sitemap as it needs to be defined on the actual page source of every URL. These type of tags is handled by your translation plugin.
If you see any caching issues with your sitemap, please follow the steps below:
1. Flush the Sitemap cache by following this video screencast:
https://i.rankmath.com/pipRDp2. Exclude the Sitemap files of the Rank Math plugin in your caching plugin. The cache could be via a plugin or from the server. For plugins or Cloudflare, please follow this article:
https://rankmath.com/kb/exclude-sitemaps-from-caching/3. Apply the following filter code to your site.
add_filter( 'rank_math/sitemap/enable_caching', '__return_false');Here’s how you can add filter to your WordPress site:https://rankmath.com/kb/wordpress-hooks-actions-filters/
Looking forward to helping you.
Hello,
Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.
If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.
Thank you.
-
The ticket ‘Sitemap preloading issue with wp rocket’ is closed to new replies.