0

I have a menu with different template assigned.
I want to disable the plugin Tabs & Sliders (by JoomlaWorks) in this menu.

Can I disable this plugin via template ?

  • No, Plugins are disabled via the Plugin Manager and Modules are disabled via the Module Manager – Lodder Jul 28 '15 at 22:40
  • Why do you want to disable it via the template? – TryHarder Jul 29 '15 at 0:42
1

The main problem with trying to disable a plugin in a template is that most plugin events are already fired at the time the template comes into play. So even if you could disable the plugin, it would be to late.

Also the template really shouldn't care at all about what extensions it shows.

A much better approach would be to adjust the plugin itself and add a conditional there. If that is really needed.

0

Tab & Sliders : Module vs Plugin

Well, I suspect that there is a misunderstanding about what plugin and modules are and how they work.

Especially in this case, the extension Tabs & Sliders by JoomlaWorks comes in both a plugin and a module version.

Plugin

The plugin version works by inserting specific strings of the type {tabs=tab one}{/tabs} into your content (articles) and it will display tabs or sliders on these articles and only.

So, it's this kind of a manual process to choose where to show tabs using the plugin.

Module

Regarding the module version, it works like all other modules. You create a new module instance in module manager, you adjust its settings, select its position according to the available positions of the template and set it to published. Module manager allows for control over which menu items a module should be displayed.

So far, there is already much flexibility on where and when to show a module.

Module Positions in Templates

Of course, there can be control inside the template through conditional statements, to manipulate if a module - module position should be called etc.

For example one possible way to do what you want, and check for what template style is being used and then decide to show or not a module position is like this:

$styleId = JMenu::getInstance('site')->getActive()->template_style_id;

Or you could simply remove a specific module position from a template.

Module Manager & Advanced Module Manager

But generally, as others stated you might not want to do all these inside your template, and simply assign modules by menu items.

And for those that need extended control over when a module should be displayed or not, there is the NoNumbers Advanced Module Manager, that gives almost unlimited assignment possibilities, including assignments by template.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.