Slide Show 001
myPics = new Array("images/straw.jpg","images/apple.jpg","images/cherry.jpg")
thisPic = 0
imgCt = myPics.length
function rotate() {
if (document.images) {
thisPic++
if(thisPic == imgCt) {
thisPic = 0
}
document.slsh.src=myPics
[thisPic]
setTimeout("rotate()",2*1000)
}
}
A:hover {color: red; font-weight: bold}
Back
Slide Show 001
This is a common script and can have as
many images you need. This script has three parts. Document tag in
pink
Script instructions for <HEAD></HEAD> tags
<SCRIPT LANGUAGE="JAVASCRIPT" TYPE="TEXT/JAVASCRIPT">
myPics = new Array("images/straw.jpg","images/apple.jpg","images/cherry.jpg")
thisPic = 0
imgCt = myPics.length
function rotate() {
if (document.images) {
thisPic++
if(thisPic == imgCt) {
thisPic = 0
}
document.slsh.src=myPics
[thisPic]
setTimeout("rotate()",2*1000)
}
}
</SCRIPT>
Script for <BODY> tag of the HTML
Document
onLoad="rotate()"
Paste where needed in the body of the HTML
document
<img border="3" src="images/straw.jpg"
name="slsh" width="200"
height="267">
Paste script between the <HEAD></HEAD> tags.
myPics = new Array("images/straw.jpg","images/apple.jpg","images/cherry.jpg")
thisPic = 0
imgCt = myPics.length
function rotate() {
if (document.images) {
thisPic++
if(thisPic == imgCt) {
thisPic = 0
}
document.slsh.src=myPics
[thisPic]
setTimeout("rotate()",2*1000)
}
}
Paste into the <BODY> tag
onLoad="rotate()"
Paste script where needed in the body of the HTML Document.
© Copyright 2003
Ultimatephp.com
Wyszukiwarka
Podobne podstrony:
fading slide showslide show 3slide show 0061974 WT Historical Slide Show Info Sheetslide show 5slide show 002slide show (2)show listshow infocan RENAULT CLIO III GRANDTOUR 08 XX PL 001001 PMP cw1v 06 001Zestawy 00103 0000 001 02 Leczenie raka piersi docetakselemwięcej podobnych podstron