Skip to the content
Documentation

A note about NavigationPartIdentifier

No ratings yet

The comments in the ini file itself give a faint idea about correct usage of NavigationPartIdentifier:
- to alter the left-column menu in a custom module view, the file module.php needs to be edited, adding default_navigation_part to the view definition
- to create content for that menu, create a template (eg. templates/admin/parts/mymodule/menu.tpl), and assign its url to $Result in the view code: $Result['left_menu'] = 'design:parts/mymodule/menu.tpl';
- the NavigationPartIdentifier ini setting present in menu.ini by itslef does not switch or alter the navigation part displayed in the left column. It is only used by the admin templates to find out what the current menu is so that it can be shown highlighted! (ie. the ini value is matched against the value set in module.php)

Comments (1 historical)

Written by readers of the earlier documentation sites, kept as they were.

  1. Re: A note about NavigationPartIdentifier

    Eirik Johansen ·

    For those of you trying to create a custom left menu on an older Exponential version (and yes, before you say anything, I know that these are the docs for eZP 4.0, but I figured that there might be others out there as stupid as me), please note that the ability to use custom left menus was added in v. 3.8.
    However, adding support for it in v. 3.5 and later is fairly easy. Just create an override of the admin pagelayout, and add the following code after:

    {section show=eq( $navigation_part.identifier, 'ezmynavigationpart' )}    {include uri='design:parts/my/menu.tpl'}{/section}

    and before

    {/section}

    Code to add:

    {section show=is_set( $module_result.left_menu )}{include uri=$module_result.left_menu}{/section}