previousConditions d'utilisation (Previous) (Next) XML_RSS::XML_RSSnext

View this page in Last updated: Sun, 18 Oct 2009
English | Brazilian Portuguese | Chinese | Dutch | French | German | Hungarian | Japanese | Polish | Russian | Spanish | Turkish

Exemple

Exemple – Exemple d'utilisation de XML_RSS

Exemple d'utilisation

Le script suivant récupère les dernières entrées depuis Slashdot.org via RSS.

Récupération des dernières entrées depuis Slashdot

<?php
require_once "XML/RSS.php";

$rss =& new XML_RSS("http://rss.slashdot.org/Slashdot/slashdot");
$rss->parse();

echo 
"<h1>Entrées depuis <a href=\"http://slashdot.org\">Slashdot</a></h1>\n";
echo 
"<ul>\n";

foreach (
$rss->getItems() as $item) {
    echo 
"<li><a href=\"" $item['link'] . "\">" $item['title'] . "</a></li>\n";
}

echo 
"</ul>\n";
?>
previousConditions d'utilisation (Previous) (Next) XML_RSS::XML_RSSnext

Download Documentation Last updated: Sun, 18 Oct 2009
Do you think that something on this page is wrong? Please file a bug report or add a note.
User Notes:
There are no user contributed notes for this page.