News:

Wondering if this will always be free?  See why free is better.

Main Menu

assigning unique id's to boards in forum index..

Started by supastoked, October 24, 2006, 09:05:00 AM

Previous topic - Next topic

supastoked

SMF Version: SMF 1.1 RC3
Hey Folks,
I've searched the forums to see if anyone else has done this or something similar, but havent managed to find anything. I am trying to find a way to assign a unique id to boards, so i can have individual icons for each of the specific boards. I've looked in all the template files, but nothing jumps out. I figured i could do something like <img class="icon-<?php echo boardid ?>" which would then give board 1 an id of "icon-1" and i'd then be able to use specificity to target each of the individual boards to give them there own icons.

I am sure this is probably something simple and am more than likely staring the answer in the face and not even realizing. Anyways, if anyone is able to offer some guidance it would be very much appreciated!

Thanks,
Chris

LeGaS

Hello!

Try this (in your theme's index.template.php):
echo '<img src="..." class="icon-', $board['id'], '" />';

supastoked

Hi LeGas,
Sorry for the belated reply - i forgot to set the notification on this post!!! I just tried your suggestion and it works like a charm!!!!!! Thank you very much for taking the time to help out!!!  :D
Cheers,
Chris

Advertisement: