#fcleft">



Are you sick of a static background? Use this script to animate you background. This script can move your background in 8 different directions. It's really soothing to your viewers. Be sure to check out the color coding because it's rather hard to figure out. Finally, this script ONLY works for MSIE4.0+ and NS4.5+.
The source..


<body background="back.gif">
<script language="Javascript">
<!--
// please keep these lines on when you copy the source
// made by: Nicolas - http://www.javascript-page.com

var background = "/~jsmaster/back.gif";
var speed = 0;

browserName = navigator.appName;
browserVer = parseInt(navigator.appVersion);

if (browserName != "Netscape" || browserVer >= 4.5) {

function moveback(movert,movedn,hPos,vPos) {
 
  if (arguments[4])
    document.body.style.backgroundImage = "url(\"" + arguments[4] + "\")";
 
  if (arguments[5])
    document.body.style.backgroundRepeat = arguments[5]
 
  if (!isNaN(hPos)) {
    if ((movert!=0) && (hPos>0)) hPos=-100000
    hPos += movert
  } 
  if (!isNaN(vPos)) {
    if ((movedn!=0) && (vPos>0)) vPos=-100000
    vPos+= movedn
  }
 
  document.body.style.backgroundPosition= hPos + " " + vPos
  if (isNaN(hPos))  hPos = "\"" + hPos + "\""
  if (isNaN(vPos)) vPos = "\"" + vPos + "\""
setTimeout("moveback("+movert+","+movedn+","+hPos+","+vPos+")",speed)
}
 
moveback(1,1,0,0, background);
}

//-->
</script>


Color coding..


This is the URL of the background image you wish to animate. It is IMPERATIVE that you declare the URL of the image twice.
This is the speed at which the background moves.
This is the direction in which the background moves. The first "1" is the horizontal direction. A "1" moves the background right, a "-1" moves it left, and a "0" keeps it put. The second "1" is the vertical direction. A "1" moves the background down, a "-1" moves it up, and a "0" keeps it put.

kick arse with your own free website
This banner was supplied by SAFE Audit