(Updated Feb/2009) Mybb 1.2x/1.4x Pure CSS "Custom Forum Icons" with only 1 image
This is a nice feature if you want to use custom icons and don't want to kill your CPU usage (if is a Shared Host) - Without <img> tags to each Forum there will be lower http requests.

[Image: custom-forum-icons-mybb-1_44.png]

Updated in Feb/09

(I) New Style Sheet

Create this CSS in ACP => Themes => Edit Theme => Add Stylesheet:


[Image: add_stylesheet.gif]

Quote:CSS Example is attached to download with the complete tutorial

This new style must be conected only to forumdisplay.php and index.php

[Image: Css-configuration.gif]

[II] Template Edit
Go to ACP => Templates & Style => Templates => Expand your Template

Expand "Forum Bit Templates":


<img src="{$theme['imgdir']}/{$lightbulb['folder']}.gif" alt="{$lightbulb['altonoff']}" title="{$lightbulb['altonoff']}" class="ajax_mark_read" id="mark_read_{$forum['fid']}" />

Replace with:

<!--Start - CSS Custom Forum Icons-->
<h2 id="{$lightbulb['folder']}_{$forum['fid']}"><a href="forumdisplay.php?fid={$forum['fid']}" rel="nofollow"><span>status</span></a></h2>
<!--End CSS Custom Forum Icons -->

[III] Background Image

Put "custom_forum_icons.png" in "\images\yourtheme\" folder

[Image: custom_forum_icons.png]


Thanks Labrocca for Custom Forum Icons for 1.2x and texasli for the code in mybb 1.4

other ways to do it:


Attached Files
.zip   Tutorial mybb custom forum icons with CSS.zip (Size: 54.17 KB / Downloads: 728)

Messages In This Thread
(Updated Feb/2009) Mybb 1.2x/1.4x Pure CSS "Custom Forum Icons" with only 1 image - by aglioeolio - 2008-08-08, 03:42 PM
CSS FAQ - by Pitter - 2008-09-25, 09:50 AM

Forum Jump:

Users browsing this thread: 1 Guest(s)