Sudipta Som
Sudipta Som

Reputation: 6567

Rss feed in webview in android

I want to show rss feeds of link http://dekora.com/blog/?feed=rss2. I have done it successfully and i am showing it in a list view. But i have one problem in i want to display the element of tag, but here lits of HTML tags are coming. So what should i do for this? Should i replace all the HTML tags or there is any Convenient way to display this tag element. Can i show this tag element in a webview? In iPhone if we put this tag element in webview it shows the things in a good and convenient way. Can any body help?

Upvotes: 6

Views: 1954

Answers (1)

jimmithy
jimmithy

Reputation: 6380

If you just want to display HTML you can look into android.text.Html.

You will need to use a custom adapter so you can control the display of the list view, so when you output the content you can do something like:

lblRSSContent.setText(Html.fromHtml(rssItem.getContent()));

I've noticed that the rss feed you provided also contains images. So you should also look into Html.ImageGetter so you can process and display the images.

Upvotes: 2

Related Questions