Log in

View Full Version : Detect Style In Use


MrBen
04-20-2006, 11:37 PM
Is it possible to determine which style is in use on the forums?

The reason I ask is I want to tweak the Geek Auto-Linker code so that it is only displayed when a particular stylesheet is in use. GAL inserts code using parse_templates hook so I figure inserting an IF statement around the code would work.

Thanks,
Ben

peterska2
04-20-2006, 11:44 PM
You could take a look at this mod (Link (https://vborg.vbsupport.ru/showthread.php?t=92009&highlight=style+postbit)) and see how it has been determined there and then work with it from there. That mod is actually to show the style in the postbit, but it probably uses a similar function.

MrBen
04-21-2006, 10:29 AM
Thanks for the reply. I tried that code but it didn't work, but I found another mod which uses the var $styleid which works fine.

So in the hook code I now have,

if ($styleid != 3)
{
GAL Code
}
Thanks,
Ben