Skip to:
Content
Pages
Categories
Search
Top
Bottom

How to Show Last Ten Posts in Sidebar?

  • @bbisimone

    Member

    I’m trying to show the last ten posts in my sidebar, but I am not entirely succeeding, what am I doing wrong? I thought I’d just need to adjust the code from latest discussion a bit. Obviously it doesn’t work like that.

    <table class="recent_posts" cellspacing="0" width="100%">
    <?php if ( $topics ) : foreach ( $topics as $topic ) : ?>
    <tr<?php topic_class(); ?>>
    <td><?php bb_topic_labels(); ?> <a href="<?php topic_link(); ?>"><?php topic_title(); ?></a></td>
    <td><small><a href="<?php topic_last_post_link(); ?>"><?php topic_time(); ?></a></small></td>
    </tr>
    <?php endforeach; endif; // $topics ?>
    </table>

    So how can I call the latest ten posts in the sidebar?

Viewing 8 replies - 1 through 8 (of 8 total)
Viewing 8 replies - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.
Skip to toolbar