czheng
-
Posts
2 -
Joined
-
Last visited
Never
Posts posted by czheng
-
-
Hey folks. Newcomer here.
I've spent the last few days modifying an RSS Reader script I downloaded somewhere, and I've got it running almost exactly how I'd like it. The last thing I'd like to do is, for the following feed([url=http://ma.gnolia.com/rss/full/people/czheng]http://ma.gnolia.com/rss/full/people/czheng[/url]), remove from each ITEM everything from (and including) [code]<b>Tags:[/code] up to (but not including) [code]<description>[/code].
I'm guessing it would be something like: [code]$rss_feed = preg_replace('**what goes here?**', '', $rss_feed);[/code]
but of course I need the pattern.
Thanks in advance if anyone can help.
P.S. How might I also strip out all the following tags? [code]<b></b><p></p>[/code]
FYI, I looked at this thread ([url=http://www.phpfreaks.com/forums/index.php/topic,99383.0.html]http://www.phpfreaks.com/forums/index.php/topic,99383.0.html[/url]) but it didn't get me the result I wanted...
Weeding out part of an RSS feed
in Regex Help
Posted
[code] $rss_feed = preg_replace("#Tags:(.*?)(?=<\/description>)#", "", $rss_feed);
[/code]
And I wasn't able to remove the (p) and (b) tags without decoding the HTML. Once I did that, everything was set.
Thanks again.