// This is the "Recent Posts" bar.
if (!empty($settings['number_recent_posts']))
{
echo '
|
';
// Only show one post.
if ($settings['number_recent_posts'] == 1)
{
// latest_post has link, href, time, subject, short_subject (shortened with...), and topic. (its id.)
echo '
', $txt[214], '
', $txt[234], ' "', $context['latest_post']['link'], '" ', $txt[235], ' (', $context['latest_post']['time'], ')
';
}
// Show lots of posts.
elseif (!empty($context['latest_posts']))
{
echo '
';
/* Each post in latest_posts has:
board (with an id, name, and link.), topic (the topic's id.), poster (with id, name, and link.),
subject, short_subject (shortened with...), time, link, and href. */
foreach ($context['latest_posts'] as $post)
echo '
| ', $post['link'], ' |
', $post['poster']['link'], ' |
', $post['board']['link'], ' |
', $post['time'], ' |
';
echo '
';
}
echo '
|
';
}