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.
__PATCHFILE_FOLLOWS__
diff --git app/code/core/Mage/Sitemap/Model/Sitemap.php app/code/core/Mage/Sitemap/Model/Sitemap.php
index 2213a4f..734bb91 100644
--- app/code/core/Mage/Sitemap/Model/Sitemap.php
+++ app/code/core/Mage/Sitemap/Model/Sitemap.php
@@ -151,11 +151,13 @@ class Mage_Sitemap_Model_Sitemap extends Mage_Core_Model_Abstract
*/
$changefreq = (string)Mage::getStoreConfig('sitemap/category/changefreq', $storeId);
$priority = (string)Mage::getStoreConfig('sitemap/category/priority', $storeId);
+ $urlSuffix = Mage::helper('catalog/category')->getCategoryUrlSuffix($storeId);
+ $urlSuffix = ($urlSuffix) ? '.' . $urlSuffix : '';
$collection = Mage::getResourceModel('sitemap/catalog_category')->getCollection($storeId);
foreach ($collection as $item) {
$xml = sprintf(
'<url><loc>%s</loc><lastmod>%s</lastmod><changefreq>%s</changefreq><priority>%.1f</priority></url>',
- htmlspecialchars($baseUrl . $item->getUrl()),
+ htmlspecialchars($baseUrl . $item->getUrl() . $urlSuffix),
$date,
$changefreq,
$priority
@@ -169,11 +171,13 @@ class Mage_Sitemap_Model_Sitemap extends Mage_Core_Model_Abstract
*/
$changefreq = (string)Mage::getStoreConfig('sitemap/product/changefreq', $storeId);
$priority = (string)Mage::getStoreConfig('sitemap/product/priority', $storeId);
+ $urlSuffix = Mage::helper('catalog/product')->getProductUrlSuffix($storeId);
+ $urlSuffix = ($urlSuffix) ? '.' . $urlSuffix : '';
$collection = Mage::getResourceModel('sitemap/catalog_product')->getCollection($storeId);
foreach ($collection as $item) {
$xml = sprintf(
'<url><loc>%s</loc><lastmod>%s</lastmod><changefreq>%s</changefreq><priority>%.1f</priority></url>',
- htmlspecialchars($baseUrl . $item->getUrl()),
+ htmlspecialchars($baseUrl . $item->getUrl() . $urlSuffix),
$date,
$changefreq,
$priority
Men
toMen's T-Shirts
? If you're disabling a category which holds sub categories then is there even a need to keep that parent category - in this instanceT-Shirts
?www.site.com/men/t-shirt/crew-neck-t-shirts
throw a 404. I have tried this myself and disabled a parent category and the full links still work well.