htmlArea

A WYSIWYG editor directory and other web components



Your Banner Here for $250 per months

Quality, Affordability, Success
Business Email Marketing Solution
Choose the best email marketing software on the web today.

FatCow Web Hosting

Free Wordpress Themes
Premium free WordPress
Themes and wordpress
development blog

Home : Web Software Components : Menu Builders : Dropdown Menu

Dropdown Menu
  Price: Free
  Rating: 0.00 (0 votes)   Rate It!  
Publisher: SparrowScripts.com
Added: Mon Oct 24 2005
Updated: Mon Oct 24 2005
Supported browsers: Tested on IE6 (Windows) and Netscape 6
   

Description: Introduction

Received some requests for the SparrowScripts.com menu, so decided to post it for everyone's benefit. :) Its also a freeware, so modify it, distribute it for all you want for your personal or commercial purpose, I don't care. Just leave my credits on top, won't you?

How To Use

Include the following two javascript files :

<SCRIPT LANGUAGE="JavaScript" SRC="js/lw_layers.js"></SCRIPT>
<SCRIPT LANGUAGE="JavaScript" SRC="js/lw_menu.js"></SCRIPT>

Then define the menu structure :

<SCRIPT LANGUAGE="JavaScript">
<!--
AddMenuItem (1, 0, "index.htm", "Home", "")
AddMenuItem (2, 0, "dp-intro.htm", "Date Picker", "")
AddMenuItem (21, 2, "dp-intro.htm", "Introduction", "")
AddMenuItem (22, 2, "dp-download.htm", "Downloads", "")
AddMenuItem (23, 2, "dp-credits.htm", "Updates & Credits", "")
AddMenuItem (3, 0, "mn-intro.htm", "Drop Down Menu", "")
AddMenuItem (21, 3, "mn-intro.htm", "Introduction", "")
AddMenuItem (22, 3, "mn-download.htm", "Download", "")
AddMenuItem (4, 0, "testimonial.htm", "Testimonials", "")
//-->
</SCRIPT>

Some points to note here. The AddMenuItem function accepts 5 parameters :

  • Unique Id ( just a unique number will do, for child nodes to point to )
  • Parent Id ( 0 to denote root node )
  • URL ( to go to when selected )
  • Description ( to display on the menu )
  • Image File ( filename to a small icon to display on the left of the option )

    Finally place the following code at the place you wishes to display the menu :

    <SCRIPT LANGUAGE="JavaScript">
    <!--
    DrawMenu()
    //-->
    </SCRIPT>



    Compatibility

    Only tested with IE6 and Netscape 6. Guarantee won't work in Netscape 4 and IE for Macintosh. Perhaps some kind soul would like to fix this issue for me :)

    Disclaimer

    The author will not assume any responsibilities including damages resulting from either proper or improper usage of the script. Hence, use it at your own risk. Bug reports are welcomed, however the author reserve the rights to decide whether to fix them or not (due to having other commitments). In the event the bug cannot be resolved by the author, no responsibilities must be assumed.

  •  

    Report this listing - If this listing has broken links, inaccurate or misleading information, or needs updating please let us know.

    Web Hosting
    VPS UK

    UK Reseller Hosting

    Toner

    UK Web Hosting

    Toner Cartridges