<SCRIPT language="VBScript"> Dim FileList,FileListArr,TxtList,TxtListArr FileList ="http://et.21cn.com/portray/images/if/01.jpg,http://et.21cn.com/portray/images/if/02.jpg,http://et.21cn.com/portray/images/if/03.jpg" TxtList ="<a href=http://www.licns.com/ target=_blank>在这里加入你的连接1</a>,<a href=http://www.licns.com/ target=_blank>在这里加入你的连接2</a>,<a href=http://www.licns.com/ target=_blank>在这里加入你的连接3</a>" FileListArr = Split(FileList,",") TxtListArr = Split(TxtList,",") Dim CanPlay CanPlay = CInt(Split(Split(navigator.appVersion,";")(1),"")(2))>5 Dim FilterStr FilterStr ="RevealTrans(duration=2,transition=23)" FilterStr = FilterStr +";BlendTrans(duration=2)" If CanPlay Then FilterStr = FilterStr +";progid:DXImageTransform.Microsoft.Pixelate(,enabled=false,duration=2,maxSquare=25)" FilterStr = FilterStr +";progid:DXImageTransform.Microsoft.Fade(duration=2,overlap=0)" FilterStr = FilterStr +";progid:DXImageTransform.Microsoft.GradientWipe(duration=2,gradientSize=0.25,motion=forward )" FilterStr = FilterStr +";progid:DXImageTransform.Microsoft.Stretch(duration=2,stretchStyle=PUSH)" FilterStr = FilterStr +";progid:DXImageTransform.Microsoft.Wheel(duration=2,spokes=16)" FilterStr = FilterStr +";progid:DXImageTransform.Microsoft.RandomDissolve(duration=2)" FilterStr = FilterStr +";progid:DXImageTransform.Microsoft.Spiral(duration=2,gridSizeX=50,gridSizeY=50)" FilterStr = FilterStr +";progid:DXImageTransform.Microsoft.Slide(duration=2,bands=1,slideStyle=SWAP)" FilterStr = FilterStr +";progid:DXImageTransform.Microsoft.RadialWipe(duration=2,wipeStyle=CLOCK)" FilterStr = FilterStr +";progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=15,Duration=1)" FilterStr = FilterStr +";progid:DXImageTransform.Microsoft.Wipe(duration=3,gradientsize=0.25,motion=reverse)" Else Msgbox "幻灯片播放具有多种动态图片切换效果,但此功能须要您的浏览器为IE5.5或以上版本号,否则您将仅仅能看到部分的切换效果。",64 End If Dim FilterArr FilterArr = Split(FilterStr,";") Dim PlayImg_M PlayImg_M =5*1000‘切换时间(毫秒) Dim I I = 1 Sub ChangeImg Do While FileListArr(I)="" I = I + 1 If I>UBound(FileListArr) Then I = 0 Loop Dim J If I>UBound(FileListArr) Then I = 0 Randomize J = Int(Rnd * (UBound(FilterArr)+1)) Img.style.filter = FilterArr(J) Img.filters(0).Apply Img.Src = FileListArr(I) Img.filters(0).play Txt.filters(0).Apply Txt.innerHTML = TxtListArr(I) Txt.filters(0).play() I = I + 1 If I>UBound(FileListArr) Then I = 0 TempImg.Src = FileListArr(I) SetTimeout "ChangeImg", PlayImg_M,"VBScript" End Sub </SCRIPT> <TABLE WIDTH="100%" height="100%" BORDER="0" CELLSPACING="0" CELLPADDING="0"><TR ID="NoScript"><TD Align="Center" Style="Color:White">对不起,图片浏览功能需脚本支持,但您的浏览器已经设置了禁止脚本执行。请您在浏览器设置中调整有关安全选项。</TD></TR><TR Style="Display:none" ID="CanRunScript"><TD HEIGHT="100%" Align="Center" vAlign="Center"><Img ID="Img" height="290" width="300" Border="0" ></TD></TR><TR Style="Display:none"><TD><Img ID="TempImg" Border="0"></TD></TR><TR><TD HEIGHT="100%" Align="Center" vAlign="Center"><div ID="Txt" style="PADDING-LEFT: 5px; Z-INDEX: 1; FILTER: progid:DXImageTransform.Microsoft.Fade(duration=1,overlap=0); POSITION:"><a href=http://www.licns.com/ target=_blank>在这里加入你的连接1</a></div></TD></TR></TABLE> <Script Language="VBScript"> NoScript.Style.Display = "none" CanRunScript.Style.Display = "" Img.Src = FileListArr(0) SetTimeout "ChangeImg", PlayImg_M,"VBScript" </Script>
腾讯的用Flash调用图片轮显
<script type="text/javascript"> <!--
var focus_width=255 var focus_height=200 var text_height=18 var swf_height = focus_height+text_height
var pics=‘http://img1.qq.com/sports/20060102/2958063.jpg|http://img1.qq.com/sports/20060101/2955633.jpg|http://img1.qq.com/sports/20051229/2936827.jpg|http://img1.qq.com/sports/20051227/2920636.jpg‘ var links=‘http://sports.qq.com/a/20060101/000514.htm|http://sports.qq.com/a/20060101/000053.htm|http://sports.qq.com/a/20051229/000159.htm|http://sports.qq.com/a/20051227/000023.htm‘ var texts=‘曲圣卿打进一球两次助攻 阿德莱德大胜|曼城客场被逼平 继海首发多次制造杀机|继海打满全场表现尚可 曼城不敌切尔西|曼城落败 孙继海险助攻‘
<script language=JavaScript> var imgUrl=new Array(); var imgLink=new Array(); var adNum=0; imgUrl[1]="http://image2.sina.com.cn/lx/nx/2006/0207/U1275P8T1D227041F918DT20060220173712.jpg"; imgLink[1]="http://eladies.sina.com.cn/bbs/p/2006/0220/17268791.html"; imgUrl[2]="http://image2.sina.com.cn/lx/nx/2006/0128/U1275P8T1D226214F918DT20060128200332.jpg"; imgLink[2]="http://eladies.sina.com.cn/pic/special/198/554.html"; imgUrl[3]="http://image2.sina.com.cn/lx/beauty1/2006/0218/U1275P8T1D229151F916DT20060220180508.jpg"; imgLink[3]="http://blog.sina.com.cn/u/45f2dd64010001yg"; imgUrl[4]="http://image2.sina.com.cn/lx/nx/2006/0210/U1275P8T1D227877F1086DT20060213161341.jpg"; imgLink[4]="http://eladies.sina.com.cn/bbs/2006/0213/16048576.html"; var imgPre=new Array(); for (i=1;i<4;i++)...{ imgPre[i]=new Image(); imgPre[i].src=imgUrl[i]; }
function setTransition()...{ if (document.all)...{ imgUrlrotator.filters.revealTrans.Transition=Math.floor(Math.random()*20); imgUrlrotator.filters.revealTrans.apply(); } }
function playTransition()...{ if (document.all) imgUrlrotator.filters.revealTrans.play() }
<script language="JavaScript"> var elady_step=3; //1:small, 3:middle, 5:big var elady_speed=50; //20:fast, 50:middle, 80:slow var e_tp=new Array(); var e_tplink=new Array(); var adNum_elady1=0; var elady_stop_sh=0; var elady_star_sh=1;
function elady1_moveImg()...{ if ((!document.all&&!document.getElementById)||(elady_stop_sh==0)) return; if (elady_star_sh==1)...{ document.all.elady1_divimg.style.pixelTop=parseInt(document.all.elady1_divimg.style.pixelTop)+elady_step;} elseif (elady_star_sh==2)...{ document.all.elady1_divimg.style.pixelLeft=parseInt(document.all.elady1_divimg.style.pixelLeft)+elady_step;} elseif (elady_star_sh==3)...{ document.all.elady1_divimg.style.pixelTop=parseInt(document.all.elady1_divimg.style.pixelTop)-elady_step;} else...{ document.all.elady1_divimg.style.pixelLeft=parseInt(document.all.elady1_divimg.style.pixelLeft)-elady_step;} if (elady_star_sh<4) elady_star_sh++; else elady_star_sh=1; setTimeout("elady1_moveImg()",elady_speed);} e_tplink[0]="http://www.licns.com"; e_tp[0]="http://et.21cn.com/portray/images/if/01.jpg"; e_tplink[1]="http://www.licns.com"; e_tp[1]="http://et.21cn.com/portray/images/if/02.jpg"; e_tplink[2]="http://www.licns.com"; e_tp[2]="http://et.21cn.com/portray/images/if/03.jpg"; e_tplink[3]="http://www.licns.com"; e_tp[3]="http://et.21cn.com/portray/images/if/04.jpg";
var currentimage=new Array(); for (i=0;i<=3;i++)...{currentimage[i]=new Image(); currentimage[i].src=e_tp[i]; } function elady1_set()...{ if (document.all) ...{ e_tprotator.filters.revealTrans.Transition=Math.floor(Math.random()*23); e_tprotator.filters.revealTrans.apply(); } } function elady1_playCo() ...{ if (document.all) e_tprotator.filters.revealTrans.play() }function elady1_nextAd()...{ if(adNum_elady1<e_tp.length-1)adNum_elady1++ ; else adNum_elady1=0; elady1_set(); document.images.e_tprotator.src=e_tp[adNum_elady1]; elady1_playCo(); theTimer=setTimeout("elady1_nextAd()", 4000);} function elady1_linkurl()...{ jumpUrl=e_tplink[adNum_elady1]; jumpTarget=‘_blank‘; if (jumpUrl !=‘‘)...{ if (jumpTarget !=‘‘)window.open(jumpUrl,jumpTarget); else location.href=jumpUrl; }} function elady1_listMsg() ...{ status=e_tplink[adNum_elady1]; document.returnValue =true;} document.write("<div id=‘elady1_divimg‘ style=‘position:relative‘>"); document.write(‘<a onMouseOver="elady1_listMsg();return document.returnValue" href="javascript:elady1_linkurl()" target="_self">‘); document.write(‘<img style="FILTER: revealTrans(duration=2,transition=20)" src="javascript:elady1_nextAd()" border=0 name=e_tprotator onMouseover="elady_stop_sh=1;elady1_moveImg()" onMouseout="elady_stop_sh=0" ></a>‘); document.write("</div>"); </script>
图片和文字一起显示的
<SCRIPT LANGUAGE=JavaScript> var imgUrl=new Array(); var imgLink=new Array(); var imgtext=new Array(); var imgsumm=new Array(); var adNum=0;
var imgPre=new Array(); var count=0; for (i=1;i<=3;i++) ...{ if( (imgUrl!="") && (imgLink!="") ) ...{ count++; }else...{ break; } } function playTran()...{ if (document.all) imgInit.filters.revealTrans.play(); } var key=0; function nextAd()...{ if(adNum<count)adNum++ ; else adNum=1;
//////////////////////////// var NX =3; var NY =3; var SP =20; var DELAY =96; //////////////////////////// var object =new Array(); var nI =0; var run =false; var xrun =0; var dR =1; var iW =0; var iH =0; var oH =0; var oW =0;
this.DOOT =function ()...{ with(this)...{ if(img.width<iW)iW=img.width; if(img.height<iH)iH=img.height; with(obj.style)...{ W = width = iW / NX; H = height = iH / NY; L = left = x * W; T = top = y * H; } with(img.style)...{ width = W; height = H; } for(var i in object) object[i].DOOT(); } } }
<div id="imgbox" style="position:absolute;left:0;top:0;overflow:hidden;"></div> <div id="txtbox" style="position:absolute;visibility:hidden;overflow:hidden;background:#333;color:#FFF;font-family:verdana;font-size:0.8em;"> <div style="margin:2%"> <h2>IMGBOX</h2>Click the thumbnails on the left for a larger image. The description connected to the clicked image is displayed here.<br> <br>Note: for performance reasons, images are not resized and must be all of the same size. </div> </div>
<div id="txtsrc" style="visibility:hidden"> <div> <h2>the river</h2><br>Awaken from my nap by the river </div> <div> <h2>transparency</h2><br>Its transparency was hypnotizing. </div> <div> <h2>cold</h2><br>Currents of cold water played with light. </div> <div> <h2>sank in</h2><br>I threw a few nuts into the river. They floated for a while, then sank in. </div> <div> <h2>masked</h2><br>A wide stepping stone masked the water‘s depth. </div> <div> <h2>a glimpse</h2><br>Later on, I had a glimpse of the river‘s bed. </div> <div> <h2>forgotten</h2><br>The wheelchair made a noise. Again, I had forgotten about my legs. </div> <div> <h2>floated</h2><br>Still, I floated in oblivion of things too real. </div> <div> <h2>for me</h2><br>I stared fixedly at the water‘s open arms. The stream was singing for me. </div> </div>