Ho creato questo script , purtroppo non va ^_^
Qualcuno saprebbe trovarmi l'errore ?
index.htm
pagine.jsCodice HTML:<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <title>Alleanza F.A.N.</title> <script language="javascript1.4" type="text/javascript" src="pagine.js"></script> </head> <body> <div id="Layer1" style="position:absolute; width:500px; height:366px; z-index:1; left: 20px; top: 20px;"> <div id="menu" style="position:absolute; width:132px; height:177px; z-index:1; top: 74px; background-color: #D5EFB5; layer-background-color: #D5EFB5; border: 1px none #000000;"> <div align="center"> <p>MENU</p> <p><a href="#" target="_parent" onClick="pagina('Home')">Home</a><br> <a href="#" target="_parent" onClick="pagina('Descrizione')">Descrizione</a><br> <a href="#" target="_parent" onClick="pagina('Membri')">Membri</a><br> <a href="#" target="_parent" onClick="pagina('Statuto')">Statuto</a></p> </div> <div id="overmenu" style="position:absolute; width:132px; height:115px; z-index:2; left: 0px; top: 178px; background-color: #D5EFB5; layer-background-color: #D5EFB5; border: 1px none #000000;"> <div align="center"></div> </div> <div align="center"><a href="#" target="_parent">Forum</a></div> </div> <div id="Layer3" style="position:absolute; width:500px; height:73px; z-index:2; background-color: #D5EFB5; layer-background-color: #D5EFB5; border: 1px none #000000;"><img src="img/banner1.gif" width="500" height="73"></div> <div id="corpo" style="position:absolute; width:367px; height:293px; z-index:3; left: 133px; top: 74px; background-color: #D5EFB5; layer-background-color: #D5EFB5; border: 1px none #000000; overflow: auto;"> <div align="center"></div> </div> </div> </body> </html>
Grazie ^_^Codice:// JavaScript function pagina(tipo){ var tipo = elem.tipo; if(tipo == Home){ document.getElementById("corpo").innerHTML = '..............home.................'; } else if(tipo == Descrizione){ document.getElementById("corpo").innerHTML = '...............descrizione.................'; } else if(tipo == Membri){ document.getElementById("corpo").innerHTML = '...............membri..................'; } else if(tipo == Statuto){ document.getElementById("corpo").innerHTML = '................statuto..................'; } else{ document.getElementById("corpo").innerHTML = '.................home..............'; } }

LinkBack URL
About LinkBacks

