|
<script language="JavaScript"> <!--
//Specify the marquee's width (in pixels)
var marqueewidth=200
//Specify the marquee's height (in pixels, pertains only to NS)
var marqueeheight=20
//Specify the marquee's scroll speed (larger is faster)
var speed=5
//Specify the marquee contents
var mcontents='<a href="http://akmac.narod.ru/">JavaScript</a> подборка JavaScript, DHTML, фильтров работающих как в Internet Explorer, так и в Netscape Navigator.'
if (document.all)
document.write('<marquee scrollAmount='+speed+' style="width:'+marqueewidth+'">'+mcontents+'</marquee>')
function regenerate(){
window.location.reload()
}
function regenerate2(){
if (document.layers){
setTimeout("window.onresize=regenerate",450)
intializemarquee()
}}
function intializemarquee(){
document.cm01.document.cm02.document.write ('<nobr>'+mcontents+'</nobr>')
document.cm01.document.cm02.document.close()
thelength=document.cm01.document.cm02.document.width
scrollit()
}
function scrollit(){
if (document.cm01.document.cm02.left>=thelength*(-1)){
document.cm01.document.cm02.left-=speed
setTimeout("scrollit()",100)
}
else{
document.cm01.document.cm02.left=marqueewidth
scrollit()
}}
window.onload=regenerate2
//--> </script>
В том месте, где необходимо, пишется следующий код:
<ilayer width=&{marqueewidth}; height=&{marqueeheight}; name="cm01"> <layer name="cm02"> </layer> </ilayer>
|