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.

 

Template switches but menu items siill showing up for the same rule

Template switches but menu items siill showing up for the same rule

I am able to switch a different template for menu other than home. For the same rule, I am unpublishing sub menu items. These sub items still appear. When I clear cache on my site, the menu items disappear but now the home page does not show the sub menu items.

In short, only a cache clean changes the menu items but what I want is -
Home page - Show all sub menu items,
Non home page - Do not show sub menu items

I have caching disabled on the main menu module.

Thanks

Tijj
Beginner Modder
ranks
useravatar
Offline
18 Posts
Administrator has disabled public posting

Re: Template switches but menu items siill showing up for the same rule

Hi Tijj,

1 - what version of Joomla are you running?
2 - what template are you using? Is it a commercial one?
3 - how do you have Chameleon set up to remove the sub menu items? Do you have this in the same "rule" as the template switch?

Can I suggest that you use Chameleon's Debug mode (found in the settings button on the Chameleon rule chain page). Then look at front page on the site and see what steps Chameleon is taking – what it's checking for, and what actions it is applying. This may help to track down any logic problems in the rules.

In general, page caching is great except that it caches pages per URL. This should be fine for your setup, as each page is distinct for each URL. (where it fails is where the page changes according to something other than the URL, e.g. by type of browser, in which case that kind of cache is useless).

Hope that helps,
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
3329 Posts
User info in posts
Administrator has disabled public posting

Re: Template switches but menu items siill showing up for the same rule

Joomla 2.5.8, Yootheme commercial.

I tried Chameleon with same rule as well as 2 rules.

I knew about debug mode so I already tried it. It Does show that the fail action supresses the menu. But why is it still supressed on the home page where I did not ask the rule to supress?
On the other hand, I clear cache and reload the home page - Now the menu items appear which is what I want. I ten click on any other page and now they show the menu items but according to the rule its not supposed to show.

Again -  Unless the cache is cleared, its not working correctly and supressing or showing items where its not supposed to.

For example:

I am in home page and I refresh it. It shows the sub menu items.

I click on any other menu and navigate to another page. Debug mode shows:
Started FAIL action for rule id 5
- Removing menu item 190
- Removing menu item 278
- Removing menu item 281
- Removing menu item 279

But these menu items still show unless I goto Joomla and clear cache.

Tijj
Beginner Modder
ranks
useravatar
Offline
18 Posts
Administrator has disabled public posting

Re: Template switches but menu items siill showing up for the same rule

Ok, looks like we're making progress.

1 - can you just confirm which cache you are talking about above? Is it the system cache plugin, or the cache found in global preferences? Or a cache in the Warp framework?

2 - does everything work as expected when the cache (whichever one it is) is turned off?

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
3329 Posts
User info in posts
Administrator has disabled public posting

Re: Template switches but menu items siill showing up for the same rule

I use system cache plugin as well as Global Config cache.

I turned off system cache plugin but that made no difference. I then turned of conservative cache to OFF in Global config and now it worked as expected.

System cache only - works fine
Global config cache - Does not work

I need to have cache enabled as I update my site frequently - around 30 times a day. The template switch works so the menu switch should also work I guess,

Thanks for your help.

Tijj
Beginner Modder
ranks
useravatar
Offline
18 Posts
Administrator has disabled public posting

Re: Template switches but menu items siill showing up for the same rule

Hi Stephen,

Looks like you are not working today. Please provide your inputs when you get back,

Wish you a very Happy New Year. !

Thanks

Tijj
Beginner Modder
ranks
useravatar
Offline
18 Posts
Administrator has disabled public posting

Re: Template switches but menu items siill showing up for the same rule

Hi Tijj,

I'm just looking at the caching situation. From your description, it appears that the Global Config cache is caching the menu items in a way that Chameleon is not able to override. So I am looking at exactly how that occurs to see how/if Chameleon can work around this limitation. At least for now there's a workaround for you (keeping the Global Config caching turned off) even if that's not ideal. Out of interest, how much difference does the Global Config cache make to your site?

I'll report back with any progress.

Thanks for your clear bug reporting!

Best regards,
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
3329 Posts
User info in posts
Administrator has disabled public posting

Re: Template switches but menu items siill showing up for the same rule

Thanks Stephen.

I have found a temporary workaround but I am not implementing it as it looks like there this is something we should fix.

Work around - Clean everything in mod_menu in cache folder and make the folder unwritable (permission xxx). This would prevent cache being written for the menu module.

As of now, I am just staying away from using Chameleon to switch templates and the menu because of this issue (I cant use template switch because one template uses dropline menu so the menu hiding needs to work first).

Thanks

Tijj
Beginner Modder
ranks
useravatar
Offline
18 Posts
Administrator has disabled public posting

Re: Template switches but menu items siill showing up for the same rule

I've just tested this out as closely as possible to your setup. So far I have been unable to replicate the problem.

My setup:
- Joomla 2.5.8
- standard template (sorry don't have a current Warp template to test with)
- standard menu module
- system cache plugin off
- global config cache on; tried with conservative and progressive
- menu module cache set to "global" and off

With all of these settings, Chameleon is able to turn a menu item "off" on all pages but the front page.

One interesting thing I noticed is that with global config cache on, it's important to clear the cache after making changes in Chameleon to what menu items are hidden.
e.g.
- global config cache on (conservative or progressive)
- menu module cache set to global
- Chameleon removes menu item from internal pages
- front page and internal pages are now showing the correct menu items
- change the Chameleon rule to remove different menu items
- the changes are NOT reflected until the cache is cleared. This behaviour is expected, but also shows that a different cache of the menu item is being maintained for each inner page and front page.

Ok, so your experience is different to this. Could I suggest 2 things:

1 - clear the cache after making any changes in Chameleon. Does this make any difference? (possibly not, but worth checking)

2 - could you please send me a copy of your Warp template? It's possible that the Warp framework does more aggressive caching of the JMenu structure, so I'd like to be able to test that and see if I can replicate your results.

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
3329 Posts
User info in posts
Administrator has disabled public posting

Re: Template switches but menu items siill showing up for the same rule

Just noticed you have JotCache installed - can you please try everything with JotCache turned off, to see if that makes a difference?

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
3329 Posts
User info in posts
Administrator has disabled public posting

Board Info

Board Stats:
 
Total Topics:
1689
Total Polls:
6
Total Posts:
5941
Posts this week:
1
User Info:
 
Total Users:
5355
Newest User:
titus87954
Members Online:
3
Guests Online:
91


Forum Legend:

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