The magic is done with ids. Every category and forum is assigned a number, you can find this number by hovering over their link and looking at the URL. The URL will look something like this:
https://URL.com/forumdisplay.php?fid=1
The number on the end is the forum/category's ID!
We will use the forum ID in the forum's class to help us differentiate between each forum.
The two templates you'll want to edit are:
- forumbit_depth1_cat - for the category
- forumbit_depth2_forum - for the forum
And the fantastic variable you want is
{$forum['fid']}
Essentially, what you want to do is give your category and forums a class in the aforementioned templates. These classes should be:
- category no{$forum['fid']}
- forum no{$forum['fid']}
Which looks like this in CSS (with the number varying)
.category.no1 { /* stuff here */ } .forum.no1 { /* stuff here */ }
So what's with the space? The space allows us to do the bulk of your styling without needing to repeat yourself. For example. If you want all forums to have uppercase 14px text. You need only type in the following:
.forum { font-size: 14px; text-transform: uppercase; }
Now you want to target one particular forum to have a certain background with a certain text color?
.forum.no1 { background: #0a0a0a; color: #efefef; }
The final result being:
.forum { font-size: 14px; text-transform: uppercase; } .forum.no1 { background: #0a0a0a; color: #efefef; }
Forum number one will still have 14px uppercase text!
Sure beats having to repeat yourself!
I won't give you the HTML code for your category and forum, because it depends entirely upon your design. Just make sure you use the classes given and you're set to make your forums and categories diverse little individuals!
- 1