RSS Excerpt
-
I’m using the following code to pull the HEADLINES from another blog. I would like to include and excerpt of the blog post as well. Can anyone tell me what to add to the code to get this done?
<?php require_once (ABSPATH . WPINC . '/rss.php'); // insert the feed URL here $rss = @fetch_rss('http://feeds.feedburner.com/blogspot/LTnB'); if ( isset($rss->items) && 0 != count($rss->items) ) { ?> <?php // set the number of items from the feed to display (10) $rss->items = array_slice($rss->items, 0, 6); foreach ($rss->items as $item ) { ?> <a href='<?php echo wp_filter_kses($item['link']); ?>'> <?php echo wp_specialchars($item['title']); ?> </a> <?php } ?> <?php } ?>
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
The topic ‘RSS Excerpt’ is closed to new replies.