Template:INSA-Lyon/menuA

From 2011.igem.org

(Difference between revisions)
Line 1: Line 1:
-
function afficheMenu(obj){
 
-
 
-
var idMenu    = obj.id;
 
-
var idSousMenu = 'sous' + idMenu;
 
-
var sousMenu  = document.getElementById(idSousMenu);
 
-
 
-
/*****************************************************/
 
-
/** si le sous-menu correspondant au menu cliqué    **/
 
-
/** est caché alors on l'affiche, sinon on le cache **/
 
-
/*****************************************************/
 
-
if(sousMenu.style.display == "none"){
 
-
sousMenu.style.display = "block";
 
-
}
 
-
else{
 
-
sousMenu.style.display = "none";
 
-
}
 
-
 
-
}
 
-
 
<html>
<html>
Line 87: Line 68:
</style>
</style>
-
<div id="menu" onclick="afficheMenu(this)">
+
<div id="menu">
   <ul class="niveau1">  
   <ul class="niveau1">  
     <li><a href="/Team:Lyon-INSA-ENS" title="go to home">Home</a></li>  
     <li><a href="/Team:Lyon-INSA-ENS" title="go to home">Home</a></li>  

Revision as of 13:33, 9 May 2011