/** * This code changes the default behavior of the navbar: * now the submenu pops in when the user rolls his mouse * over the parent level menu entry. * Many tanks to Hanzi for this idea and code! */ jQuery(document).ready(function($) { $('ul.nav li.dropdown, ul.nav li.dropdown-submenu').hover(function() { $(this).find(' > .dropdown-menu').stop(true, true).delay(200).fadeIn(); }, function() { $(this).find(' > .dropdown-menu').stop(true, true).delay(200).fadeOut(); }); });