• Post Reply Bookmark Topic Watch Topic
  • New Topic

Rss Feed in jsp  RSS feed

Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
friends pls.. help me out regarding Rss feed

i was tried a simple example to retrive data from the given rss feed by a news site by using console application but iam unable to run it
it is compiled successfully. while running the program it is showing the following error.

C:\Rssfeed>java testfeed
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/lo
at de.nava.informa.utils.FormatDetector.<clinit>(FormatDetector.java:50)

at testfeed.main(testfeed.java:15)

it is giving error in the informa package class..

plss... help me out...

my code is as follows

import de.nava.informa.core.*;
import de.nava.informa.utils.*;
import de.nava.informa.impl.basic.*;
import de.nava.informa.utils.*;
import de.nava.informa.utils.FormatDetector;
import java.io.*;
import java.net.*;
import java.util.*;
public class testfeed
public static void main(String args[])
try {
URL feed = new URL("file:/C:/Rssfeed/testfeed.rss");
ChannelFormat format = FormatDetector.getFormat(feed);
ChannelParserCollection parsers = ChannelParserCollection.getInstance();

ChannelParserIF parser = parsers.getParser(format, feed);

parser.setBuilder(new ChannelBuilder());
ChannelIF channel = parser.parse();

for (Iterator iter = channel.getItems().iterator(); iter.hasNext();)
ItemIF item = (ItemIF)iter.next();
} catch (MalformedURLException mue)
catch (UnsupportedFormatException ufe)
catch (ParseException pe)
catch(Exception e)


<?xml version="1.0"? >
<!-- The version of RSS we are using -->
<rss version="0.91">
<!-- Information about our channel -->
<title>Random News</title>
Random news from the random news website!
<copyright>Copyright: (C) 2003 Random News.com</copyright>

<title>Random News Logo</title>
<link> http://randomnews.org/</link>

<title>News piece one</title>

<title>News piece two</title>
I love a good mentalist. And so does this tiny ad:
Rocket Oven Kickstarter - from the trailboss
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!