I am currently working on Simplepie and CakePHP 1.2.x. I have a working code that successfully display xml feeds from different remote sources, a sample can be viewed on my homepage. And, I can’t find how to limit it.
My problem on limiting the rss/xml feeds is extending simplepie up to the view/ of cakephp. At first, I thought I should just do.
$feed->set_item_limit(5);
But, looking closely on the documentation:
http://simplepie.org/wiki/reference/simplepie/set_item_limit#limit
I shouldn’t be doing that. And, I should be working on get_items() instead.
http://simplepie.org/wiki/reference/simplepie/get_items
get_items(0, 5) as $item): ?> <div class="item"> <h2 class="title"><a href="<?php echo $item->get_permalink(); ?>">get_title(); ?></a></h2> get_description(); ?> <small>Posted on get_date('j F Y | g:i a'); ?></small></div>
Hmm.. I am going to find the solution on this problem.

Hi!!
I did it using your second option, here is my code:
$cannabisymas = new SimplePie(‘http://www.cannabisymas.com/blog/?feed=rss2‘);
$cannabisymas->handle_content_type();
foreach ($cannabisymas->get_items(0, 10) as $item)
{
$feed = $item->get_feed();
echo ”;
echo ‘get_permalink() . ‘” target=”_blank”>’ . $item->get_title() . ‘‘;
echo ” . $item->get_date() . ”;
echo ”;
}