Sitemap CGBlog - error unknown tag "CGBlog [solved]
Posted: Wed Oct 09, 2013 1:01 pm
Hi
I m trying to use sitemapmadesimple to generate an xml file. But I need it to include articles from both the news and CGBlog.
I tried this method http://forum.cmsmadesimple.org/viewtopi ... og#p292142
Using this code:
I also tried using:
Both returned similar errors as below:
This error seems to be a fatal if I make the tempalte the default and I have to uninstall sitemapmadesimple, to get rid of the error.
Anybody come across this, any remedies?
I m trying to use sitemapmadesimple to generate an xml file. But I need it to include articles from both the news and CGBlog.
I tried this method http://forum.cmsmadesimple.org/viewtopi ... og#p292142
Using this code:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
{* Note: Web crawlers usually discover pages from links within the site and from other sites. Sitemaps supplement this data to allow crawlers that support Sitemaps to pick up all URLs in the Sitemap and learn about those URLs using the associated metadata. It is not strictly necessary to use a sitemap on a well designed site. This is just an aide to the web crawlers in finding data from your website. *}
<urlset xmlns="http://www.google.com/schemas/sitemap/0.9"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.google.com/schemas/sitemap/0.9
http://www.google.com/schemas/sitemap/0.9/sitemap.xsd">
{strip}
{foreach from=$output item='page'}
<url>
<loc>{$page->url}</loc>
<lastmod>{$page->date|date_format:"%Y-%m-%d"}</lastmod>
<priority>{$page->priority}</priority>
<changefreq>{$page->frequency}</changefreq>
</url>
{/foreach}
{assign var='foo' value=$mod}{CGBlog detailpage='projects' assign='junk2'}{assign var=mod value=$foo}
{foreach from=$items item=entry}
<url>
<loc>{$entry->detail_url}</loc>
<lastmod>{$entry->postdate|date_format:"%Y-%m-%d"}</lastmod>
<priority>{$page->priority}</priority>
<changefreq>{$page->frequency}</changefreq>
</url>
{/foreach}
{/strip}
</urlset>Code: Select all
{news number=1000 detailpage='news-detail' assign='junk'}
{foreach from=$items item=entry}
<url>
<loc>{$entry->moreurl}/d,McFTDetail</loc>
<lastmod>{$entry->postdate|date_format:"%Y-%m-%d"}</lastmod>
<priority>{$page->priority}</priority>
<changefreq>{$page->frequency}</changefreq>
</url>
{/foreach}Code: Select all
Syntax Error in template "module_db_tpl:SiteMapMadeSimple;xml_cpesitemap" on line 22 "{assign var='foo' value=$mod}{CGBlog detailpage='projects' assign='junk2'}{assign var=mod value=$foo}" unknown tag "CGBlog"Anybody come across this, any remedies?