When trying to display an RSS feed I am getting the following error

An error occured while Parsing an XML document.  
Content is not allowed in prolog.  

I am using CFMX 7 enterprise, any ideas on what is causing this error?

------------code-------------
<cfscript>
  URLToPull  = "http://www.easycfm.com/syndication/mostviewed.cfm";;
</cfscript> 

<cfhttp url="#URLToPull#"
           method="GET"
           timeout="15">
</cfhttp> 
<cfscript>
  XMLContent = trim(cfhttp.filecontent);
  XMLContent = XMLParse(XMLContent);
</cfscript> 
</head>

<body>
<cfoutput>
    Feed provided by:<BR>
    <a href="#XMLContent.rss.channel.image.link.xmlText#">
       <img src="#XMLContent.rss.channel.image.url.xmlText#"
alt="#XMLContent.rss.channel.image.title.xmlText#" border="0">
    </a><br>
    #XMLContent.rss.channel.title.xmlText#<BR>
    #XMLContent.rss.channel.description.xmlText#<BR><BR>
</cfoutput>     

<cfloop from="1" to="#ArrayLen(XMLContent.rss.channel.item)#"
index="idx">
 <hr>
 <cfoutput>
 <a
href="#XMLContent.rss.channel.item[idx].link.xmlText#">#XMLContent.rss.c
hannel.item[idx].title.xmlText#</a><BR>
 
#ParagraphFormat(ReplaceNoCase(XMLContent.rss.channel.item[idx].descript
ion.xmlText, "&lt;", "<", "ALL"))#
 Author: #XMLContent.rss.channel.item[idx].author.xmlText#<BR>
 Date: #XMLContent.rss.channel.item[idx].pubDate.xmlText#
 </cfoutput>
</cfloop> 
<HR>
<cfoutput><div
align="center">#XMLContent.rss.channel.copyright.xmlText#</div></cfoutpu
t> 

----------------------------


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four 
times a year.
http://www.fusionauthority.com/quarterly

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:250435
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to