网页代码设计技巧系列之---广告banner效.doc_第1页
网页代码设计技巧系列之---广告banner效.doc_第2页
网页代码设计技巧系列之---广告banner效.doc_第3页
网页代码设计技巧系列之---广告banner效.doc_第4页
网页代码设计技巧系列之---广告banner效.doc_第5页
已阅读5页,还剩20页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

脚本说明:第一步:把如下代码加入区域中!- Beginning of JavaScript -/ The width of your images (pixels). All pictures should have the same width.var imgwidth=468/ The height of your images (pixels). All pictures should have the same height.var imgheight=60/ The horizontal and vertical position of the images (pixels). var pos_left=70var pos_top=90/ The name of your images. You may add as many images as you like.var imgname=new Array()imgname0=home1.gifimgname1=home2.gifimgname2=home3.gifimgname3=home4.gif/ Where should those images be linked to? / Add an URL for each image./ If you dont want to add an URL just write # instead of / the URL, see sample imgurl2.var imgurl=new Array()imgurl0=imgurl1=imgurl2=imgurl3=/ This block will preload your images. Do not edit this block.var imgpreload=new Array()for (i=0;i=imgname.length-1;i+) imgpreloadi=new Image()imgpreloadi.src=imgnamei/ Standstill-time between the images (microseconds).var pause=2000/ Speed of the stretching and shrinking effect. More means slower.var speed=20/ This variable also affects the speed (the length of the step between each inmage-frame measured in pixels). More means faster.var step=10/ Do not edit the script belowvar i_loop=0var i_image1=0var i_image2=1function stretchimage() if (i_loop=imgwidth) if (document.all) imgcontainer1.innerHTML=document.all.imgcontainer2.style.posLeft=document.all.imgcontainer1.style.posLeft+i_loopimgcontainer2.innerHTML=i_loop=i_loop+stepvar timer=setTimeout(stretchimage(),speed)else clearTimeout(timer)changeimage()function changeimage() i_loop=0i_image1+if (i_image1imgname.length-1) i_image1=0i_image2=i_image1-1if (i_image2imgname.length-1) i_image2=0if (i_image20) i_image2=imgname.length-1document.all.imgcontainer2.style.posLeft=document.all.imgcontainer1.style.posLeftvar timer=setTimeout(stretchimage(),pause)function initiate() if (document.all) document.all.imgcontainer1.style.posLeft=pos_leftdocument.all.imgcontainer2.style.posLeft=pos_leftdocument.all.imgcontainer1.style.posTop=pos_topdocument.all.imgcontainer2.style.posTop=pos_topchangeimage()if (document.layers) document.imgcontainer1.left=pos_leftdocument.imgcontainer2.left=pos_leftdocument.imgcontainer1.top=pos_topdocument.imgcontainer2.top=pos_toprotatenetscape()function rotatenetscape() document.imgcontainer1.document.write() document.imgcontainer1.document.close() i_i

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

最新文档

评论

0/150

提交评论