Les avertissements suivants se sont produits :
Warning [2] Undefined array key 0 - Line: 1640 - File: showthread.php PHP 8.2.18 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/showthread.php 1640 errorHandler->error_callback
/showthread.php 915 buildtree




Note de ce sujet :
  • Moyenne : 0 (0 vote(s))
  • 1
  • 2
  • 3
  • 4
  • 5
Problème Menu déroulant [Résolu]
#11
Code :
{strip}
{if $count > 0}
<ul class="menu-nav">
{foreach from=$nodelist item=node}
{if $node->depth > $node->prevdepth}
{repeat string="<div class='ulwrapper'><ul>" times=$node->depth-$node->prevdepth}
{elseif $node->depth < $node->prevdepth}
{repeat string="</li></ul>" times=$node->prevdepth-$node->depth}
</div></li>
{elseif $node->index > 0}</li>
{/if}
{if $node->current == true && $node->depth == 1}
<li class="current"><a href="{$node->url}" {if $node->target ne ""} target="{$node->target}"{/if}><strong>{$node->menutext}</strong></a>
{elseif $node->parent == true && $node->depth == 1}
<li class="top parent item"> <a href="{$node->url}" {if $node->target ne ""} target="{$node->target}"{/if}><strong>{$node->menutext}</strong></a>
{elseif $node->depth == 1}
<li class="top item"> <a href="{$node->url}" {if $node->target ne ""} target="{$node->target}"{/if}><strong>{$node->menutext}</strong></a>
{else}
<li><a href="{$node->url}" {if $node->target ne ""} target="{$node->target}"{/if}><strong>{$node->menutext}</strong></a>
{/if}
{/foreach}
{repeat string="</li></ul>" times=$node->depth-1}</li>
</ul>
{/if}
{/strip}
Si ça buggue sur le current, remet id au lieu de class (peut-être à cause du JS).


Messages dans ce sujet

Atteindre :


Utilisateur(s) parcourant ce sujet : 2 visiteur(s)