View Single Post
(#13)
bobsmith bobsmith is offline
Junior Member
bobsmith is on a distinguished road
 
Posts: 16
Join Date: Jul 2006
Default 10-11-2006, 12:51 AM

Quote:
Originally Posted by juven14

You might be able to do this:

in your home page:

PHP Code:
require_once('classifiedsdirectory/modules/rss_mod/includes/rss_fetch.inc.php');
require_once(
'classifiedsdirectory/modules/rss_mod/includes/rss_utils.inc.php');
require_once(
'classifiedsdirectory/modules/rss_mod/includes/config.php');

Then where you want to display the feed do something like this (in the same file):

PHP Code:
$url = "somefeedurl.xml";
$rss = fetch_rss( $url );
echo
"Channel: " . $rss->channel['title'] . "<p>";
echo
"<ul>";
foreach (
$rss->items as $item)
{
    
$href = $item['link'];
    
$title = $item['title'];    
    echo
"<li><a href=$href>$title</a></li>";
}
echo
"</ul>";

John, I must be missing something, have tried for an hour and still no luck.

What is $url="somefeedurl.xml" in the above script suppose to be? Is that a custom file XML file I need to set up on my 68C?

Thanks again for all your help.