1) Я делаю приложение RSS Feed в Android. Таким образом, на некоторых сайтах недостаточно данных в теге description в XML, но есть тег <link>
, который содержит все данные этой статьи. Итак, как читать данные из этого тега ссылки.
http://news.yahoo.com/rss/us
<item>
<title>
Police hold off on eviction of Los Angeles Occupy camp
</title>
<description>
<p><a href="http://news.yahoo.com/occupy-la-campers-brace-midnight-eviction-deadline-062954673.html"><img src="http://l2.yimg.com/bt/api/res/1.2/Tjy1MjbTLRHaXzGH5HEznA--/YXBwaWQ9eW5ld3M7Zmk9ZmlsbDtoPTg2O3E9ODU7dz0xMzA-/http://media.zenfs.com/en_us/News/Reuters/2011-11-28T230234Z_1_BTRE7AR1S0D00_RTROPTP_2_USA-PROTESTS.JPG" alt="photo" align="left" title="The Occupy Los Angeles encampment at City Hall Park is seen before the midnight deadline for eviction from City Hall Park passes in Los Angeles" border="0" /></a>LOS ANGELES (Reuters) - Police in riot gear closed in before dawn on Monday on anti-Wall Street activists in Los Angeles who defied a midnight deadline to vacate a camp outside City Hall, but stopped short of clearing the encampment. Police managed to reopen blocked streets for morning rush-hour commuters after a tense standoff with protesters who had taken over a downtown intersection, but remnants of a crowd that had swelled to 2,000 overnight remained at City Hall. ...</p><br clear="all"/>
</description>
<link>
http://news.yahoo.com/occupy-la-campers-brace-midnight-eviction-deadline-062954673.html
</link>
В ссылке выше вся информация находится в теге ссылки.
2) Я могу отобразить одно изображение в приложении Feed из src в описании. Но как я могу показать более двух изображений? Я имею в виду, как я могу сохранить ссылку на изображение в массиве из тега <description>
?
http://feeds.feedburner.com/GameProVideoGameAnalysisNews?format=xml
<description><p>Projections for 2011 make it look like Nintendo and Sony's handhelds together won't be able to touch the mobile phone market.</p><p>
<div class="inlineImage center" style="width:590px;">
<img src="http://cdn1.gamepro.com/article_img/gamepro/51225-224881-1.jpg?rand=D2B74567-BA30-957E-4B59D7FA5F9913FC" alt="Nintendo 3DS Continues To Lose " />
</div>
</p>
<p>It's no secret that mobile phone gaming has seen a meteoric rise over the last few years, but it looks like the software sales trends are finally following suit. The chart above paints a pretty clear picture of Nintendo and Sony's loosening hold on portable game sales, and <a href="http://blog.flurry.com/bid/77424/Is-it-Game-Over-for-Nintendo-DS-and-Sony-PSP">Flurry Analytics</a> expects their share to fall to less than 50% by the end of the year.</p>
<p>While Sony's fortunes are expected to change somewhat with Vita's release next year, it looks like gamers are sending a pretty clear message on where they want to spend their gaming dollars.</p><img src="http://feeds.feedburner.com/~r/GameProVideoGameAnalysisNews/~4/hc6MxVcn7T8" height="1" width="1"/></description>
Я могу прочитать первый src img из описания, но как я могу прочитать все src img из описания ..