如何在这些标签中提取字符串?

时间:2013-09-04 07:06:44

标签: android regex replace

我有以下字符串

String text = "<div align="center"><a href="http://www.ndtv.com/news/images/topstory_thumbnail/  Shatrughan_Sinha_agency_120.jpg"><img border="0" src="http://www.ndtv.com/news/images/topstory_thumbnail/Shatrughan_Sinha_agency_120.jpg" alt="2013-07-29-08-43-05" /></a></div><p><span style="font-size: large;">The BJP is likely to anoint Narendra Modi as its prime ministerial candidate for the 2014 elections and make a formal announcement to that effect by September.</span><br /><br /><span style="font-size: large;"> A day after Narendra Modi appeared to declare himself his party's prime ministerial candidate, another initiative by him has not been welcomed by the BJP's Bihar branch.  </span><br /><br /><span style="font-size: large;">BJP President Rajnath Singh today appeared to bat for Gujrat Chief Minister Narendra Modi as the party's Prime Ministerial candidate and said it is now Congress' turn to make clear its choice of its candidate for the top post.    </span><br /><br /></p>";

如何从上面的字符串文本中删除foll字符串?

<div align="center"><a href="http://www.ndtv.com/news/images/topstory_thumbnail/  Shatrughan_Sinha_agency_120.jpg"><img border="0" src="http://www.ndtv.com/news/images/topstory_thumbnail/Shatrughan_Sinha_agency_120.jpg" alt="2013-07-29-08-43-05" /></a></div>

0 个答案:

没有答案