Full version: jsB@nk » Background » DHTML image animation with fade-in-fade-out effect
URL: https://www.javascriptbank.com/dhtml-background-image-animation-with-fade-in-fade-out-effect.html
Enhances your image presentation with a smooth dynamic motion (fade-in-fade-out). Great to bring your images alive! Loads much faster than any gif-animations. Easy to configure.
Full version: jsB@nk » Background » DHTML image animation with fade-in-fade-out effect
URL: https://www.javascriptbank.com/dhtml-background-image-animation-with-fade-in-fade-out-effect.html
<script language="javascript">/* This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com*/<!-- Beginning of JavaScript -// Author: Peter Gehrig // Web Site: http://www.24fun.com img0 = new Image();img0.src = "../image/pic191.jpg";img1 = new Image();img1.src = "../image/homer.jpg";img2 = new Image();img2.src = "../image/logojs.gif";var i_strngth=1var i_image=0var imageurl = new Array()imageurl[0] ="../image/pic191.jpg"imageurl[1] ="../image/homer.jpg"imageurl[2] ="../image/logojs.gif"function showimage() {if(document.all) {if (i_strngth <=80) {testimage.innerHTML="<img style='filter:alpha(opacity="+i_strngth+")' src="+imageurl[i_image]+" border=0>";i_strngth=i_strngth+3var timer=setTimeout("showimage()",400)}else {clearTimeout(timer)var timer=setTimeout("hideimage()",1000)}}if(document.layers) {clearTimeout(timer)document.testimage.document.write("<img src="+imageurl[i_image]+" border=0>")document.close()i_image++if (i_image >= imageurl.length) {i_image=0}var timer=setTimeout("showimage()",2000)}}function hideimage() {if (i_strngth >=-3) {testimage.innerHTML="<img style='filter:alpha(opacity="+i_strngth+")' src="+imageurl[i_image]+" border=0>";i_strngth=i_strngth-4var timer=setTimeout("hideimage()",400)}else {clearTimeout(timer)i_image++if (i_image >= imageurl.length) {i_image=0}i_strngth=1var timer=setTimeout("showimage()",500)}}// - End of JavaScript - --></script><!-- This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->
<body onLoad="showimage()"><div id="testimage" style="position:absolute;visibility:visible;top:0px;left:0px"></div><div id="mainbod" style="position:absolute;visibility:visible;top:10px;left:10px;"></div></body><!-- This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->