图片自动滚动方法
<script language="java script"> var adImg = new Array(); var adLink = new Array(); var cID = 0; adImg[0] = "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59561.jpg"; adLink[0] = "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59558.jpg"; adImg[1] = "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59558.jpg"; adLink[1] = "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59559.jpg"; adImg[2] = "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59559.jpg"; adLink[2] = "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59562.jpg"; adImg[3] = "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59562.jpg"; adLink[3] = "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59564.jpg"; adImg[4] = "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59564.jpg"; adLink[4] = "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59563.jpg"; adImg[5]= "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59563.jpg"; adImg[5]= "http://woaini1989112.blog.enorth.com.cn/attachment/pic/59563.jpg"; var preImgs = new Array(); for(i=0;i<5;i ) { preImgs[i] = new Image(); preImgs[i].src = adImg[i]; } function NextAd() { if(cID == 5)cID=0; if(document.all) { imgAD.filters.revealTrans.Transition=Math.floor(Math.random()*23); imgAD.filters.revealTrans.apply(); imgAD.src = adImg[cID]; imgAD.filters.revealTrans.play(); cID ; setTimeout("NextAd()", 4000); } } function ShowLink() { document.returnValue = true; } function Go2Url() { window.open(adLink[cID-1]); }</script> <a onMouseOver="java script:ShowLink();return document.returnValue;" href="java script:Go2Url();"> <img name="imgAD" style="FILTER: revealTrans(duration=2,transition=20);BORDER-RIGHT:#cccccc 1px solid; BORDER-TOP:#cccccc 1px solid; BORDER-LEFT:#cccccc 1px solid; BORDER-BOTTOM:#cccccc 1px solid" src="java script:NextAd()" border="0" width="140" height="170" hspace="0">
将以上代码粘贴到模板中的任何位置,即可显示在主页上,如果想更换照片,更改以上网页即可!
更改网页方式如下
以上一共12个网站,从第一个到第12个
1第一个照片的网址 2第2个照片的网址 3 第2个照片的网址 4第3个照片的网址 5第3个照片的网址 6第4个照片的网址 7第4个照片的网址 8第5个照片的网址 9第5个照片的网址 10.11.12均放第6个照片的网址
这样一来,这些照片在主页上将会随机显示!!!
|