Первый
<SCRIPT LANGUAGE="JavaScript"> <!-- Beginning of JavaScript - var picOne=new Image() picOne.src="86-1.jpg" var picTwo=new Image() picTwo.src="86-2.jpg" var picThree=new Image() picThree.src="86-3.jpg" var message = new Array() message[0]="<img src='86-1.jpg'>" message[1]="<img src='86-2.jpg'>" message[2]="<img src='86-3.jpg'>" var i_message=0 var covertop=50 var coverleft=400 var coverwidth=1200 var coverheight=520 var texttop=covertop var textleft=coverleft var textwidth=400 var textheight=coverheight var cliptop=0 var clipright=textwidth var clipbottom=coverheight var clipleft=0 var clippoints var step=40 var pause=50 var timer function init() { if (document.all) { document.all.text.style.posTop=texttop document.all.text.style.posLeft=textleft document.all.cover.style.posTop=covertop document.all.cover.style.posLeft=coverleft clipleft=0 fadeout() } if (document.layers) { document.text.top=texttop document.text.left=textleft document.cover.top=covertop document.cover.left=coverleft clipleft=0 fadeout() } } function fadeout() { if (document.all) { if (document.all.cover.style.posLeft >=(-coverwidth+textwidth+coverleft+step)) { clipleft+=step clipright=clipleft+textwidth clippoints="rect("+cliptop+" "+clipright+" "+clipbottom+" "+clipleft+")" document.all.cover.style.clip=clippoints document.all.cover.style.posLeft-=step timer= setTimeout("fadeout()",pause) } else { clearTimeout(timer) i_message++ if (i_message>=message.length) {i_message=0} text.innerHTML=message[i_message] fadein() } } if (document.layers) { if (document.cover.left >=(-coverwidth+textwidth+coverleft+step-22)) { clipleft+=step clipright=clipleft+textwidth document.cover.clip.top=cliptop document.cover.clip.left=clipleft document.cover.clip.bottom=clipbottom document.cover.clip.right=clipright document.cover.left-=step timer= setTimeout("fadeout()",pause) } else { clearTimeout(timer) i_message++ if (i_message>=message.length) {i_message=0} document.text.document.write(message[i_message]) document.text.document.close() fadein() } } } function fadein() { if (document.layers) { if (document.cover.left<=coverleft) { clipleft-=step clipright=clipleft+textwidth document.cover.clip.top=cliptop document.cover.clip.left=clipleft document.cover.clip.bottom=clipbottom document.cover.clip.right=clipright document.cover.left+=step timer= setTimeout("fadein()",pause) } else { clearTimeout(timer) init() } } if (document.all) { if (document.all.cover.style.posLeft<=coverleft) { clipleft-=step clipright=clipleft+textwidth clippoints="rect("+cliptop+" "+clipright+" "+clipbottom+" "+clipleft+")" document.all.cover.style.clip=clippoints document.all.cover.style.posLeft+=step timer= setTimeout("fadein()",pause) } else { clearTimeout(timer) init() } } } // - End of JavaScript - --> </SCRIPT>
Второй
<script language="JavaScript"> imgnum=0 // Начальные значения рисунков slideimg=new Array() slideimg[0]=new Image() slideimg[1]=new Image() slideimg[2]=new Image() slideimg[3]=new Image() // Здесь указываются рисунки, которые будут показываться slideimg[0].src="slidimg1.gif" slideimg[1].src="slidimg2.gif" slideimg[2].src="slidimg3.gif" slideimg[3].src="slidimg4.gif" function showslides(){ document.images[0].src=slideimg[imgnum].src imgnum++ if(imgnum==4) // Количество показываемых рисунков imgnum=0; // Здесь задаётся время, через которое будут меняться рисунки (1000 = 1 секунда) setTimeout("showslides()", 2000) } </script> <body bgcolor="#FFFFFF" onLoad="showslides()"> <p><img src="slidimg1.gif" width="171" height="95"></p>
Третий
<style type="text/css"> .imgsstyle { position:absolute; left:-2000px; } A { color:FF0000; } </STYLE> <SCRIPT LANGUAGE="JavaScript"> <!-- // The file-names of your slideshow's images var imgsname = new Array() imgsname[0]="bannertransj1.gif" imgsname[1]="bannertransj2.gif" imgsname[2]="bannertransj3.gif" // the links for each image var imgsurl = new Array() imgsurl[0]="http://www.yahoo.com" imgsurl[1]="http://www.altavista.com" imgsurl[2]="http://www.excite.com" // Configure the distance to the left and top margin of the window (pixels) var imgstop=20 var imgsleft=20 // Configure the speed of the transition effect. less means faster var pause=80 // Configure the standstill-time of the images (seconds) var standstill=3000 // Do not change the variables below this line var imgpreload=new Array() for (i=0;i<=imgsname.length-1;i++) { imgpreload[i]=new Image() imgpreload[i].src=imgsname[i] } var coverimage = new Array() coverimage[0]="imgtransj115.gif" coverimage[1]="imgtransj215.gif" coverimage[2]="imgtransj315.gif" coverimage[3]="imgtransj415.gif" coverimage[4]="imgtransj515.gif" coverimage[5]="imgtransj615.gif" coverimage[6]="imgtransj715.gif" coverimage[7]="imgtransj815.gif" coverimage[8]="imgtransj915.gif" coverimage[9]="imgtransj1015.gif" coverimage[10]="imgtransj1115.gif" coverimage[11]="imgtransj1215.gif" coverimage[12]="imgtransj1315.gif" coverimage[13]="imgtransj1415.gif" coverimage[14]="imgtransj1515.gif" var covimgpreload=new Array() for (i=0;i<=coverimage.length-1;i++) { covimgpreload[i]=new Image() covimgpreload[i].src=coverimage[i] } var i_imgs=0 var i_loop=0 var thisurl=0 var timer stamdstill=standstill*1000 function init() { if (document.all) { document.all.imgs.style.posTop=imgstop document.all.imgs.style.posLeft=imgsleft document.all.cover.style.posTop=imgstop document.all.cover.style.posLeft=imgsleft enlargehearts() } if (document.layers) { document.imgs.top=imgstop document.imgs.left=imgsleft document.cover.top=imgstop document.cover.left=imgsleft enlargehearts() } } function enlargehearts() { if (i_loop<=coverimage.length-1) { if (document.all) { imgcover.src=coverimage[i_loop] } if (document.layers) { document.cover.document.imgcover.src=coverimage[i_loop] } i_loop++ timer= setTimeout("enlargehearts()",pause) } else { clearTimeout(timer) i_loop-- timer= setTimeout("shrinkhearts()",standstill) } } function shrinkhearts() { if (i_loop>=0) { if (document.all) { imgcover.src=coverimage[i_loop] } if (document.layers) { document.cover.document.imgcover.src=coverimage[i_loop] } i_loop-- timer= setTimeout("shrinkhearts()",pause) } else { clearTimeout(timer) i_loop=0 i_imgs++ if (i_imgs>=imgsname.length) {i_imgs=0} if (document.all) { imgsback.src=imgsname[i_imgs] } if (document.layers) { document.imgs.document.imgsback.src=imgsname[i_imgs] } timer= setTimeout("enlargehearts()",(4*pause)) } } function gotourl() { document.location.href=imgsurl[i_imgs] } // - End of JavaScript - --> </SCRIPT> </HEAD> <BODY bgcolor=FFFFFF onLoad="init()"> <DIV ID="imgs" class="imgsstyle"><img width=468 height=60 name="imgsback" src="bannertransj1.gif" border="0" target="_blank"></DIV> <DIV ID="cover" class="imgsstyle"><a href="javascript:gotourl()"><img width=468 height=60 name="imgcover" src="imgtransj1.gif" border="0" target="_blank"></a></DIV>