Question

I've assinged some modules to the category page but they also appear on the K2 item page.

I've tried Advanced Module Manager but it says it's not compatible with the module i was using so the Also on child item option doesn't work.

Any ideas?

Was it helpful?

Solution

i had same problem,and solved

create a hidden menu for each K2 item, in menu manager create a new menu (name it hidden) where it will not appear in any page, then at that hidden menu you can create a menu for each k2 item, and in module manger deselect that menus from menu assignment that solution worked for me as i didnt have much k2 items

OTHER TIPS

What you could do is create an override for the modules you are trying to display and wrap the whole thing in an if clause.

First copy the folder /modules/mod_MYMODULE/tmpl to /templates/MYTEMPLATE/html and rename it to the name of your module eg /templates/MYTEMPLATE/html/mod_MYMODULE.

Then rename default.php to whatever (for example k2catonly.php) and wrap it in an if clause eg.

if(JFactory::getApplication()->input->get('view') == 'itemlist') {
    // module code
}

Then open said modules in your module manager and select your new sub-template (usually found in the advanced options and called "Alternative Layout".

Now your module will only display on the category. To display it on all pages but the item page wrap it in the following instead:

if(JFactory::getApplication()->input->get('view') !== 'item') {
    // module code
}
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top