MyBB Community Forums

Full Version: Adding Icons Next to Each Forum?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I've been trying to do this for quite some time tonight - but to no avail. What I want to resolve is being able to add icons next to the forums (like so). I realize that labrocca has a plugin to achieve this, but I currently don't have a method of payment at the moment (if I did, I would most certainly subscribe, as it seems more than worth it). If someone knows how to do this, and it isn't very difficult to accomplish, I would greatly appreciate any help I can get. I have the basic idea of how to pull it off, but I'm relatively unfamiliar with how to actually do it correctly; I seem to obliterate my forum every time I make a small change.
You need to make a series of edits to pull this off. First, edit Forumbit Templates -> forumbit_depth1_cat. Change <td class="thead" colspan="5"> to <td class="thead" colspan="6"> (around line 4), and also change <td class="tcat" colspan="2"> to <td class="tcat" colspan="3"> (about 11 lines from the bottom).

In forumbit_depth2_forum, before <td class="{$bgcolor}" valign="top">, add <td class="{$bgcolor}" valign="top"><img src="{$theme['imgdir']}/forum_icons/{$forum['fid']}.gif" alt="" /></td>.

In Forumdisplay Templates, edit forumdisplay_subforums. Change <td class="thead" colspan="5" to <td class="thead" colspan="6" (around line 3), and after <td class="tcat" width="2%">&nbsp;</td> add <td class="tcat" width="2%">&nbsp;</td>.

Then, you need to make a folder called "forum_icons" in your images folder, and add your forum icons into there. For example, for your first forum, it will be ./images/forum_icons/2.gif. You just need to match the forum ID with the image name...

Although I think you should find a way to buy a subscription at MyBB Central. Labrocca's plugin is much more user friendly to this.

Also, be warned that this will increase your server load / page loading times if you have a large amount of forums on your index, due to the amount of image requests.
Tom - thank you. That worked perfect! Smile

And thanks for the advice, too.
Is there a way to make this work when your index has forums and categories? I managed to shove the forums over (changing some categories to forums in the process), but the categories are still one column shorter. How do I shove those over (I don't want to put images in the very top categories)?
[Image: cap.jpg]
Isn't this exactly what Labrocca's Ficons does? Big Grin
I just don't see a reason to pay 5/year just to use their little thing when I can do it myself. I just need to know what to edit to shove it over. :\
(2009-02-26, 10:05 PM)bpatton Wrote: [ -> ]I just don't see a reason to pay 5/year just to use their little thing when I can do it myself. I just need to know what to edit to shove it over. :\

You pay $5 a year for loads of plugins, not just this one. I was just mentioning that this is what Ficons does.
Increase the "colspan" value by 1 for the "Forums" header, and do the same for the category title.
(2009-02-27, 11:14 AM)Yumi Wrote: [ -> ]Increase the "colspan" value by 1 for the "Forums" header, and do the same for the category title.

Awesome, thanks!

Will this work for all the themes that I've installed? I'm running into not being able to see the new icons in a second theme (I have 3 of the Afresh themes installed).
You'll need to perform the template edits on all the themes unfortunately.

Alternatively, you could save the template into the Global Templateset, and remove any custom versions of the template for each theme.
Pages: 1 2