Template:Team:HokkaidoU Japan/LargeDropDown/JS
From 2014.igem.org
(Difference between revisions)
Line 1: | Line 1: | ||
<html> | <html> | ||
<script type="text/javascript"> | <script type="text/javascript"> | ||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
$(function() { | $(function() { | ||
var $menu = $('#ldd_menu'); | var $menu = $('#ldd_menu'); | ||
var $child = $menu.children(".menu_button") | var $child = $menu.children(".menu_button") | ||
+ | $child.eq(2).find('.ldd_submenu').css("width","440px"); | ||
+ | $child.eq(3).find('.ldd_submenu').css("width","160px"); | ||
$child.hover(function() { | $child.hover(function() { | ||
var $number = $child.index(this); | var $number = $child.index(this); | ||
- | + | ||
- | + | ||
$child.eq($number).find('.ldd_submenu').slideDown(300); | $child.eq($number).find('.ldd_submenu').slideDown(300); | ||
} ,function(){ | } ,function(){ | ||
$child.find('.ldd_submenu').stop(true,true).slideUp(300); | $child.find('.ldd_submenu').stop(true,true).slideUp(300); | ||
+ | |||
}); | }); | ||
}); | }); | ||
+ | |||
</script> | </script> | ||
</html> | </html> |
Revision as of 16:50, 5 October 2014