Вот так делаются титры
| Код | <html> <head> <title> Титры</title> </head> <body bgcolor=white onLoad="init()"> <script language=javascript> <!-- //global variables var layerRef="null",layerStyleRef="null",styleSwitch="null",topStopPoint="null",layerRef="null",styleSwitch="null",currtop=-100; var topStopPoint=-700,d=document.referrer; var backupTopStopPoint=topStopPoint; var currTop=600; var pxSwitch="null"; var moving=1; var k=0; function init() { if (navigator.appName == "Netscape") { layerStyleRef="layer."; layerRef="document.layers"; styleSwitch=""; pxSwitch=""; } else { layerStyleRef="layer.style."; layerRef="document.all"; styleSwitch=".style"; pxSwitch="px"; } moveLayerUp('credits',k); } function pause(layerName) { moving*=-1; if(moving<0) topStopPoint=currTop+pxSwitch; else { topStopPoint=backupTopStopPoint; moveLayerUp(layerName,k); } } function restart(layerName) { k++; currTop=600; topStopPoint=backupTopStopPoint; if(moving<0) { moving*=-1; moveLayerUp(layerName,k); } }
function moveLayerUp(layerName,n) { if (eval(layerRef+'["'+layerName+'"]'+styleSwitch+'.top != topStopPoint')) { currTop-=4; eval(layerRef+'["'+layerName+'"]'+styleSwitch+'.top = currTop'); setTimeout('moveLayerUp("'+layerName+'",'+n+')',50); } } //--> </script>
<style type="text/css"> #text {z-index: 2; position: absolute; left: 15px; top: 15;} #credits {z-index: 1; position: absolute; top: 0; left: 30px; width: 300px;} </style>
<div id="text">Text</div>
<div id="credits"> <font face=arial> All trade marks and brand names are acknowledged as belonging to their respective owners. <br><br> <b>Authors</b> </font> </div>
</body> </html>
| |