Removing drop down menu in javascript

I have created a menu in html that slides down from behind the header. Al, this works perfectly. I click the button the menu the menu slides down click it again it slides up. I was wondering is there a way I could add a rollout function to this. I have tried but the menu consists of various columns where the data is brought from php. I added a rollover the main page which worked but sometimes stopped the initial drop as the mouse was allready over the page. I was thinking would it be possible to add this function to any other element on the page that isn't the menu or the contained divs within the menu, when the menu is down and then remove the function to return the menu when the menu is returned.

This is what I have so far:

<div class="nav_btn_drop_down" onclick="toggle_menu(this,'clothing',menu_toggle)"><a>CLOTHING&nbsp;<img src="global.includes/small_icon_down.png" width="10" height="10"  /></a></div>

var menu_toggle = false;
    function toggle_menu(f,s,t){
        if(t === false){
            document.getElementById('menu').style.opacity = 1;
            menu_toggle = true;
            menu_toggle = false;
                document.getElementById('menu').style.opacity = 0;


Need Your Help

Which would be the best implementation strategy for a dynamic system with stick-slip friction

math physics numeric microsoft-dynamics

I'm trying to build a theoretical model of a lead screw drive to involve in mbs-simulations as a force element. Which means F=blackbox(u) I simplified the system into a represantative model in...

Is there any way to make multiple checkboxes for each item in the list?

sencha-touch extjs sencha-touch-2

What i want to achieve is putting a list in one of the carousel page and in the list there must be a checkbox and a labelfor each line and of course there is multiple items in the list , while i was

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.