Aggregate multiple feeds, order by date, with PHP

Has anyone had any experience / done any experimenting aggregatng mutiple feeds and ordering them by date, using php and without using a database?

I’m playing with MagpieRSS atm, and it’s an awesome tool that does a really good job, and was wondering whether anyone else has done anything similiar with it?
I’ve also started playing with Feeds on Feeds, which is also pretty cool, but it uses a DB so not ideal…

Any thoughts, directions or help would be much apprecited ;-)

9 Responses to “Aggregate multiple feeds, order by date, with PHP”


  1. 1 Peter Nixey

    Hi Gareth,
    I’m using magpie but have only got as far as playiing with it so far. I’m not using its caching though, I’m putting straight back into a DB…

  2. 2 Gareth Knight

    Thanks Peter ;-)

    See, the problem I can see with using a DB for the purpose that I have (only need to see current feed, not archived feeds) is that you end up populating a DB unnecessarily. I spose you could go back and delete rows based on a time criteria, but that’s not really solving the problem but just working around it…

  3. 3 Gareth Knight

    Wikipedia has quite a list of RSS aggregators, here:
    http://en.wikipedia.org/wiki/List_of_news_aggregators

  4. 4 Gesslar

    I’m looking to do exactly this, if you find out, please let me know.

  5. 5 Gareth Knight

    Will do - should be posting something soon on this blog if I get it to work the way I want it to…

  6. 6 Craig (mars-hill)

    Hey,

    I’ve used magpie to bring feeds to my homepage, but am not having much luck in creating a “master feed” of all my content (which is my next goal).

    If you have any luck I’d be thankful to hear about it. Cheers!

  7. 7 Gareth Knight

    Will do Craig ;-)

  8. 8 EH

    Howto sort by date

    1. Get feed into array using magpie
    2. write sort compare function. This compares timestamps!
    3. use php usort with custom compare function
    4. Loop array and display.

    Worked for me, but tricky!

  9. 9 Anthony

    EH could you share your source with us, as I am also looking to do this very thing. If possible, perhaps e-mail me at asgentile@gmail.com. Thanks

Leave a Reply