Новините за спорт и футбол2020-08-02T14:45:40+00:00
Loading...

Избрано

load($url); $arrFeeds = array(); foreach ($doc->getElementsByTagName('item') as $node) { $itemRSS = array ( 'title'=>$node->getElementsByTagName('title')->item(0)->nodeValue, 'desc' =>$node->getElementsByTagName('description')->item(0)->nodeValue, 'link' =>$node->getElementsByTagName('link')->item(0)->nodeValue, 'date' =>$node->getElementsByTagName('pubDate')->item(0)->nodeValue, ); array_push($arrFeeds, $itemRSS); } $feedLimit=0; $feedCount=0; foreach($arrFeeds as $oneItem){ # foreach($oneItem as $key=>$value){$oneItem[$key]=iconv('utf-8','cp1251',$value);} $feedCount++; print '

'.$oneItem['title'].'

'; print '

'.$oneItem['desc'].'

'; print '
'; if($feedLimit>0 && $feedCount>=$feedLimit) break; }