★33°空间‰


                       ----★七彩服饰  【最潮拜☆日单精品】【Esprit】【Hotwind】满150包邮-女装-流行女装    www.7color.hb.cn

                       ----智力比知识重要,素质比智力重要,觉悟比素质更重要
posts - 110,comments - 35,trackbacks - 0

<script language="JavaScript">
var imgUrlss="<%=imgUrls%>";
var imgLinkss="<%=imgLinks%>";
var imgTextss="<%=imgTexts%>";
var imgUrl=new Array();
var imgLink=new Array();
var imgText=new Array();
//var focustext;
var picNum=0 ;
imgUrl=imgUrlss.split('|');
imgLink=imgLinkss.split('|');
imgText=imgTextss.split('|');
/*function thisPic(){
 //picNum=1;
 i=picNum;
 if (i<6)
 {
  document.images.imgInit.src=imgUrl[i];
  i++;
 }
}*/
function pic1(i){
 picNum=1;
 i=picNum;
 if(i=1)
 document.images.imgInit.src=imgUrl[i];
 focustext.innerHTML='<a href='+imgLink[picNum]+' target=_blank>'+imgText[picNum]+'</a>';
}
function pic2(i){
 picNum=2;
 i=picNum;
 if(i=2)
 document.images.imgInit.src=imgUrl[i];
 focustext.innerHTML='<a href='+imgLink[picNum]+' target=_blank>'+imgText[picNum]+'</a>';
}
function pic3(i){
 picNum=3;
 i=picNum;
 if(i=3)
 document.images.imgInit.src=imgUrl[i];
 focustext.innerHTML='<a href='+imgLink[picNum]+' target=_blank>'+imgText[picNum]+'</a>';
}
function pic4(i){
 picNum=4;
 i=picNum;
 if(i=4)
 document.images.imgInit.src=imgUrl[i];
 focustext.innerHTML='<a href='+imgLink[picNum]+' target=_blank>'+imgText[picNum]+'</a>';
}
function pic5(i){
 picNum=5;
 i=picNum;
 if(i=5)
 document.images.imgInit.src=imgUrl[i];
 focustext.innerHTML='<a href='+imgLink[picNum]+' target=_blank>'+imgText[picNum]+'</a>';
}
function pic6(i){
 picNum=6;
 i=picNum;
 if(i=6)
 document.images.imgInit.src=imgUrl[i];
 focustext.innerHTML='<a href='+imgLink[picNum]+' target=_blank>'+imgText[picNum]+'</a>';
}
function NextPic(){
    if(picNum<6) picNum++;//显示6个图片
    else picNum=1;
    if (document.all){
        //下面注意,如果存在于FORM表单中,需要使用下面的方法,否则可直接使用name。
        document.imgInit.filters.revealTrans.Transition=Math.floor(Math.random()*20);
        document.imgInit.filters.revealTrans.apply();
        document.imgInit.filters.revealTrans.play();
    }
    document.images.imgInit.src=imgUrl[picNum];
    //如果不是图片,而是SWF等,可做判断,内容可在程序中做好,再放于下面。
    focustext.innerHTML='<a href='+imgLink[picNum]+' target=_blank>'+imgText[picNum]+'</a>';
    //设置翻页时间
    theTimer=setTimeout('NextPic()', 3000);
}

function goUrl(){
    window.open(imgLink[picNum],'_blank');
}
</script>
//////////////////////////////////////////////////////////
调用
<SCRIPT type=text/javascript>
 <!--
 var focus_width=510
 var focus_height=140
 var text_height=0
 var swf_height = focus_height+text_height
 
 <%
 
 set rspp=server.CreateObject("adodb.recordset")
 rspp.open("select * from flash order by productid desc"),conn,1,1
 do while not rspp.eof
 %>
 <%
 k1=rspp("productimage")
 m1="manage/"+k1+"|"
 s1=m1+s1
 
 k2=rspp("productlink")
 m2=k2+"|"
 s2=m2+s2
 
 k3=rspp("productname")
 m3=k3+"|"
 s3=m3+s3
 
 rspp.movenext
 if rspp.eof then
 s1=left(s1,len(s1)-1)
 s2=left(s2,len(s2)-1)
 s3=left(s3,len(s3)-1)
 end if
 
 loop
 rspp.close
 set rspp=nothing
 %>
 var pics='<%=s1%>'
 
 var links='<%=s2%>'
 var texts='<%=s3%>'
 
 document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="
http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0 " width="'+ focus_width +'" height="'+ swf_height +'">');
 document.write('<param name="allowScriptAccess" value="sameDomain"><param name="movie" value="flash/picplay.swf"><param name="quality" value="high"><param name="wmode" value="trasparent"><param name="bgcolor" value="#DADADA">');
 document.write('<param name="menu" value="false"><param name=wmode value="opaque">');
 document.write('<param name="FlashVars" value="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'">');
 document.write('<embed src="flash/picplay.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#DADADA" quality="high" width="'+ focus_width +'" height="'+ focus_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="
http://www.macromedia.com/go/getflashplayer " />');  
 document.write('</object>');
 //-->
 </SCRIPT>

posted on 2006-09-20 15:12 圣域飞侠 阅读(265) 评论(0)  编辑  收藏

只有注册用户登录后才能发表评论。


网站导航: