Horizontal Javascript Accordion Menu!

Thu, Nov 27, 2008

Javascript, Other, Scripts

This versatile 1kb horizontal accordion script can be used for menus, images, presentation content and more.

The script will automatically adjust to the number of elements in the accordion and the dimensions of the accordion.

The front-end markup for the script is a simple unordered list as in the example below…

<ul id="sm" class="sm">
<li><img src="images/1.gif" alt="" /></li>
<li><img src="images/2.gif" alt="" /></li>
<li><img src="images/3.gif" alt="" /></li>
<li><img src="images/4.gif" alt="" /></li>
</ul>

To build the accordion call the function below onload…

slideMenu.build('sm',200,10,10,1)

Click here to view the working sample.

Share/Save/Bookmark

Related Posts

,

This post was written by:

Mike - who has written 263 posts on Open Source Resources for Designers & Developers | Greepit.com.


2 Comments For This Post

  1. Reader Says:

    Good work! Thank you very much!
    I always wanted to write in my site something like that. Can I take part of your post to my blog?
    Of course, I will add backlink?

    Regards, Your Reader

  2. Saif Says:

    @Reader:
    Thank you for your liking.

    Yes, you can post to your blog with a backlink.

    Thank you!
    Saif

Leave a Reply