Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: How Do I Do This?

<?php bb_get_header(); ?>

<?php if ( $forums ) : ?>

<div id="hottags">
<h2><?php _e('Hot Tags'); ?></h2>
<p class="frontpageheatmap"><?php bb_tag_heat_map(); ?></p>
</div>

<div id="discussions">
<?php if ( 0 > 1 ) : ?>

<h2><?php _e('Latest Discussions'); ?></h2>

<table id="latest">
<tr>
<th><?php _e('Topic'); ?> — <?php new_topic(); ?></th>
<th><?php _e('Posts'); ?></th>
<th><?php _e('Last Poster'); ?></th>
<th><?php _e('Freshness'); ?></th>
</tr>

<?php if ( $super_stickies ) : foreach ( $super_stickies as $topic ) : ?>
<tr<?php topic_class(); ?>>
<td><?php _e('Sticky:'); ?> <big><a href="<?php topic_link(); ?>"><?php topic_title(); ?></a></big></td>
<td class="num"><?php topic_posts(); ?></td>
<td class="num"><?php topic_last_poster(); ?></td>
<td class="num"><small><?php topic_time(); ?></small></td>
</tr>
<?php endforeach; endif; // $super_stickies ?>

<?php if ( $topics ) : foreach ( $topics as $topic ) : ?>
<tr<?php topic_class(); ?>>
<td><a href="<?php topic_link(); ?>"><?php topic_title(); ?></a></td>
<td class="num"><?php topic_posts(); ?></td>
<td class="num"><?php topic_last_poster(); ?></td>
<td class="num"><small><?php topic_time(); ?></small></td>
</tr>
<?php endforeach; endif; // $topics ?>
</table>
<?php endif; // $topics or $super_stickies ?>

<?php
if ( bb_forums() ) :
global $bb_forums_loop;
$_loop =& $bb_forums_loop;
bb_forum();
$skipForum = false;
while ($_loop) :
if ($_loop->walker->depth == 1) {
if (in_array(get_forum_id(), array(2, 3, 4, 5, 6, 7, 18, 19, 20, 101)))
$skipForum = true;
if ($skipForum) {
?>
<h2<?php bb_forum_class?>><a href="<?php forum_link(); ?>">Click Here To Go To the <?php forum_name(); ?> Forums</a></h2>
<?php
}
else {
?>
<h2<?php bb_forum_class?>><?php forum_name(); ?></h2>
<table id="forumlist">
<tr>
<th><?php _e('Main Theme'); ?></th>
<th><?php _e('Topics'); ?></th>
<th><?php _e('Posts'); ?></th>
</tr>
<?php
}
}
elseif (!$skipForum) {
?>
<tr<?php bb_forum_class(); ?>>
<td><?php bb_forum_pad( '<div class="nest">' ); ?><a href="<?php forum_link(); ?>"><?php forum_name(); ?></a><small><?php forum_description(); ?></small><?php bb_forum_pad( '</div>' ); ?></td>
<td class="num"><?php forum_topics(); ?></td>
<td class="num"><?php forum_posts(); ?></td>
</tr>
<?php
}
bb_forum();
if ($_loop === null || $_loop->walker->depth == 1) {
if (!$skipForum)
echo '</table>';
$skipForum = false;
}
endwhile; ?>
<?php endif; // bb_forums() ?>

<?php if ( bb_is_user_logged_in() ) : ?>
<div id="viewdiv">
<h2><?php _e('Views'); ?></h2>
<ul id="views">
<?php foreach ( bb_get_views() as $view => $title ) : ?>
<li class="view"><a href="<?php view_link(); ?>"><?php view_name(); ?></a></li>
<?php endforeach; ?>
</ul>
</div>
<?php endif; // bb_is_user_logged_in() ?>

</div>

<?php else : // $forums ?>

<h3 class="bbcrumb"><a href="<?php bb_option('uri'); ?>"><?php bb_option('name'); ?></a></h3>

<?php post_form(); endif; // $forums ?>

<?php bb_get_footer(); ?>

Skip to toolbar