MenuSettings per class

Author Message

Erik Weinmaster

Tuesday 11 January 2011 2:35:23 pm

Is there anyway to have menu settings available on a per class basis for the ezwebin extension? More specifically, I want the flat_left menu to display for one class, but I want just a TopOnly design for most other classes. The settings I see in menu.ini I believe are mostly for the admin interface. Thus, what exists for the ezwebin interface?

Thanks,

Erik

André R.

Wednesday 12 January 2011 2:50:20 am

you can customize this from your class's node template by using persistent variables which ezpagedata looks for.

See how other templates in webin/flow uses it, for instance frontpage.tpl in webin:

{set scope=global persistent_variable=hash('left_menu', false(),
'extra_menu', false(),
'show_path', false())}

This needs to be on the top of the node temaplte, if you use persistent_variable for other stuff, then consider using ezpagedata_set | ezpagedata_append functions from webin which does any merging needed for you on this variable.

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 05:09:34
Script start
Timing: Jan 18 2025 05:09:34
Module start 'layout'
Timing: Jan 18 2025 05:09:34
Module start 'content'
Timing: Jan 18 2025 05:09:34
Module end 'content'
Timing: Jan 18 2025 05:09:34
Script end

Main resources:

Total runtime0.0171 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0067 589.0391152.6250
Module start 'layout' 0.00670.0034 741.664139.4375
Module start 'content' 0.01010.0049 781.101689.3047
Module end 'content' 0.01500.0021 870.406330.2891
Script end 0.0171  900.6953 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.003017.2064140.0002
Check MTime0.00137.8134140.0001
Mysql Total
Database connection0.00094.993410.0009
Mysqli_queries0.004023.468030.0013
Looping result0.00000.087610.0000
Template Total0.001810.410.0018
Template load0.00094.969810.0009
Template processing0.00095.389710.0009
Override
Cache load0.00063.423510.0006
General
dbfile0.00021.446280.0000
String conversion0.00000.048740.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs