<?php
/*
Here, we'll loop through all of the items in the feed, and $item represents the current item in the loop.
*/
$newscount = 0;
foreach ($news->get_items() as $item):
{
if ($newscount < 5)
{
?>
<div>
<h3><a href="<?php echo $item->get_permalink(); ?>"target="_blank"><?php echo $item->get_title(); ?></a></h3>
<p><?php echo $item->get_date('j M Y | g:i a T'); ?></p>
<p><?php echo $item->get_description(); ?></p>
<p></p>
<div class="break"> </div>
</div>
<?php
$newscount++;
}
else
{
break;
}
}
?>
<?php endforeach; ?>