Ec (2); simpleXML is a new feature of php5. RSS is now popular. Here is a simple demonstration to get the RSS of php.net. Copy the content to the clipboard code: & lt ;? & Nbsp; $ cache & quot; phpnews. xml & quot; & nbsp; $ rssurl & quot; www. php. netnews. rss & quot; & script ec (2); script
SimpleXML is a new feature of php5.
RSSIt is now quite popular. Here is a simple demonstration to get the php.net
RSS.
Copy the content to the clipboard code:
$cache="phpnews.xml";
$rssurl="http://www.php.net/news.rss";
header("content-type:text/html;charset=utf-8");
if( file_exists("$cache") )
{
$m=filemtime("$cache");
$n=time();
if($n-$m>10800)
{
$rss=simplexml_load_file("$rssurl");
$rss->asXML("$cache");
}
else
$rss=simplexml_load_file("$cache");
}
else
{
$rss=simplexml_load_file("$rssurl");
$rss->asXML("$cache");
}
foreach($rss->item as $item)
print "link" target=_blank> $item->title
n";
?>
<