Results 1 to 3 of 3

Thread: Accordian Menu Script

  1. #1
    Join Date
    Apr 2009
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Accordian Menu Script

    Hi,

    I have used this accordian script and works perfect, only 2 small problems

    1: When I load the page, the 1st menu stays open, I have to physically click on "the collection"(check attachment) to close it,how can i get it ,when i open the page it stays closed and only when i click on the menu, it opens,

    2: If you look at the attachment again, I want to be able to expand the drop downs aswell, so you click on the collection, it slides down, and then if i click on africa, that slides down again for another option, hope that makes sense???

    I have done everything it says in the "how to page" and have not changed any code


    http://www.dynamicdrive.com/dynamici...ordionmenu.htm

    Please can you help!!

    Thanks

  2. #2
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    To answer your questions:

    1) Make sure the defaultexpanded option is set to empty. You'll probably also want to turn off persistence:

    Code:
    	defaultexpanded: [], //index of content(s) open by default [index1, index2, etc]. [] denotes no content
    	onemustopen: false, //Specify whether at least one header should be open always (so never all headers closed)
    	animatedefault: false, //Should contents open by default be animated into view?
    	persiststate: false, //persist state of opened contents within browser session?
    2) The script does support nested accordions. Take a look at the second example on this page: http://www.dynamicdrive.com/dynamici...enu-bullet.htm
    DD Admin

  3. #3
    Join Date
    Apr 2009
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Hi,

    Thanks, that seemed to work very well with what I want to do, only thing I wanted to ask you is as you can see in the above image again, i know its not the right one,I am using the nested accordian nav, but im sure this will work anyway, you see where it says collection, experience, i have been trying to add 3 more of those main menu headings,all im doing is copying this code and placing it under the next one

    <h3 class="menuheader expandable">The Collection</h3>
    <ul class="categoryitems">
    <li><a href="#" class="subexpandable">Africa</a>

    <ul class="subcategoryitems" style="margin-left: 15px">
    <li><a href="#">South Africa</a></li>
    <li><a href="#">Madagascar</a></li>
    <li><a href="#">Kenya</a></li>
    <li><a href="#">Tanzania</a></li>

    </ul>

    That in theory should create another 1 right????

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •