我有段让背景移动的代码。可是它只是横着移。我想让他向下移动要 怎么改
<script language="JavaScript">
var backgroundOffset=0;
var bgObject=eval('document.body');
function scrollBG(maxSize){
backgroundOffset=backgroundOffset+1;
if(backgroundOffset>maxSize)backgroundOffset=0;
bgObject.style.backgroundPosition="0"+backgroundOffset;
}
var ScrollTimer=window.setInterval("scrollBG(307)",64);
</script> 作者:
自由 时间: 2006-4-17 14:06
<script language="JavaScript">
var backgroundOffset=0;
function scrollBG(maxSize){
backgroundOffset=backgroundOffset+1;
if(backgroundOffset>maxSize)backgroundOffset=0;
document.body.style.backgroundPositionY="0"+backgroundOffset;
}
var ScrollTimer=window.setInterval("scrollBG(307)",64);
</script>