I have generate google sitemap through Magento adminpanel.
I have set Product URL Suffix(html) and Category URL Suffix(html) in the configuration.
This suffix are not showing in sitemap.xml.
It just show like below URL,
www.site.com/men/t-shirt/crew-neck-t-shirts
but its throw 404 with url suffix
And also i have disabled some parent categories, like
-root category
- Men
- T-shirt // i have disable this category
- Crew Neck
- V Neck
So the sitemap generate for the category like this
www.site.com/men/t-shirt/crew-neck
but i need to show like this
www.site.com/men/crew-neck
how to achieve this. I have checked in the following collection
Mage::getResourceModel('sitemap/catalog_category')->getCollection($storeId)
Mage::getResourceModel('sitemap/catalog_product')->getCollection($storeId)
but no luck.
Any suggestions will be appreciated.
Best Answer
To address one of your initial comments:
"I have set Product URL Suffix(html) and Category URL Suffix(html) in the configuration.
This suffix are not showing in sitemap.xml."
We noticed this bug introduced in EE 1.13. We requested a patch and received the following. I don't believe this is EE specific so hopefully it helps a bit. Also, just upgraded a EE 1.12 site to 1.14 and noticed all the .html extension were dropped from sitemap.xml as well. Yes, having .html is old school and really not of any seo value these days but this bug can really suck if it goes unnoticed.
Warning ... I did not look at the referenced file in community. Use this as a guide, do not try to apply the patch blindly to your community store. Or if you do, at least test it very thoroughly before going live.