MyBB Community Forums

Full Version: Breakdown of Templates
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Is there a thread out there that shows all the elements of a template and where to find them? I'm specifically looking for board statistics and whos online but if there is a breakdown of where to find the html elements (in which areas of the templates) I'd be happy as a clam. As you can see from the image, I have a bit of a problem...the advanced stats altered my template and I'd like to fix it.

I've STF high and lo and haven't come up with anything...

[Image: whosonlineprob.Jpg]
Thanks so much Big Grin Exactly what I was looking for to solve my problem.

Is there a graphical representation of a standard template and its areas in the admin CP though for future reference? (so I don't have to ask silly questions after I mess things up?)

Also...that thread fixed the 'whos online' part of things...

I'm also looking at repairing the Board Statistics part of things as well.
Found the board statistics...

They're located in index_stats under the index section in templates..

I found
<tr><td class="tcat"><strong>$lang->boardstats</strong></td></tr>
<tr>
<td class="trow1"><span class="smalltext">
$lang->stats_posts_threads<br />
$lang->stats_numusers<br />
$lang->stats_newestuser<br />
$lang->stats_mostonline
</span>
</td>
</tr>

and replaced with
<tr><td class="tcat" colspan=""><strong>$lang->boardstats</strong></td></tr>
<tr>
<td class="trow1" colspan=""><span class="smalltext">
$lang->stats_posts_threads<br />
$lang->stats_numusers<br />
$lang->stats_newestuser<br />
$lang->stats_mostonline
</span>
</td>
</tr>

Which added the colspan="" to each tcat and trow.

Now I only have to find and fix the header to this section.
I think I've found where that collapsable row for board statistics is...but I'm not sure how to go about fixing it. As you can see from the image I posted previously, it halts after 1 column. I've found that it is inside Index Templates >> Expand >> Index

<html>
<head>
<title>$settings[bbname]</title>
$headerinclude
</head>
<body>
$header
$forums
<table border="0" cellspacing="$theme[borderwidth]" cellpadding="$theme[tablespace]" class="tborder">
<thead>
<tr>
<td class="thead">
<div class="expcolimage"><a href="javascript:expandCollapse('boardstats');"><img src="$theme[imgdir]/collapse$collapsedimg[boardstats].gif" id="boardstats_collapseimg" border="0" alt="[-]" /></a></div>
<div><strong>$lang->boardstats</strong></div>
</td>
</tr>
</thead>
<tbody style="$collapsed[boardstats_e]" id="boardstats_e">
$whosonline
$birthdays
$forumstats<!-- ASOIP_2_0_I -->
</tbody>
</table>
<br />
<table border="0" cellspacing="$theme[borderwidth]" cellpadding="$theme[tablespace]" class="tborder">
<tr>
<td class="trow1">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td valign="middle" align="left">
<table cellspacing="0" cellpadding="2" border="0">
<tr><td><img src="$theme[imgdir]/on.gif" alt="$lang->new_posts" /></td><td class="trow"><span class="smalltext">$lang->new_posts</span></td></tr>
<tr><td><img src="$theme[imgdir]/off.gif" alt="$lang->no_new_posts" /></td><td class="trow"><span class="smalltext">$lang->no_new_posts</span></td></tr>
<tr><td><img src="$theme[imgdir]/offlock.gif" alt="$lang->forum_locked" /></td><td class="trow"><span class="smalltext">$lang->forum_locked</span></td></tr>
</table>
</td>
<td valign="top" align="right">
<table width="100%" cellspacing="0" cellpadding="0" border="0">
<tr><td valign="top" align="right">
<span class="smalltext">$logoutlink<a href="misc.php?action=markread">$lang->markread</a> | <a href="showteam.php">$lang->forumteam</a> | <a href="stats.php">$lang->forumstats</a></span>
</td></tr>
$loginform
</table>
</td></tr>
</table>
</td></tr>
</table>
$footer
</body>
</html>

Is it this line?

<div><strong>$lang->boardstats</strong></div>

Or would it be the thead class above and I'd have to add the colspan="" to it?
Ok...sorry for replying so much to myself...but I'm hopefully helping someone else if they have this problem...


I've found the place you need to alter it. Open your template and expand Index Templates >> Index

Find:

<td class="thead">

Replace with:

<td class="thead" colspan="">

That expands your collapsable board statistics row to fill the page across instead of being one column of the advance statistics.

Thanks for pointing me in the right direction initially. Smile