View Full Version : Installing mods stopping templates changes in all styles?
deverill2010
07-06-2012, 06:13 AM
I'm currently working on a new look and want to release some new mods alongside my new theme. So when I install a mod how can I stop the template changes affecting all my styles? I only wnt them to apply to my secret style at the moment as otherwise there is no surprise!
You could do something like this:
global $style;
if ($style['title'] == "My Style")
{
// do something
}
One issue is that this won't work until the style is loaded, which doesn't happen until a template is rendered, but if you can do what you need to do using hook parse_templates then it should always work.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.