Help With Accordion Menu

Dear Sirs,

I have the accordion effect working great however, I want to retain the menu state (e.g. which section is open) when a user clicks a particular link and the site loads a new page.

How do I do this?.

Also, when the name of the element its biger than the the accordion menu width it does not work properly, how do i do to make the menu to rearreange the height of one element to fit all the name?

e.g:


 <?php

 $items = array(

  array(

    'name' => 'NORMAL SIZE',

    'link' => '#',

    'icon' => 'google',

    'active' => 'dashboard', 

    'sub' => array(

      array(

        'name' => 'THIS IS THE VERYYYYY LONG NAMEEE THAT IM TELLING YOU',

        'link' => '#',

      ),

        array(

        'name' => 'normal size 2',

        'link' => '#',

      ),

      array(

          'name' => 'another normal size',

        'link' => '#',

      ),

      array(

        'name' => 'normal size 3',

        'link' => '#',

      ),

      array(

        'name' => 'THIS IS ANOTHEEEEEEER VERYYYY LONG NAMEEE THAT IM TELLING YOU',

        'link' => '#',

      ),

    )

  )

);

?>

in the layout main i call the menu like this


 <div class="span-8 last">

                <div id="sidebar">

            <?php $this->widget('ext.menu.EMenu', array('items' => $items)); ?>

        

        </div>

        </div>

Ps: I need to use the colspan-8 because its the width i need in my web app.

Also, i send you a screen capture of what i’m talking about

Thanks in Advance

Good night, i dont know if you solve your problem with that extension, but i did, if it helps you in any way.

if you want the menu to be active in a controller that it is not in protected/controllers

you have to put in active like this:

‘active’=>'nameofyourextensionnomatterwhereitis/namecontroller

for instance im using cruge extension and i wanted to use the accordion menu to organize the cruge admin menu

but this views are from the cruge controller named ‘ui’

so to use the menu it worked like this:


$items = array(

      'name' => 'Documentation',

      'link' => $this->createUrl('#'),

      'icon' => 'list',

      'active' => 'cruge/ui',

      'sub' => array(

        10 => array(

          'name' => 'General',

          'link' => $this->createUrl('#'),

          'active' => '/modules/cruge/ui/usermanagementadmin',

        ),))






i hope it helped you in some way.

Greetings