Team:UNITN-Trento/JS/Subs/Header
From 2013.igem.org
(Difference between revisions)
(add .stop()) |
|||
Line 4: | Line 4: | ||
//Open the submenu | //Open the submenu | ||
$("#tn-menu li").mouseenter(function(e) { | $("#tn-menu li").mouseenter(function(e) { | ||
+ | alert(1); | ||
e.preventDefault(); | e.preventDefault(); | ||
$(this).children("ul").stop().slideDown(); | $(this).children("ul").stop().slideDown(); |
Revision as of 12:34, 9 August 2013
//Javascript here $(document).ready(function() {
//Open the submenu $("#tn-menu li").mouseenter(function(e) { alert(1); e.preventDefault(); $(this).children("ul").stop().slideDown(); });
//Close the submenu $("#tn-menu li").mouseleave(function(e) { e.preventDefault(); $(this).children("ul").stop().slideUp(); });
});