开发者

php - quick help needed with preg_replace

I'm parsing rss feeds however some feeds have what look to be blank images in them (from feedburner). Can somewhere help me out with a preg_replace command 开发者_如何学编程to find and remove an image tag structured like:

<img src="http://feeds.feedburner.com/sdfasdfsfd" height="1" width="1"/>

Thanks!


I guess the "sdfasdfsfd" is something random:

$text = preg_replace( '#<img src="http://feeds.feedburner.com/[a-z]+" height="1" width="1"/>#i', '', $text );
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜