Share » Forums » Setup & design » Display small icon when an object has...

Display small icon when an object has child-objects

Display small icon when an object has child-objects

Tuesday 28 September 2004 11:35:59 am - 1 reply

Modified on Tuesday 28 September 2004 11:39:32 am by willy jansen

Author Message

willy jansen

Tuesday 09 November 2004 7:37:38 am

I now use the (ugliest of all solutions): I check what the id of the node that is shown in the menu is and place a "plus" sign before... :'( ... the best I could come up with

did anybody implement a more elegant solution?

{let docs=treemenu( $module_result.path, 
                    $module_result.node_id,
                    array('folder'), 2, 2 )
                    depth=1}

        {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}


{* $menu|attribute(show) *}

{section name=plus show=$menu.id|eq(117)}+{/section}
{section name=plus show=$menu.id|eq(118)}+{/section}
            <a {$menu.is_selected|choose('','class="selected"')}
                href={$menu.url_alias|ezurl}>{$menu.text|shorten(35)}</a>

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

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

        {/let}

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu