RSS example from main page

Here is how the RSS feeds are displayed on the main page. Change the title and feed url (first and fourth lines) and use as many times as you want in a page.


= new DOMDocument();
$feed = array();
    foreach (
$rss->getElementsByTagName('item') as $node) {
$item = array ( 
'title' => $node->getElementsByTagName('title')->item(0)->nodeValue,
'desc' => $node->getElementsByTagName('description')->item(0)->nodeValue,
'link' => $node->getElementsByTagName('link')->item(0)->nodeValue,
$limit 5;
$x=0;$x<$limit;$x++) {
$title str_replace(' & '' &amp; '$feed[$x]['title']);
$link $feed[$x]['link'];
$description $feed[$x]['desc'];
'<p><strong><a href="'.$link.'" title="'.$title.'">'.$title.'</a></strong><br />';



Proudly powered by a Text Editor and some Internet Searches.

2021 end of file.