Jump to Navigation

068 - MagpieRSS

MagpieRSS is a powerful RSS parser written in PHP. It's freely available for download via http://magpierss.source.net/ and
is distributed under the GPL license. MagpieRSS offres develpers an amazingly practical and easy means for retrieving
and rendering RSS feeds, as you'll soon see. In addition, Magpie offers users a number of cool features.

Magpie parses a feed by placing it into an object consisting of four fields: channel, image, items, and textinput.
In turn, channel is an array of associative arrays, while the remaining three are associative arrays.
The following script retrieves the blog.xml feed, outputting it using the print_r() statement.

<?php
require("magpie/magpie.php");
$url = "http://localhost/book/20/blog.xml";
$rss = fetch_rss($url);
print_r($rss);
?>

PHP:


Main menu 2

Story | by Dr. Radut