Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.
- Index
- » MetaMod
- » MetaMod General Support
- » Problem with displaying a module on...
Problem with displaying a module on some pages
Problem with displaying a module on some pages
I tried to follow the instructions and hope I have not made mistakes, but I have a problem, I loaded the map of ohanah (http://app.ohanah.com/) visible in a menu item
joomla. enthous. it / index.php/what-we-do-now/calendar-events
the problem is when I enter into the individual component events ohanah
joomla . enthous . it/index.php/cosa-facciamo-oggi/agenda-eventi/creattivando
thanks a lot
stefano
the domain is a test site
02-May-13 10:45:33
Re: Problem with displaying a module on some pages
Hi riga75,
you can almost certainly detect the different types of pages in ohanah with a little help from MetaMod's "advanced debug" mode. Can you turn that on (temporarily) then view the 2 pages: the original list page, and the detail page? Then copy and paste the output from MetaMod on the 2 pages and post it to the forum here? From that it's usually fairly obvious how to use the suggested code to distinguish between the 2 types of pages.
Thanks,
Stephen
Re: Problem with displaying a module on some pages
Ok, in MetaMod you have an option called "Debug: off, on, advanced". Creat a MetaMod and set it to display in a valid module position, and on ALL pages. Set it to "debug: advanced", then view the 2 pages mentioned above, and take a copy of the output from the front end. After you have done this you can unpublish or delete that MetaMod because you don't need that info to be shown to the public!
Cheers,
Stephen
Re: Problem with displaying a module on some pages
ok the home of ohanah:
Page Identification
The PHP code below may be used to help MetaMod to identify the exact page that you are viewing. For help using this feature, please click here.
if (
$option == 'com_ohanah'
and $view == 'events'
and $Itemid == '459'
) return XXX; /* replace XXX with the module ID or position to display */
MetaMod debug info:
Module ID: 211
$option: com_ohanah
$view: events
$id:
$Itemid: 459
$timezone: UTC
$language: it-it
$language_code: it
$language_region: it
Including modules: Nessuno
and the internal page of ohanah
Page Identification
The PHP code below may be used to help MetaMod to identify the exact page that you are viewing. For help using this feature, please click here.
if (
$option == 'com_ohanah'
and $view == 'event'
and $id == '3'
and $Itemid == '459'
and $jinput->get('layout') == 'default' /*!*/
) return XXX; /* replace XXX with the module ID or position to display */
Note: lines starting with "and" and ending with /*!*/ contain rules that may be optional. You may wish to leave them out.
MetaMod debug info:
Module ID: 211
$option: com_ohanah
$view: event
$id: 3
$Itemid: 459
$timezone: UTC
$language: it-it
$language_code: it
$language_region: it
Including modules: Nessuno
Re: Problem with displaying a module on some pages
ok, I have forgotten if you want the modules to only appear on the inner page, or NOT on the inner page. So here's how to do both things:
To make the module appear only on the event (inner) pages:
Code:
if (
$option == 'com_ohanah'
and $view == 'event'
) return XXX;
To make the module appear only on the main ohanah page and not the event pages:
Code:
if (
$option == 'com_ohanah'
and $view == 'events'
) return XXX;
Remember to replace XXX with the module id of the module you want to control.
Hope that helps,
Stephen
- Index
- » MetaMod
- » MetaMod General Support
- » Problem with displaying a module on...
Board Info
- Board Stats:
- Total Topics:
- 1689
- Total Polls:
- 6
- Total Posts:
- 5942
- Posts this week:
- 2
- User Info:
- Total Users:
- 7627
- Newest User:
- rudys68879
- Members Online:
- 1
- Guests Online:
- 177
- Online:
- rudys68879
Forum Legend:
Topic
New
Locked
Sticky
Active
New/Active
New/Locked
New Sticky
Locked/Active
Active/Sticky
Sticky/Locked
Sticky/Active/Locked