francescobigozzi (Normal User)
Rookie
Messaggi: 30
Iscritto: 29/01/2010
|
Questo topic è stato chiuso dal moderatore Dove sbaglio?
CODICE HTML
Codice sorgente - presumibilmente Javascript |
[...] <body onload="init(100);"> <center> <img src="images/logo.png" alt="" onmouseover="menu();" /> <div id="menu"> [...] </div> </center> [...]
|
CODICE JS
Codice sorgente - presumibilmente Delphi |
<script type="text/javascript"> var delay = null; var margin = null; var menu = null; var max = 0; function init(slidedelay) { var prop = windows.getComputedStyle(document.getElementById('menu'), ''); margin = parseInt(prop.getPropertyValue('margin-top')); menu = windows.document.getElementById('menu'); delay = slidedelay; } function menu() { if (margin < max) { menu.style.marginTop = margin + 10 + "px"; margin += 10; margin = 100; setTimeout('menu()', delay); } } </script>
|
Ultima modifica effettuata da francescobigozzi il 19/12/2010 alle 14:33 |