Rewritten IndexSitemap and Sitemap code fully tested