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] Show module only on product category and not product page

[solved] Show module only on product category and not product page

Hello!
I m using Joomla 2.5.8 along with VM 2.0.20b and MetaMod 3.11.


I have 2 VM Product Categories and I also linked them to 2 different Product Category Modules.
I'm trying to show each module(product category list) to show only in related VM category page and not in the VM product page.

This is what I m using at the moment:

$vm = JomGenius("virtuemart");
if ($vm->check("pagetype = category")) return 22;

This could work but its a global rule so I cant define which module to show in a Product Category.

I also tried this:

$vm = JomGenius("virtuemart");
if ($vm->check("category_ids = 10")) return 22;

$vm = JomGenius("virtuemart");
if ($vm->check("category_ids = 11")) return 23;

But this code displays the VM Category modules also in the Product Detail Page.

Any help would appreciated smile

Edited By: metamodguy
18-Dec-13 02:47:26

Makis77
Beginner Modder
ranks
useravatar
Offline
1 Posts
Administrator has disabled public posting

Re: [solved] Show module only on product category and not product page

Hi, sorry for the sloooow response,

It's just a matter of combining the 2 rules:


$vm = JomGenius("virtuemart");
if ($vm->check("category_ids = 10") and $vm->check("pagetype = category")) return 22;
if ($vm->check("category_ids = 11") and $vm->check("pagetype = category")) return 23;


Cheers,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3312 Posts
User info in posts
Administrator has disabled public posting

Re: [solved] Show module only on product category and not product page

Hallo, i was using this method to display a module on a category.
Everythig was working fine until i updated virtuemart form 2.0.22c to 2.0.24c.
Now it doesn't work anymore, nothing is displayed even if i didn't change anything else: the same categories, the same modules...

The string i was using is:

$vm = JomGenius("virtuemart");
if ($vm->check("category_ids = 3") and $vm->check("pagetype = category")) return 188;

Could you help me please ?

Thanks

kekko
Beginner Modder
ranks
useravatar
Offline
6 Posts
Administrator has disabled public posting

Re: [solved] Show module only on product category and not product page

i can add that it works if i only write:

$vm = JomGenius("virtuemart");
if ($vm->check("category_ids = 3")) return 188;

so the problem is only the part:
and $vm->check("pagetype = category")

that is the reason why i use metamod, in order to make the pages of the single products of the category not to show the module 188.

maybe the new virtuemart changed the name of the pagetype ?

I also tried to use 2.0.24b becouse 2.0.24c i think is unofficial, but it's the same..

Thank you so much

kekko
Beginner Modder
ranks
useravatar
Offline
6 Posts
Administrator has disabled public posting

Re: [solved] Show module only on product category and not product page

Can you tell me if you have Chameleon installed, or just MetaMod? Chameleon is more likely to be upset by changes in VM than MetaMod is, so that would be useful to know.

Also what exact version of Joomla are you using?

I'll do some checking with the different versions of VM and see if something changed in the category implementation.

Thanks,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3312 Posts
User info in posts
Administrator has disabled public posting

Re: [solved] Show module only on product category and not product page

Ok, found the issue, a fairly easy one to fix. Will release an update to MetaMod and Chameleon later today to fix it. This will be backwards compatible with older sub-versions of VM too.

Thanks for reporting it,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3312 Posts
User info in posts
Administrator has disabled public posting

Re: [solved] Show module only on product category and not product page

Thank you so much,
so i have just to wait for the fix or do i have to install Chameleon in any case ?

Thanks

kekko
Beginner Modder
ranks
useravatar
Offline
6 Posts
Administrator has disabled public posting

Re: [solved] Show module only on product category and not product page

Just wait for the fix - if you aren't using Chameleon then you don't need it – it's just that the 2 products share the same piece of code and if you're using both then the Chameleon one gets used so you would need the update for that.

I hope to have the new MetaMod available later today. WIll update on here once it's available.

Cheers,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3312 Posts
User info in posts
Administrator has disabled public posting

Re: [solved] Show module only on product category and not product page

Hallo,
i can't see any new version, is there a patch or something like that to make it work ?

Thanks

kekko
Beginner Modder
ranks
useravatar
Offline
6 Posts
Administrator has disabled public posting

Re: [solved] Show module only on product category and not product page

Sooorry it took ages, but I've just uploaded the new versions: the free version is a direct download from http://www.metamodpro.com/metamod/download and for the Pro version you need to log into your account, view your orders, and download from the order page.

Thanks for your patience,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3312 Posts
User info in posts
Administrator has disabled public posting

Board Info

Board Stats:
 
Total Topics:
1666
Total Polls:
6
Total Posts:
5909
Dormant:
User Info:
 
Total Users:
10093
Newest User:
lamanaudio
Members Online:
0
Guests Online:
266

Online: 
There are no members online

Forum Legend:

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