Page 1 of 1

[resolu]bmenu 0.4.5 vers 0.4.6

Posted: Thu Jan 24, 2008 4:25 pm
by okoweb
Bonjour!

Quelques nouveautés apporte le module bmenu 0.4.6 par rapport aux anciennes versions?

Franche collaboration !

Gérard depuis le Cameroun

Re: bmenu 0.4.5 vers 0.4.6

Posted: Fri Jan 25, 2008 12:49 pm
by bterkuile
Version 0.4.6 adds a template to the Menu Manager that works best with the bMenu module. From version 0.4.6 you can use the

Code: Select all

{menu template=bMenu}
Call.
This template will work with the default settings of bMenu. I added this template because many people seem to have problems adapting bMenu to their Menu template.

Utilisations

Posted: Fri Jan 25, 2008 2:31 pm
by okoweb
Bonsoir !
bterkuile wrote: Version 0.4.6 adds a template to the Menu Manager that works best with the bMenu module. From version 0.4.6 you can use the
{menu template=bMenu}
Call.
Cela veut dire que tous ces 2 méthodes sont fonctionnelles :
1- Methode
- head

Code: Select all

{cms_module module="bMenu"}

- body à l'endroit d'affichage de mon menu :

Code: Select all

{menu template='simple_navigation.tpl'}
{cms_module module="bMenu" styleid="..."}
- et le template simple_navigation.tpl

Code: Select all

{if $count > 0}
<ul id="primary-nav">
{foreach from=$nodelist item=node}
{if $node->depth > $node->prevdepth}
{repeat string="<ul>" times=$node->depth-$node->prevdepth}
{elseif $node->depth < $node->prevdepth}
{repeat string="</li></ul>" times=$node->prevdepth-$node->depth}
</li>
{elseif $node->index > 0}</li>
{/if}

{if $node->current == true}
<li class="currentpage"><a class="currentpage" href="{$node->url}"{if $node->accesskey != ''} accesskey="{$node->accesskey}"{/if}{if $node->tabindex != ''} tabindex="{$node->tabindex}"{/if}{if $node->titleattribute != ''} title="{$node->titleattribute}"{/if}><dfn>{$node->hierarchy}: </dfn>{$node->menutext}</a>

{elseif $node->parent == true}
<li class="activeparent"><a class="activeparent" href="{$node->url}"{if $node->accesskey != ''} accesskey="{$node->accesskey}"{/if}{if $node->tabindex != ''} tabindex="{$node->tabindex}"{/if}{if $node->titleattribute != ''} title="{$node->titleattribute}"{/if}><dfn>{$node->hierarchy}: </dfn>{$node->menutext}</a>

{elseif $node->type == 'sectionheader'}
<li class="sectionheader">{$node->menutext}

{elseif $node->type == 'separator'}
<li class="separator" style="list-style-type: none;"> <hr />

{else}
<li><a href="{$node->url}"{if $node->accesskey != ''} accesskey="{$node->accesskey}"{/if}{if $node->tabindex != ''} tabindex="{$node->tabindex}"{/if}{if $node->titleattribute != ''} title="{$node->titleattribute}"{/if}{if $node->target != ''} target="{$node->target}"{/if}><dfn>{$node->hierarchy}: </dfn>{$node->menutext}</a>

{/if}

{/foreach}
{repeat string="</li></ul>" times=$node->depth-1}</li>
</ul>
{/if}
2- Methode:
- head

Code: Select all

{cms_module module="bMenu"}
- body

Code: Select all

{menu template=bMenu}
{cms_module module="bMenu" styleid="..."}
A bientôt !