[英]Rss feed in webview in android
I want to show rss feeds of link http://dekora.com/blog/?feed=rss2 .我想显示链接http://dekora.com/blog/?feed=rss2的 rss 提要。 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.
但是我有一个问题,我想显示标签的元素,但是这里 HTML 标签的灯即将到来。 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.
我应该替换所有 HTML 标签还是有任何方便的方法来显示这个标签元素。 Can i show this tag element in a webview?
我可以在 webview 中显示此标签元素吗? In iPhone if we put this tag element in webview it shows the things in a good and convenient way.
在 iPhone 中,如果我们将这个标签元素放在 webview 中,它会以一种很好且方便的方式显示事物。 Can any body help?
任何身体都可以帮忙吗?
If you just want to display HTML you can look into android.text.Html .如果您只想显示 HTML 您可以查看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:您将需要使用自定义适配器,以便控制列表视图的显示,因此当您使用 output 内容时,您可以执行以下操作:
lblRSSContent.setText(Html.fromHtml(rssItem.getContent()));
I've noticed that the rss feed you provided also contains images.我注意到您提供的 RSS 提要也包含图像。 So you should also look into Html.ImageGetter so you can process and display the images.
因此,您还应该查看Html.ImageGetter以便您可以处理和显示图像。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.