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.

 

Changing template in products page

Changing template in products page

Hello

I have some rules changing the template according to different categories, the problem appears when I go to check an specific product, there I am not getting any info on ancestor_category_ids I just can get product_parent_id, I need a recipe based on product_parent_id to get the ancestors categories of that parent and change the template based on this

Thank you for your help

edsadr
Beginner Modder
ranks
useravatar
Offline
3 Posts
Administrator has disabled public posting

Re: Changing template in products page

Hi,

can you please tell me the version of Chameleon, Joomla and VM that you are using?

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: Changing template in products page

Hello

Joomla 1.5.22
Chamaleon 1.19
Virtuemart 1.1.7a stable

I am getting the product_parent_id but not ancestors_category_ids

Thank you for your help

edsadr
Beginner Modder
ranks
useravatar
Offline
3 Posts
Administrator has disabled public posting

Re: Changing template in products page

ok, the GUI controls for the ancestor category ids should work, but you should be able to use the PHP box on the left to do this:

$vm = JomGenius("virtuemart");
$ids = $vm->info("ancestor_category_ids);
echo "ancestor ids: ";
print_r($ids);

Then view one of the products on the front end of the site and see what happens. It will probably make a mess of the HTML on your page (temporarily), but see if at the top of your page you see a list of the ancestor category ids for the product you are viewing. Does this come up with the right information? If so, we'll refine that to check for a specific ancestor and switch the template with that info.

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

Board Info

Board Stats:
 
Total Topics:
1667
Total Polls:
6
Total Posts:
5909
Total Posts Today:
1
User Info:
 
Total Users:
10099
Newest User:
chris277354
Members Online:
0
Guests Online:
167

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