多张图片渐变交换显示代码

发布时间:2007年01月26日      浏览次数:1719 次
<table cellspacing="0" cellpadding="0" width="248" border="0">
<script language="JavaScript" type="text/javascript">
            
            var imgUrl=new Array();
            var imgLink=new Array();
            var imgTz=new Array();
            var adNum=0;
            imgUrl[5]="http://photocdn.sohu.com/20060301/Img242083819.jpg?";
            imgLink[5]="http://digi.it.sohu.com/s2006/digigirls/";
            imgTz[5]="放歌女人节!大奖爱可视3999元时尚MP4";
            imgUrl[4]="http://photocdn.sohu.com/20060314/Img242290095.jpg ";
            imgLink[4]="http://digi.it.sohu.com/s2006/sony905e/";
            imgTz[4]="索尼DVD数码摄像机DVD905E/805E专区";
            imgUrl[3]="http://photocdn.sohu.com/20060327/Img242492741.jpg?";
            imgLink[3]="http://digi.it.sohu.com/20060327/n242492390.shtml";
            imgTz[3]="漫漫发烧路! 06年准专业相机选购指南";
            imgUrl[2]="http://photocdn.sohu.com/20060324/Img242459893.jpg?????";
            imgLink[2]="http://digi.it.sohu.com/20060324/n242448282.shtml?";
            imgTz[2]="不到500元!十五个MP3播放器产品选秀";
            
imgUrl[6]="";
            imgLink[6]="";
            imgTz[6]="";
            imgUrl[1]="http://photocdn.sohu.com/20060324/Img242452066.jpg?";
            imgLink[1]="http://digi.it.sohu.com/s2006/0320panasonic/";
            imgTz[1]="2006年松下电器AV新产品发布会";
            imgUrl[7]="";
            imgLink[7]="";
            imgTz[7]="";
            imgUrl[8]="";
            imgLink[8]="";
            imgTz[8]="";
//            imgUrl[5]="http://photocdn.sohu.com/20060111/Img241390060.jpg?";
//            imgLink[5]="http://digi.it.sohu.com/s2005/2005sypx/index.shtml";
//            imgTz[5]="摄影频道05年度网络摄影师网络图片十大评选";
//            imgUrl[4]="http://photocdn.sohu.com/20051221/Img241067289.jpg?";
//            imgLink[4]="http://www.pan-ocean.com.cn/E400.htm";
//            imgTz[4]="宽洋E400九合一数码伴侣";
            var imgPre=new Array();
            var j=0;
            for (i=1;i<=8;i++) {
                  if( (imgUrl[i]!="") && (imgLink[i]!="") ) {
                        j++;
                  } else {
                        break;
                  }
            }
            
            function playTran(){
                  if (document.all)
                        imgInit.filters.item(0).play();
            }
            
            var key=0;
            function nextAd(){
                  if(adNum<j) adNum++ ;
                  else adNum=1;
                  
                  if( key==0 ){
                        key=5;
                  } else if(document.all){
                        imgInit.filters.revealTrans.Transition=60;
                        imgInit.filters.item(0).apply();
                        playTran();
                  }
                  document.images.imgInit.src=imgUrl[adNum];
                  document.getElementById('jdtz').innerHTML=imgTz[adNum];
                  theTimer=setTimeout("nextAd()", 5000);
            }
            
            
            function goUrl(){
                  jumpUrl=imgLink[adNum];
                  jumpTarget='_blank';
                  window.open(jumpUrl,jumpTarget);
                  }
            
            </script>
<tbody>
<tr>
<td height="186" align="center"><a href="javascript:goUrl()"><img src="javascript:nextAd()" name="imgInit" border="0" id="imgInit" style="filter: revealTrans(duration=2,transition=20)" /></a></td>
</tr>
<tr>
<td bgcolor="#8ea4ac" height="1"></td>
</tr>
<tr>
<td id="jdtz" align="middle" height="25"></td>
</tr>
</tbody>
</table>
免责声明:本站相关技术文章信息部分来自网络,目的主要是传播更多信息,如果您认为本站的某些信息侵犯了您的版权,请与我们联系,我们会即时妥善的处理,谢谢合作!