|
先定義 id 為 m
的背景圖網址,填入已上傳的圖檔網址,再將下列語法複製貼於要移動的表單背景下一行。
<img id="m"
style="LEFT: -1800;
POSITION: absolute;
TOP: -1800" src="背景圖網址.jpg或gif"
width="650">
****************************************************
<SCRIPT
language=vbscript>
Dim intervalhandle
Rem this is the
ticker 視窗狀態顯示
window.status=" ~~
背景斜移 ~~"
Rem table1是第一背景圖
table2是第二張圖
table3是第三張圖
x=0
y=0
Sub Window_OnLoad()
scw=document.body.clientWidth
sch=document.body.clientHeight
Clearinterval
(intervalhandle)
intervalhandle=SetInterval
("scrollback",100)
table2.style.backgroundImage="URL("&m.src&")"
End Sub
Rem you can change
the direction of the
scroll by changing
the - or + x是左右移動
y是上下移動
Sub scrollback()
x=x-1
y=y+1
table2.style.backgroundPosition=x&"
"&y
End sub
</SCRIPT>
|