Hi

Does anybody on the list know for any more articles on

1.) Creating your own RSS feeds using Coldfusion

And

2.) Displaying RSS feeds from external sources i.e. BBC, I tried the UDF
in the last post but all I was receiving was a blank page ?

I have also tried using another approach based on the article by Pablo
Varando http://tutorial208.easycfm.com/  but am receiving the following
error 

An error occured while Parsing an XML document.  
Content is not allowed in prolog.  
  
The error occurred in \testpages\rss.cfm: line 20
 
18 : <cfscript>
19 :   XMLContent = trim(cfhttp.filecontent);
20 :   XMLContent = XMLParse(XMLContent);
21 : </cfscript> 
22 : 

 

-----Original Message-----
From: Larry Lyons [mailto:[EMAIL PROTECTED] 
Sent: 01 June 2005 21:18
To: CF-Talk
Subject: RSS Feeds

>I've never done RSS Feeds before. Can someone please provide brief 
>details about RSS Feeds. I'll be running this on CF 5.0.
>
>I'll basically be displaying RSS Feeds from a few different sources, NY

>Times etc.
>
>Also can I control how many are displayed per feed? For example I want
>3 from NY times, 2 from Wash Post etc etc..
>
>If anyone has an simple tutorials they've found helpful. 
>
>
>Thanks in advance. 
>
>Ryan

Ryan,

If you're just consuming the RSS feeds, you might want to try this UDF:
http://www.cflib.org/udf.cfm?ID=813
TranslateRSSItems(rssDoc)
Description
Takes a RSS feed from Blogger, Slashdot, ZDNet, etc and translates into
a CF query. Based on the function TranslateMacromediaResourceFeed by
Jeffry Houser ([EMAIL PROTECTED]).

Returns a query.

Example

<cfhttp url="http://pro.blogger.com/docs/example_rss.xml"; 
        method="GET" 
        resolveurl="true" 
        timeout="6000">
<cfif cfhttp.fileContent is not "Connection Failure">
   <cfset rssFeed = TranslateRSSItems(cfhttp.FileContent)>
   <cfloop query="rssFeed">
      <!-- only output at most 5 rows --->
      <cfif currentRow lte 5>
         <cfoutput>
            <p><a href="#link#">#title#</a><br>#description#</p>
         </cfoutput>
      <cfelse>
         <cfbreak>
      </cfif>
   </cfloop>
</cfif> 



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble 
Ticket application

http://www.houseoffusion.com/banners/view.cfm?bannerid=48

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:208328
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to