include('header.php');
define('MAGPIE_CACHE_DIR', 'cache');
define('MAGPIE_CACHE_AGE', '600');
require_once('rss_fetch.inc');
$url = 'http://www.spiegel.de/politik/deutschland/index.rss';
if ( $url ) {
$num_items = 15;
$rss = fetch_rss( $url );
$items = array_slice($rss->items, 0,$num_items);
}
echo "
Deutschland Nachrichten
\n";
$ptitle=$rss->channel['title'];
$jetzt=date("d. M. Y");
foreach ($items as $item) {
$href = $item['link'];
$item['pubdate'] = date('d.m.Y, H:i', strtotime($item['pubdate']));
$pubdate = $item['pubdate'];
$newstitle = $item['title'];
$newstitle=utf8_encode($newstitle);
$content=$item['content']['encoded'];
$content=utf8_encode($content);
#$pubdate=utf8_encode($pubdate);
echo "\n";
echo "$pubdate Uhr\n";
echo "
$content
\n";
echo "
\n";
}
echo "© $ptitle - $jetzt
\n";
include('footer.php'); ?>