Line 101: | Line 101: | ||
} | } | ||
+ | .show {display:block;} | ||
/* Wrapper for the menu */ | /* Wrapper for the menu */ | ||
Line 503: | Line 504: | ||
− | <li> <a href="">TEAM <span class="arrow">▼</span></a> | + | <li> <a href="" onclick="myFunction(team)">TEAM <span class="arrow">▼</span></a> |
− | <ul class="sub-menu"> | + | <ul class="sub-menu" id="team"> |
<li> <a href=" https://2016.igem.org/Team:Austin_UTexas/Team"> Team </a> </li> | <li> <a href=" https://2016.igem.org/Team:Austin_UTexas/Team"> Team </a> </li> | ||
<li> <a href="https://2016.igem.org/Team:Austin_UTexas/Collaborations">★ Collaborations </a> </li> | <li> <a href="https://2016.igem.org/Team:Austin_UTexas/Collaborations">★ Collaborations </a> </li> | ||
Line 650: | Line 651: | ||
}); | }); | ||
+ | |||
+ | /* When the user clicks on the button, | ||
+ | toggle between hiding and showing the dropdown content */ | ||
+ | function showSubMenu(menu) { | ||
+ | document.getElementById(menu).classList.toggle("show"); | ||
+ | } | ||
Revision as of 06:02, 18 October 2016