Warning

 

Close

Confirm Action

Are you sure you wish to do this?

Confirm Cancel
BCM
User Panel

Site Notices
Posted: 4/7/2006 9:10:58 PM EDT
I've written a groovy program in C++ to import a text file and turn it into a stream of RSS feeds. However, I don't know how to test it. I don't have anyplace to host the feed itself and was wondering if there was a way to read the .rss file from a location on my hard drive?

I'm trying to use the SAGE extension for FireFox but I can't seem to figure it out.
Link Posted: 4/7/2006 9:24:47 PM EDT
[#1]
Just make a simple HTML document and embed the RSS file into it by putting this tag in the <head>

<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="path/to/feed.xml" />
Link Posted: 4/7/2006 9:30:18 PM EDT
[#2]

Quoted:
Just make a simple HTML document and embed the RSS file into it by putting this tag in the <head>

<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="path/to/feed.xml" />



Path isn't working for some reason. I haven't used HTML in ages.

ETA: Yes, I changed the href to the file location.

Any other ideas?
Link Posted: 4/7/2006 9:42:12 PM EDT
[#3]
Try pasting this into a blank file:

<html>
 <head>
   <title>RSS Feed Test</title>
   <link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="path/to/feed.xml" />
 </head>
 <body>
   Nothing to see here...
 </body>
</html>

ETA: For the path, just make sure the feed is in the same directory as the html file and put just the filename in there.
Link Posted: 4/7/2006 9:45:22 PM EDT
[#4]

Quoted:
Try pasting this into a blank file:

<html>
 <head>
   <title>RSS Feed Test</title>
   <link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="path/to/feed.xml" />
 </head>
 <body>
   Nothing to see here...
 </body>
</html>



Hmm, tried it and no luck. Could be my actual RSS feed creator is shot.

Here's what it's outputting though:


<?xml version="1.0" encoding="UTF-8"?>
   <rss version="2.0">
<channel>
<title>TLC News</title>
<link>http://tlc.discovery.com/news/news.html</link>
<description>Get the latest news and information on attractions, developments, trends, sites and events worldwide.</description>
</channel>
<item>
<title>Laser Makes Solids Transparent</title>
<link>http://tlc.discovery.com/news/afp/20060320/laser.html?source=rss</link>
<description>The beam of light could some day help see through rubble or body parts.</description>
Fri, Mar 24, 2006 15:56
</item>
<item>
<title>Pocket Printer Handles Email</title>
<link>http://tlc.discovery.com/news/afp/20060320/printer.html?source=rss</link>
<description>The mobile-phone-sized printer spits out messages for the technophobe or the email-obsessed.</description>
Thu, Mar 23, 2006 15:56
</item>
<item>
<title>Malaysian Makes Hissstory with Snake-Kissing</title>
<link>http://tlc.discovery.com/news/afp/20060320/snake.html?source=rss</link>
<description>A snake farm worker may have set a new world record after kissing a poisonous snake 51 times in three minutes.</description>
Mon, Mar 20, 2006 17:05
</item>
<item>
<title>Many Irish Names Not so Irish?</title>
<link>http://tlc.discovery.com/news/afp/20060313/irishname.html?source=rss</link>
<description>The English and the Normans, who invaded Ireland, led to radical changes in the way Irish families named kids.</description>
Wed, Mar 15, 2006 17:05
</item>
</rss>
Link Posted: 4/7/2006 9:53:19 PM EDT
[#5]
It appears your XML is for not formatted to the RSS 2.0 spec.

All of the Item nodes should be child nodes of the channel node.

Here is an example RSS 2.0 doc.

www.rssboard.org/files/sample-rss-2.xml

Here's the spec.

www.rssboard.org/rss-specification
Close Join Our Mail List to Stay Up To Date! Win a FREE Membership!

Sign up for the ARFCOM weekly newsletter and be entered to win a free ARFCOM membership. One new winner* is announced every week!

You will receive an email every Friday morning featuring the latest chatter from the hottest topics, breaking news surrounding legislation, as well as exclusive deals only available to ARFCOM email subscribers.


By signing up you agree to our User Agreement. *Must have a registered ARFCOM account to win.
Top Top