Team:BIT-China/js/nav.js

From 2013.igem.org

Revision as of 12:05, 6 August 2013 by Singlewindy (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

$(document).ready(

           function(){
               $("ul.subnav").parent().find("> a").append("");
               $("ul.topnav li").hover(
                   function() {
                       // Hover over
                       $(this).parent().find("ul.subnav").hide();
                       $(this).find("ul.subnav").show();
                       // Hover out
                       $(this).hover(
                           function() {
                           },
                           function(){
                               $(this).find("ul.subnav").hide();
                           }
                       );
                   },
                   function(){
                       $(this).find("ul.subnav").hide();
                   }
               );
           }
       );