Neuigkeiten

News

‚242238246296552‘,
’secret‘ => ‚4fa29a82755eb983ec55c6de0b3c83a3‘
));
$rawFeed = $fb->api($url);
$feed = array();
foreach($rawFeed[‚data‘] as $item) {
$title = false;
if($title === false && isset($item[’story‘]) && !empty($item[’story‘])) {
$title = $item[’story‘];
}
if($title === false && isset($item[‚message‘]) && !empty($item[‚message‘])) {
$title = $item[‚message‘];
}
$image = false;
if($image === false && isset($item[‚picture‘]) && !empty($item[‚picture‘])) {
$image = $item[‚picture‘];
}
$link = false;
if($link === false && isset($item[‚link‘]) && !empty($item[‚link‘])) {
$link = $item[‚link‘];
}
$updated_time = false;
if($updated_time === false && isset($item[‚updated_time‘]) && !empty($item[‚updated_time‘])) {
$updated_time = $item[‚updated_time‘];
}
$feed[] = array(
‚title‘ => $title,
‚link‘ => $link,
‚image‘ => $image,
‚updated_time‘ => $updated_time
);
}
file_put_contents($cacheName, json_encode($feed));
} else {
$feed = json_decode(file_get_contents($cacheName), true);
}
foreach($feed as $item) {
?>