Typo Google Sitemap fix
Posted by Max Dunn Tue, 16 Jan 2007 16:59:00 GMT
I guess Google used to be more lenient in the format of their Sitemaps. However, when I installed Typo 4.0.3 and submitted a sitemap, Google didn’t like the format.
The format of the Google Sitemap is straightforward:
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.google.com/schemas/sitemap/0.84">
<url>
<loc>http://www.example.com/</loc>
<lastmod>2005-01-01</lastmod>
<changefreq>monthly</changefreq>
<priority>0.8</priority>
</url>
</urlset> However, Typo 4.0.3 and Typo edge (as of 15-Jan-2007) both used “item” instead of “url” and “link” instead of “loc”.
Luckily the fix is easy. Edit all 4 _googlesitemap_item_*.rxml files in /app/views/xml and change “xm.item” to “xm.url” and “xm.link” to “xm.loc”. For instance, _googlesitemap_item_article.rxml will look like:
xm.url do
xm.loc post_link(item)
xm.lastmod item.updated_at.xmlschema
xm.priority 0.8
endNow make similar changes to the other 3 files. When done, go into Typo Admin, Settings, Cache and select “Rebuild cached HTML”. Now you can submit a sitemap like http://blog.maxdunn.com/sitemap.xml to Google Sitemaps and it will work!
I think thats a pretty smart way of submitting a sitemap but it seems Like G no longer needs you to submit this as their web spiders have gotten so advanced they seem to know how to best crawl without it.
Hello there,
I’m running Typo 5.1.3 and it’s fixed now. Hope this late post would be helpful for someone :)
I agree that there is no need to submit a sitemap manually anymore, however this may depend on how often your site gets crawled by Google in the first place. If you have a smaller site, manual submissions will help speed up the process.
I’m also running Typo and think this would help. What gets me is site maps aren’t as important as they once were. What is important are page rankings and behind-the-scenes coding practices.