Forums / Setup & design / Menu Structure not show some items

Menu Structure not show some items

Author Message

Cristian Pacheco

Thursday 25 October 2007 5:03:59 am

Hello, we have this doubt and need if you can help us. We defined (in v3.9.3) this structure of Menu created with Folders but the items under 5th level, (Sub2_Menu1 > Item1, Item2, Item3) do not appear in the end user page.

- Is normal this behavior ?
- There is way to show them ?

Example:

Home / Menu2 / Submenu2 / Sub2_Menu1 / Item1

Home (ROOT)
-Menu1
-Menu2
-SubMenu2
-Sub2_Menu1
- Item1*
- Item2*
- Item3*
-Sub2_Menu2*
-Sub2_Menu3*
-Menu3
-Menu4

Thanks, Cristian.

UTN Facultad Regional Delta
Campana, Bs.As.-Argentina
http://www.frd.utn.edu.ar

Ɓukasz Serwatka

Friday 26 October 2007 12:12:14 am

Hello Cristian and welcome to the eZ Publish Community!

I assume that you are using Website Interface, where left menu support 2 levels only. However as long as folder has enabled checkbox on "Display sub items" attribute, you should see all children in main content area.

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

Cristian Pacheco

Friday 26 October 2007 6:15:58 am

Yes, I am Using Website Interface. Thanks for you Reply.

Saludos, Cristian.

UTN Facultad Regional Delta
Campana, Bs.As.-Argentina
http://www.frd.utn.edu.ar

Bernd Winkelmann

Tuesday 13 November 2007 5:33:40 am

Hi Cristian

I had the same problem yesterday.

the standard presentation of subitems is a bit unluckily

my solution

1. create overwrite template for /menu/flat_left.tpl from extension/ezwebin/design/ezwebin/templates

Admin/Design -> select here your siteaccess (my is ger) otherwise you will show templates from the current sitaccess (first i was confused because not displaying the templates for what i was seaching)

->Templates

filter for flat_left

find menu/flat_left in extension/ezwebin/design/ezwebin/templates

->create now a overwite for this template (eg treemenu_flat_left[.tpl]) for your siteaccess

the overwrite template is now in design/ezwebin/override/templates/ ready for editing

or edit it online clicking the "Pencil"
my looks like this
this is presenting the same menu stile also for other subitems like eg documentation pages

<div class="border-box">
<div class="border-tl"><div class="border-tr"><div class="border-tc"></div></div></div>
<div class="border-ml"><div class="border-mr"><div class="border-mc">

        <h5><a href={if eq( $ui_context, 'browse' )}{concat("content/browse/", $module_result.path[$pagerootdepth].node_id)|ezurl}{else}{$module_result.path[$pagerootdepth].url_alias|ezurl}{/if}>{$module_result.path[$pagerootdepth].text}</a></h5>

<div class="contentstructure">
    {include uri='design:parts/treemenu.tpl'}
    {* try also -> menu_01/flat_left.tpl looks a bit different *}
</div>

</div></div></div>
<div class="border-bl"><div class="border-br"><div class="border-bc"></div></div></div>
</div>

clear all caches -> sometimes is helpfully to use all cache clearing options step by step

ok now have a look at your left menu

you see now all folders collapsed also the higher levels i think

next overwrite template

filter for "treemenu"

select -> /parts/treemenu.tpl from design/base/templates

create a overwrite
edit it

my looks like this

{let docs=treemenu( $module_result.path,
                    $module_result.node_id,
                    ezini( 'MenuContentSettings', 'LeftIdentifierList', 'menu.ini' ), 1, 6 )
                    depth=1}

        <ul>
        {section var=menu loop=$:docs last-value}
            {section show=and($menu.last.level|gt($menu.level),$menu.number|gt(1))}
           </ul>
           </li>
           {/section}
            <li>
            {section show=and($menu.last.level|lt($menu.level),$menu.number|gt(1))}
            <ul>
               <li>
            {/section}

            {set depth=$menu.level}
            <div class="menu-level-{$menu.level}">
            <a {$menu.is_selected|choose('','class="selected"')}
                href={$menu.url_alias|ezurl}>{$menu.text|shorten(25)}</a>
            </div>

           </li>
        {/section}
        </ul>

        {section show=$depth|gt(1) loop=$depth|sub(1)}
         </li>
        </ul>
        {/section}

{/let}

about the used here treemenu() read details here:
http://ez.no/doc/ez_publish/technical_manual/3_10/reference/template_operators/miscellaneous/treemenu

i tuned my menu so that it show all subitems declared in menu.ini [MenuContentSettings] LeftIdentifierList array()
from the second level (1) (first level is 0) to the sixth (6) level deep

tune it like you want - clear chaches - look and feel :-) the debris is css setup i think

i'm sure that now you are not satisfied with fakt that the system display the links for the deeper sublevels in content - is'nt it beastly? for me it was unpossible

looking for a way to change it?

i was gone this way

overwriting this template
/full/folder.tpl from extension/ezwebin/design/ezwebin/override/templates -> full_folder_view_do_not_display_subfolders[.tpl]

one little change

was

line 33          {if le( $node.depth, '3')}
                   {set $classes=array( 'infobox', 'folder' )}

to

 line 33         {if le( $node.depth, '6')}
                    {* set here all classes witch not have to be displayed in the childview of the folder *}
                    {set $classes=array( 'infobox', 'folder', 'article', 'article_mainpage','article_subpage' )}

after clearing cache you doesn't see changes?
thats right - seems the overwrite system not work here

open this file -> /settings/siteaccess/your_siteaccess/overrite.append.ini or edit it for your siteaccess within admin ini tool in section [full_folder]

my shoes like this:

[full_folder]
Source=node/view/full.tpl
MatchFile=full_folder_view_do_not_display_subfolders.tpl
Subdir=templates
Match[class_identifier]=folder

so and now? hope that i haven't forgotten something to write from my diary here

if you have a different solution - please post it here

aha folks! - sorry for my "bewitching" english ;-)
greetinx
bernd