»
AnglaisFran�aisVietnamien

Imprimer - Floating images II - JavaScriptBank.com

Version compl�te: jsB@nk » Image » Floating images II
URL: https://www.javascriptbank.com/floating-images-ii-up-down.html

Floating images II © JavaScriptBank.comImages flottantes II anime toute image (ou bloc de HTML) et les navigateur fenêtre, comme un ascenseur, et les séjours en vue même si l'utilisateur fait défiler la page. Going up personne?

Version compl�te: jsB@nk » Image » Floating images II
URL: https://www.javascriptbank.com/floating-images-ii-up-down.html



JavaScript
<SCRIPT LANGUAGE="JavaScript">// Bruce W.Anderson ([email protected])<!-- Beginvar xPosLeft = 20;var xPosRight = 800;var step = 1;var delay = 30;var yPos = 0;var height = 0;var offset = 0;var yon = 0;var name = navigator.appName;if (name == "Microsoft Internet Explorer") {yPos = document.body.clientHeight;xPosRight = document.body.clientWidth - 150;point1.style.top = yPos;point2.style.top = yPos;}else {yPos = window.innerHeight;document.point1.pageY = yPos;document.point1.visibility = "hidden";document.point2.pageX = window.innerWidth - 155;}function changePos() {if (yon == 0) {yPos = yPos - step;}else {yPos = yPos + step;}if (name == "Microsoft Internet Explorer") {height = document.body.clientHeight;offset = point1.offsetHeight;}else {height = window.innerHeight;offset = document.point1.clip.height;}  if (yPos < 0) {yon = 1;yPos = 0;}if (yPos >= (height - offset)) {yon = 0;yPos = (height - offset);}if (name == "Microsoft Internet Explorer") {point1.style.left = xPosLeft;point1.style.top = yPos + document.body.scrollTop;point2.style.left = xPosRight;point2.style.top = yPos + document.body.scrollTop;}else {document.point1.pageX = xPosLeft;document.point1.pageY = yPos + window.pageYOffset;document.point2.pageX = xPosRight;document.point2.pageY = yPos + window.pageYOffset;   }}function start(){if (name != "Microsoft Internet Explorer") {document.point1.visibility = "visible";}loopfunc();}function loopfunc(){changePos();setTimeout('loopfunc()',delay);}//  End --></script><!--    This script downloaded from www.JavaScriptBank.com    Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->


HTML
<BODY onLoad="start()"><div id="point1" STYLE="position:absolute;visibility:visible;"><img src="logojs.gif" width=150 height=48 border=0></div><div id="point2" STYLE="position:absolute;visibility:visible;"><img src="logojs.gif" width=150 height=48 border=0></div></body><!--    This script downloaded from www.JavaScriptBank.com    Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->