I'm trying to set up a "News Extra" page in addition to my news blog - to do so I'm bringing together a number of media rss/xml feeds, each in their own cell.
However, some of it just plain isn't working, with what should be a display from one feed simply repeating on other feeds, and also not the full file being displayed.
Here's the page:
http://www.platinax.co.uk/news/extra/
The Security focus cell sometimes shows 1 or 2 stories, or just copies the Reuters - once it actually showed 20 when I mixed the feeds around.
There's also a problem with the Sitepoint and O-Reilly feeds, too.
I think I must be missing something important in the construction of these feeds.
So far I'm simply using the following code:
Code:
<?php
$xmlfile = fopen("http://news.bbc.co.uk/rss/newsonline_uk_edition/business/rss091.xml", "r");
if(!$xmlfile)die("cannot open the xml file");
$readfile = fread($xmlfile ,40000);
$searchfile = eregi("<item>(.*)</item>", $readfile ,$arrayreg);
$filechunks = explode("<item>", $arrayreg[0]);
$count = count($filechunks);
echo "<table class='featuretable2'>";
for($i=1 ; $i<=$count-1 ;$i++)
{
ereg("<title>(.*)</title>",$filechunks[$i], $title);
ereg("<link>(.*)</link>",$filechunks[$i], $links);
echo "<tr><td>";
echo "<a href ='$links[1]'\>$title[1]</a>";
echo "</td></tr>";
}
echo "</table>";
?>
Are there any known problems with bringing multiple feeds together?
I'm really stuck on figuring out why not all feeds are showing, and why almost none are showing their actual full feed of 20 items.
Any pointers most appreciated.