Forums / General / How to add classes to admin content structure menu

How to add classes to admin content structure menu

Author Message

Heath

Monday 10 November 2008 6:41:53 am

How is it possible to add content classes (for display) within the administration content structure menu.

One would think there is an ini setting which allows a developer to display custom content classes within the content structure menu.

For example I'm looking in this example to enable the class 'Article' and 'Gallery' to be displayed in the content structure menu.

Cheers,
Heath

Brookins Consulting | http://brookinsconsulting.com/
Certified | http://auth.ez.no/certification/verify/380350
Solutions | http://projects.ez.no/users/community/brookins_consulting
eZpedia community documentation project | http://ezpedia.org

Greg McAvoy-Jensen

Monday 10 November 2008 6:55:47 am

Heath,

It's tucked in contentstructuremenu.ini:

[TreeMenu]
ShowClasses[]
ShowClasses[]=folder
...

Granite Horizon, Certified Developer of eZ Publish Web Solutions
Provider of the SaaS Solution Granite Horizon In The Cloud | http://granitehorizon.com/cloud
http://granitehorizon.com | +1 916 647 6350 | California USA | @granitegreg
Blog: http://granitehorizon.com/blog

Heath

Monday 10 November 2008 7:23:06 am

@Greg

Yes. I am familiar with the settings, TreeMenu:ShowClasses:*
I have added the classes to this settings block in the

file: <i>settings/override/contentstructuremenu.ini.append.php</i>

# which classes to show
ShowClasses[]
ShowClasses[]=folder
ShowClasses[]=forum
ShowClasses[]=gallery
ShowClasses[]=user_group
ShowClasses[]=article
# ShowClasses[]=frontpage
ShowClasses[]=feedback_form

I have cleared all cache

sudo php bin/php/ezcache.php --clear-all

Yet the article class is not displayed within the administration's <i>dynamic</i> content structure menu.

Cheers,
Heath

Brookins Consulting | http://brookinsconsulting.com/
Certified | http://auth.ez.no/certification/verify/380350
Solutions | http://projects.ez.no/users/community/brookins_consulting
eZpedia community documentation project | http://ezpedia.org

Heath

Tuesday 11 November 2008 1:12:26 pm

I reviewed the source code for the dynamic_content_structure menu template and did not notice the usage of the 'ShowClasses' configuration ini variable.

Is there any known reason why my additional custom class entries would not be displayed.

Assuming for the sake of argument that the cache is clearing properly (I deleted the contents of the var/cache and var/(siteaccess)/cache).

Respectfully,
Heath

Brookins Consulting | http://brookinsconsulting.com/
Certified | http://auth.ez.no/certification/verify/380350
Solutions | http://projects.ez.no/users/community/brookins_consulting
eZpedia community documentation project | http://ezpedia.org

André R.

Tuesday 11 November 2008 1:21:53 pm

Tried clearing tree menu cache? (from admin)

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

Heath

Tuesday 11 November 2008 4:59:19 pm

It seems that while I thought the global override directory's file, <i>settings/override/contentstructuremenu.ini.append.php</i> would override the admin siteaccess' copy of the same file, <i>settings/siteaccess/starsadmin/contentstructuremenu.ini.append.php</i>

All I had to do was add the classes in the manner Greg recommends to the admin siteaccess settings file, clear cache as Andre recommends and the content structure menu changed.

Thank you to Greg and Andre for their assistance in my search for the answer.

Cheers,
Heath

Brookins Consulting | http://brookinsconsulting.com/
Certified | http://auth.ez.no/certification/verify/380350
Solutions | http://projects.ez.no/users/community/brookins_consulting
eZpedia community documentation project | http://ezpedia.org

eZ debug

Timing: Jan 18 2025 19:22:52
Script start
Timing: Jan 18 2025 19:22:52
Module start 'content'
Timing: Jan 18 2025 19:22:53
Module end 'content'
Timing: Jan 18 2025 19:22:53
Script end

Main resources:

Total runtime1.0590 sec
Peak memory usage4,096.0000 KB
Database Queries205

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0066 587.8359180.8203
Module start 'content' 0.00660.8970 768.6563642.7266
Module end 'content' 0.90360.1553 1,411.3828341.0625
Script end 1.0589  1,752.4453 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00440.4142210.0002
Check MTime0.00170.1623210.0001
Mysql Total
Database connection0.00080.078510.0008
Mysqli_queries0.961190.75872050.0047
Looping result0.00250.23762030.0000
Template Total1.016696.020.5083
Template load0.00250.233720.0012
Template processing1.014195.766220.5071
Template load and register function0.00010.009810.0001
states
state_id_array0.00180.169110.0018
state_identifier_array0.00190.183820.0010
Override
Cache load0.00190.1835460.0000
Sytem overhead
Fetch class attribute can translate value0.00120.112040.0003
Fetch class attribute name0.00260.246290.0003
XML
Image XML parsing0.00200.192240.0005
class_abstraction
Instantiating content class attribute0.00000.0029120.0000
General
dbfile0.00250.2346430.0001
String conversion0.00000.000430.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
6content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
6content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
14content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
6content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
2content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 36
 Number of unique templates used: 7

Time used to render debug report: 0.0002 secs