Welcome to the MetaMod and Chameleon Support Forums.

Before posting, please check out the FAQs.

helpme

 

Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.

 

(Solved) Recipe to load 2 modules

(Solved) Recipe to load 2 modules

UPDATE:  Closer look at the documentation showed me that if I have more than one module ID I need to enclose them in quotes:  if ($template != "Ethnowideinterior") return "215,296" ;   The quotes work!

Hello

I am trying to load two modules via ID.

I don't think the below is the correct format. 

$mainframe = JFactory::getApplication();
$template = $mainframe->getTemplate();
if ($template != "Ethnowideinterior") return 215, 296 ;

The above only returns the first module: 215

Here is the resulting debug code:

Module ID: 301
$option: com_content
$view: article
$id: 787
$Itemid: 525
$timezone: UTC
$language: en-us
$language_code: en
$language_region: us
Including modules: 215

The above shows the first module, but as we can see, ignores 296
I am assuming the "," is not a way to include two modules?

Thanks!

Rowby

Edited By: metamodguy
05-Jan-14 02:57:24

rowby
Junior Modder
ranks
useravatar
Offline
24 Posts
User info in posts
Administrator has disabled public posting

Board Info

Board Stats:
 
Total Topics:
1667
Total Polls:
6
Total Posts:
5909
Posts this week:
1
User Info:
 
Total Users:
10113
Newest User:
michael2066
Members Online:
1
Guests Online:
214

Online: 
michael2066

Forum Legend:

 Topic
 New
 Locked
 Sticky
 Active
 New/Active
 New/Locked
 New Sticky
 Locked/Active
 Active/Sticky
 Sticky/Locked
 Sticky/Active/Locked