爱易网
IT新闻
IT新闻
爱易资讯
网站搭建
云虚拟主机教程
云服务器教程
Apache教程
IIS教程
Nginx教程
网站策划
站长文章
推广教程
淘宝客教程
网页设计
HTML教程
XHTML教程
CSS教程
HTML5教程
CSS3教程
JavaSript基础
JQuery教程
Node.js教程
前端技术
Ajax教程
Js特效
Xml教程
平面设计
页面UI设计
photoshop教程
程序开发
AI人工智能
Asp教程
Php教程
Asp.Net教程
Net Core教程
C#教程
Java教程
Jsp教程
开发技术
微信小程序教程
Uniapp开发教程
微信公众号开发
Andriod教程
IOS教程
DOS教程
Python教程
Docker教程
Windows Container教程
数据库
MSSQL教程
MySQL教程
Redis教程
Access教程
Oracle教程
数据库教程
操作系统
Linux教程
Windows教程
MAC教程
Cisco教程
交换机教程
防火墙教程
搜索
爱易网页
JS特效
超酷随鼠标而飞动的时钟--时钟还是走动的
超酷随鼠标而飞动的时钟--时钟还是走动的
日期:2014-05-18 浏览次数:20183 次
欢迎光临爱易网网页脚本特效中心,点击运行按钮演示特效:
以下是程序代码
有什么问题请到<a href='/bbs/index.asp?boardid=2'>论坛</a>中发表<br> <!-- 把如下代码加入<body>区域中 --> <!-- http://www.aiyiweb.com/js --> <!-- bbs http://www.aiyiweb.com/bbs--> 看看效果怎么样啊:<br> <!-- cool clock --> <SCRIPT language=JavaScript>dCol='000099';//date colour. fCol='668099';//face colour. sCol='FF0000';//seconds colour. mCol='000000';//minutes colour. hCol='000000';//hours colour. ClockHeight=40; ClockWidth=40; ClockFromMouseY=0; ClockFromMouseX=100; //Alter nothing below! Alignments will be lost! d=new Array("SUNDAY","MONDAY","TUESDAY","WEDNESDAY","THURSDAY","FRIDAY","SATURDAY"); m=new Array("JANUARY","FEBRUARY","MARCH","APRIL","MAY","JUNE","JULY","AUGUST","SEPTEMBER","OCTOBER","NOVEMBER","DECEMBER"); date=new Date(); day=date.getDate(); year=date.getYear(); if (year < 2000) year=year+1900; TodaysDate=" "+d[date.getDay()]+" "+day+" "+m[date.getMonth()]+" "+year; D=TodaysDate.split(''); H='...'; H=H.split(''); M='....'; M=M.split(''); S='.....'; S=S.split(''); Face='1 2 3 4 5 6 7 8 9 10 11 12'; //font='Arial'; font='Verdana'; size=1; speed=0.6; ns=(document.layers); ie=(document.all); Face=Face.split(' '); n=Face.length; a=size*10; ymouse=0; xmouse=0; scrll=0; props="<font face="+font+" size="+size+" color="+fCol+"><B>"; props2="<font face="+font+" size="+size+" color="+dCol+"><B>"; Split=360/n; Dsplit=360/D.length; HandHeight=ClockHeight/4.5 HandWidth=ClockWidth/4.5 HandY=-7; HandX=-2.5; scrll=0; step=0.06; currStep=0; y=new Array();x=new Array();Y=new Array();X=new Array(); for (i=0; i < n; i++){y[i]=0;x[i]=0;Y[i]=0;X[i]=0} Dy=new Array();Dx=new Array();DY=new Array();DX=new Array(); for (i=0; i < D.length; i++){Dy[i]=0;Dx[i]=0;DY[i]=0;DX[i]=0} if (ns){ for (i=0; i < D.length; i++) document.write('<layer name="nsDate'+i+'" top=0 left=0 height='+a+' width='+a+'><center>'+props2+D[i]+'</font></center></layer>'); for (i=0; i < n; i++) document.write('<layer name="nsFace'+i+'" top=0 left=0 height='+a+' width='+a+'><center>'+props+Face[i]+'</font></center></layer>'); for (i=0; i < S.length; i++) document.write('<layer name=nsSeconds'+i+' top=0 left=0 width=15 height=15><font face=Arial size=3 color='+sCol+'><center><b>'+S[i]+'</b></center></font></layer>'); for (i=0; i < M.length; i++) document.write('<layer name=nsMinutes'+i+' top=0 left=0 width=15 height=15><font face=Arial size=3 color='+mCol+'><center><b>'+M[i]+'</b></center></font></layer>'); for (i=0; i < H.length; i++) document.write('<layer name=nsHours'+i+' top=0 left=0 width=15 height=15><font face=Arial size=3 color='+hCol+'><center><b>'+H[i]+'</b></center></font></layer>'); } if (ie){ document.write('<div id="Od" style="position:absolute;top:0px;left:0px"><div style="position:relative">'); for (i=0; i < D.length; i++) document.write('<div id="ieDate" style="position:absolute;top:0px;left:0;height:'+a+';width:'+a+';text-align:center">'+props2+D[i]+'</B></font></div>'); document.write('</div></div>'); document.write('<div id="Of" style="position:absolute;top:0px;left:0px"><div style="position:relative">'); for (i=0; i < n; i++) document.write('<div id="ieFace" style="position:absolute;top:0px;left:0;height:'+a+';width:'+a+';text-align:center">'+props+Face[i]+'</B></font></div>'); document.write('</div></div>'); document.write('<div id="Oh" style="position:absolute;top:0px;left:0px"><div style="posi
上一篇:狡猾的按钮特效
下一篇:三个下拉框分别显示当前的年、月、日,这在web编程时非常有用
免责声明:
本文仅代表作者个人观点,与爱易网无关。其原创性以及文中陈述文字和内容未经本站证实,对本文以及其中全部或者部分内容、文字的真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
相关资料
更多>
iPhone5S组件曝光 印证杀手级功能存在
团购网站存活率仅18.6% 剩余缺乏千家
传苹果已告知鸿海:两款新iPhone下月发货
承载京东C2C野心的拍拍网:梦想丰满,现实骨感
网曝富士康500万iphone遭退货是确证的事
微软提示XP只剩365天寿命:用户被绑架?
广东移动董事长徐龙受调查 圈内对其褒贬不一
App Store严禁推送广告 运用面临大清洗
这一次,微软将带给我们什么惊喜?
推荐阅读
更多>
快播灭了,还有西瓜:视频网站的灰色江湖还在
银联布局二维码支付,“擦边球”生态不能自救
苏宁双线同价遇难题:第一个吃螃蟹不轻松
阿朗力避步北电后尘 急切停止自我革新
酷派首抓4G时机大丰收,未来份额必降无疑
美国政府关门可能影响去哪儿等公司IPO
三大运营商获通知大减营销费 传3年减400多亿
雅安地震救灾前线的科技之手 微弱而暖和
马云:银行若放开存款利率 余额宝死了也光荣
眼球识别技术EyeVerify融资600万美元 360参投
盛大游戏走向衰落的根源:免费游戏模式惹的祸
iPhone 6将于10月17日内地上市:售5288元起
苹果App Store被大量刷榜:iTunes账号成帮凶
优酷土豆携手新浪微博 谋攻移动视频失地
用友软件股价逆势下跌 再融资方案现曙光
传诺基亚Lumia928下月推出 将与iPhone5看齐
任正非:华为决不上市 上市公司股东贪婪而短视
Docker Desktop 4.11 发布:支持虚拟桌面、Mac 权限更改和新扩展
网络音乐非片面收费 高晓松时间表难完成
刘强东:京东上市融资用于开拓三至六线城市