skip to Main Content

Printing out feeds on your wordpress site


<?php

include_once(ABSPATH.WPINC.'/feed.php');
$rss = fetch_feed('http://ransomedheart.com/daily-reading/feed');
$maxitems = $rss->get_item_quantity(5);
$rss_items = $rss->get_items(0, $maxitems);

?>
<?php if ($maxitems == 0) echo '<li>No items.</li>';
else
// Loop through each feed item and display each item as a hyperlink.
foreach ( $rss_items as $item ) : ?>

<div class="sidebar-box widget_bp_groups_widget buddypress widget" id="bp_groups_widget-2">

<div class="sidebar-title">
<img src="https://www.ransomedheart.com/sites/all/themes/pixture_reloaded/images/rh-logo.png" style="margin:0 auto;width:100%;" />
<cufon class="cufon cufon-canvas" alt="<?php echo $item->get_title();?>" style="width: 121px; height: 26px;"><canvas width="136" height="26" style="width: 136px; height: 26px; top: 0px; left: -1px;"></canvas><cufontext><?php echo $item->get_title();?></cufontext></cufon>

</div>
<div class="sidebar-box-child" />

<?php
echo $item->get_description(); ?>
</div>
<?php
break;
endforeach; ?>

</div>
<?php

?>

Alphonse

Editorial Staff at ETN Multimedia is led by Alphonse Tan. Page maintained by Alphonse Tan

Back To Top