imgwidth=177
imgheight=166
imgPauseTime=10000
imgSpeed=20
chgLoop=0
imgCount=0
doChg=true
imgSrc=new Array()
imgURL=new Array()
imgSrc[0]="/images/advpics/2007062351.gif"
imgURL[0]="木靈芝"
imgSrc[1]="/images/advpics/2007062313.gif"
imgURL[1]="冬蟲夏草"
imgSrc[2]="/images/advpics/2007062353.gif"
imgURL[2]="北黃耆片"
imgSrc[3]="/images/advpics/2007062316.gif"
imgURL[3]="白芷片"
imgSrc[4]="/images/advpics/2007062356.gif"
imgURL[4]="白芷條"
imgArray=new Array()
for (x=0;x<=imgSrc.length-1;x++) {
imgArray[x]=new Image()
imgArray[x].src=imgSrc[x]
}
function imgIni() {
doChg=true
imgCount++
if (imgCount>=imgSrc.length){
imgCount=0
}
imgStretch()
}
function imgStretch() {
if(doChg){
if (chgLoop<=100) {
if (document.all) {
imgArea.innerHTML="
"
}
chgLoop+=10
timer=setTimeout("imgStretch()",imgSpeed)
} else {
chgLoop=100
clearTimeout(timer)
imgArea.innerHTML="
"
timer=setTimeout("imgShirk()",imgPauseTime)
}
}
}
function imgShirk() {
if(doChg){
if (chgLoop>=0) {
if (document.all) {
imgArea.innerHTML="
"
}
chgLoop-=10
timer=setTimeout("imgShirk()",imgSpeed)
} else {
chgLoop=0
clearTimeout(timer)
imgIni()
}
}
}
function mouse_in() {
document.myPic.style.filter="Alpha(Opacity=100)"
doChg=false
}
function mouse_out() {
document.myPic.style.filter="Alpha(Opacity=100)"
doChg=true
clearTimeout(timer)
imgStretch()
}