Welcome to the MetaMod and Chameleon Support Forums.

Before posting, please check out the FAQs.



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


Produktkathegorie an einen bestimmten Tag dastellen

Produktkathegorie an einen bestimmten Tag dastellen


ich benutze VirtueMart 3.0.9  und Chameleon

Ich möchte an eine Tag der Woche eine bestimmte Produktkathegorie darstellen und eine andere ausblenden.
An den anderen Tagen der Woche genau umgedreht.

Wie kann ich dies am besten lösen.

Mit freundlichen Grüßen

Beginner Modder
1 Posts
Administrator has disabled public posting

Re: Produktkathegorie an einen bestimmten Tag dastellen

Hi Kaule,

thanks for your question. I trust you can either read English or that Google Translate can help you smile

In answer to the question, the answer is a little complicated.

It all depends on how you display the category:
- if you have a menu item for a page that displays just 1 category, then Chameleon could hide that menu item and display another one with a different category instead.
- or, Chameleon can also change the category id of the category that the page will display.

However, if someone is viewing the hierarchy of categories e.g. sports -> cycling -> bikes -> MTB  then Chameleon can't change the way that the hierarchy will appear as people navigate through it.

So if you want to "feature" a category on a certain day of the week, then I'd set up a menu item that displays all the items from a certain category. Using Chameleon, we're going to detect which day of the week it is, and change the parameters of the menu item based on that, so that you can tell it to show a different category instead.

There's a box in the Succeed Action called PHP where can put in a snippet of code to tell VM which category to display, overriding the category in the menu item.


1 - create a new Chameleon rule and name it "mondays".
2 - in the Environment tab, enter "monday 00:00" as the start date/time, and "monday 11:59" as the end date/time
3 - in the Menu Handling tab, select the menu item that you want to be affected by this change (the one that displays the category page)
4 - in the VirtueMart tab, select "page type": category AND manufacturer.products (select both items in the select box)
5 - in the Actions tab, in the PHP box, add the following, editing the category id to whichever one you want to display on that page on Mondays.

JRequest::setVar("virtuemart_category_id", 8);

6 - Save the rule
7 - repeat this, creating a new rule for each day of the week that you want to display a different category.

#3 and #4 are important so that the rule only activates on the exact page that you want it to apply to. Otherwise it might create problems on other pages.

I've tested this and it works on my test system. I trust it will do what you want it to do. This does depend on what type of page you want to change though. There are several other techniques that can be used, so please ask if this does not suit your situation.

Best regards,

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

3330 Posts
User info in posts
Administrator has disabled public posting

Board Info

Board Stats:
Total Topics:
Total Polls:
Total Posts:
Total Posts Today:
User Info:
Total Users:
Newest User:
Members Online:
Guests Online:

There are no members online

Forum Legend:

 New Sticky