Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]Code: Select all
$body1[1] = "<title>afasfasf</title><link>http://www.kafa.com</link><description>afasfasf</description><category>afafasdf</category><pubDate>Sun, 30 Apr 2006 14:08:53 GMT</pubDate></item>";
echo preg_replace('/<title>(.*?)<\/title><link>(.*?)<\/link><description>(.*?)<\/description><category>(.*?)<\/category><pubDate>(.*?)<\/pubDate><\/item>/i', '$5', $body1[1]);
$body1[1] = "
<title>aalkdfkasflkasklfasfdlsafasfasf</title>
<link>http://www.kafa.com</link>
<description>skafdasfasf.</description>
<category>kweasfasff</category>
<pubDate>Sun, 30 Apr 2006 14:08:53 GMT</pubDate>
</item>";
echo preg_replace('/<title>(.*?)<\/title><link>(.*?)<\/link><description>(.*?)<\/description><category>(.*?)<\/category><pubDate>(.*?)<\/pubDate><\/item>/i', '$5', $body1[1]);feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]