channel->item as $item){
// create variables from the title and description (can also be used for images and links)
$title = $item->title;
$description = $item->description;
// displays the title and description on your website, formatted any way you want
echo '
'.$title.'
'.$description.'
';
}}
?>
http://www.whatdotheyknow.com/body/north_east_lincolnshire_council
# INSTANTIATE CURL.
$curl = curl_init();
# CURL SETTINGS.
curl_setopt($curl, CURLOPT_URL, "http://twitter.com/statuses/user_timeline/122933.rss");
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curl, CURLOPT_CONNECTTIMEOUT, 0);
# GRAB THE XML FILE.
$xmlTwitter = curl_exec($curl);
curl_close($curl);
# SET UP XML OBJECT.
$xmlObjTwitter = simplexml_load_string( $xmlTwitter );
$tempCounter = 0;
foreach ( $xmlObjTwitter -> item as $item )
{
# DISPLAY ONLY 10 ITEMS.
if ( $tempCounter < 11 )
{
echo "
guid}\">{$item -> title}
";
}
$tempCounter += 1;