I setup an rss feed for one of my weblogs. I copied and pasted the feed template because I don’t know anything about rss. When I view the page in Safari with the error console on, I get the following error:
<head> must be a child of <html>. Content ignored.
The page validates using the w3 validator http://validator.w3.org/feed/, and it seems to display okay but sometimes I get a blank screen and I have to reload the page. I’m not sure what’s going on. Here is a link to the page:
http://posustainableseafood.com/index.php/rss
Here’s my template:
{preload_replace:master_channel_name="news"}
{exp:rss:feed channel="{master_channel_name}"}
<?xml version="1.0" encoding="{encoding}"?>
<rss version="2.0"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
xmlns:admin="http://webns.net/mvcb/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
<title><![CDATA[{channel_name}]]></title>
<link>{channel_url}</link>
<description>{channel_description}</description>
<dc:language>{channel_language}</dc:language>
<dc:creator>{email}</dc:creator>
<dc:rights>Copyright {gmt_date format="%Y"}</dc:rights>
<dc:date>{gmt_date format="%Y-%m-%dT%H:%i:%s%Q"}</dc:date>
<admin:generatorAgent rdf:resource="http://expressionengine.com/" >
<atom:link href="http://posustainableseafood.com/index.php/rss" rel="self" type="application/rss+xml" >
{exp:channel:entries channel="{master_channel_name}" limit="10" dynamic_start="on" disable="member_data|pagination"}
<item>
<title><![CDATA[{title}]]></title>
<link>{title_permalink='site/index'}</link>
<guid>{title_permalink='site/index'}#When:{gmt_entry_date format="%H:%i:%sZ"}</guid>
<description><![CDATA[{summary}{body}]]></description>
<dc:subject><![CDATA[{categories backspace="1"}{category_name}, {/categories}]]></dc:subject>
<dc:date>{gmt_entry_date format="%Y-%m-%dT%H:%i:%s%Q"}</dc:date>
</item>
{/exp:channel:entries}
</channel>
</rss>
{/exp:rss:feed}Thanks for your help,
Troy