tags:

views:

35

answers:

1

Hello,

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!

+4  A: 

I guess the "sdfasdfsfd" is something random:

$text = preg_replace( '#<img src="http://feeds.feedburner.com/[a-z]+" height="1" width="1"/>#i', '', $text );
poke
that did the trick! thanks
Joe