0
我正在使用Simple Pie顯示來自多個RSS源的內容。在SimplePie中顯示Feed標題
我已成功顯示RSS源的內容。我現在想要的是顯示作者姓名或飼料標題。
實施例:
這是RSS頻道URL:http://aaron.dietfreelife.com/feed/
我希望能夠檢索提要標題所示附接的圖中
這裏是我的代碼規格:
<?php
foreach ($feed->get_items() as $item):
?>
<div class="item">
<h2><a href="<?php echo $item->get_permalink(); ?>"><?php echo $item->get_title(); ?></a></h2>
<p><?php echo $item->get_description(); ?></p>
<p><small>Posted on <?php echo $item->get_date('j F Y | g:i a'); ?></small></p>
</div>
<?php endforeach; ?>
任何幫助將不勝感激....
嗨Revent,非常感謝。是的,你的代碼完美地工作......接受解決方案... – mkb
但是,如果我們不希望它在循環但在上面? – Gino