爱易网
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 浏览次数:20234 次
欢迎光临爱易网网页脚本特效中心,点击运行按钮演示特效:
以下是程序代码
脚本说明: 把如下代码加入<body>区域中 <script> function Year_Month(){ var now = new Date(); var yy = now.getYear(); var mm = now.getMonth()+1; var cl = '<font color="#0000df">'; if (now.getDay() == 0) cl = '<font color="#c00000">'; if (now.getDay() == 6) cl = '<font color="#00c000">'; return(cl + yy + '年' + mm + '月</font>'); } function Date_of_Today(){ var now = new Date(); var cl = '<font color="#0000df">'; if (now.getDay() == 0) cl = '<font color="#c00000">'; if (now.getDay() == 6) cl = '<font color="#00c000">'; return(cl + now.getDate() + '</font>'); } function Day_of_Today(){ var day = new Array(); day[0] = "星期日"; day[1] = "星期一"; day[2] = "星期二"; day[3] = "星期三"; day[4] = "星期四"; day[5] = "星期五"; day[6] = "星期六"; var now = new Date(); var cl = '<font color="#0000df">'; if (now.getDay() == 0) cl = '<font color="#c00000">'; if (now.getDay() == 6) cl = '<font color="#00c000">'; return(cl + day[now.getDay()] + '</font>'); } function CurentTime(){ var now = new Date(); var hh = now.getHours(); var mm = now.getMinutes(); var ss = now.getTime() % 60000; ss = (ss - (ss % 1000)) / 1000; var clock = hh+':'; if (mm < 10) clock += '0'; clock += mm+':'; if (ss < 10) clock += '0'; clock += ss; return(clock); } function refreshCalendarClock(){ document.all.calendarClock1.innerHTML = Year_Month(); document.all.calendarClock2.innerHTML = Date_of_Today(); document.all.calendarClock3.innerHTML = Day_of_Today(); document.all.calendarClock4.innerHTML = CurentTime(); } function getCalendarClockFreeCodeMsg(nn){ if (nn == 'off') CalendarClockFreeCode.style.visibility = 'hidden'; else { CalendarClockFreeCode.style.visibility = 'visible'; setTimeout("getCalendarClockFreeCodeMsg('off')",10000); } } var webUrl = webUrl; function calendarClockFreeCode(){ var win = window.open('about:blank','_blank','width=300,height=260,top=0,left=0'); win.document.writeln('<'+'script language="JavaScript">'); win.document.writeln('var autoClose = setTimeout("window.close()",30000)'); win.document.writeln('</'+'script>'); win.document.writeln('<p align="center"><a style="cursor:hand"'); win.document.writeln(' onclick="clearTimeout(autoClose)">请点击此处,否则<br>30秒后此窗口将自动关闭</a></p>'); win.document.writeln('<p>想在自己的网站上添加带日历时钟的朋友,请将下面框中的代码贴到网页的适当地方就可以了<br>'); win.document.writeln('<textarea rows="4" cols="30">'); win.document.writeln('<script>'); win.document.writeln('function Year_Month(){ '); win.document.writeln('var now = new Date(); '); win.document.writeln('var yy = now.getYear(); '); win.document.writeln('var mm = now.getMonth()+1; '); win.document.writeln('var cl = \'<font color="#0000df">\'; '); win.document.writeln('if (now.getDay() == 0) cl = \'<font color="#c00000">\'; '); win.document.writeln('if (now.getDay() == 6) cl = \'<font color="#00c000">\'; '); win.document.writeln('return(cl + yy + \'年\' + mm + \'月<\/font>\'); '); win.document.writeln('}'); win.document.writeln('function Date_of_Today(){ '); win.document.writeln(' var now = new Date(); '); win.document.writeln(' var cl = \'<font color="#0000df">\'; '); win.document.writeln(' if (now.getDay() == 0) cl = \'&l
上一篇:狡猾的按钮特效
下一篇:测算年度星期数
免责声明:
本文仅代表作者个人观点,与爱易网无关。其原创性以及文中陈述文字和内容未经本站证实,对本文以及其中全部或者部分内容、文字的真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
相关资料
更多>
打车App就是下一个团购骗局!?
从雷军的“互联网七字诀”告诉你一个非妖魔化的小米
北京电信推“0月租卡”,同网通话免费
阿里巴巴450亿勾画“现代服务业”藏宝图
柳传志马云陷舆论漩涡:请不要辜负这个时代
只有切到刚需痛点,漫画APP才能走下去
Android版WhatsApp曝漏洞:聊天记录可被窃取
微软不会被颠覆
工商下月将整治手机市场
推荐阅读
更多>
阿朗力避步北电后尘 急切停止自我革新
360涉足搜索范围 百度市场份额面临应战
MIUI,有了它小米就无惧对手
中兴通讯不打机海战术 将向中高端手机转型
史上最严电话实名制9月实行 三大难题待解
用友软件股价逆势下跌 再融资方案现曙光
全球最具“颠覆性”特质的公司排行榜TOP25
诺基亚再缩阵线 封锁上海旗舰店全力蜕变
如家撤离同程内情:祸起反水OTA“联盟”?
HDS发布《2013中国CIO洞察白皮书》
组建铁塔公司倒逼运营商改革 或加速4G网建设
三星石墨烯制备技术获突破
摩托罗拉中国区将再裁员 助力公司变身
雅安地震救灾前线的科技之手 微弱而暖和
从3G牌照发放看中国4G规划效果
墨迹天气:产品创新以攻为守方能对抗巨头
淘宝公布新规:升级售假卖家惩罚力度
索尼移动中国区陷裁员风波:业务不佳 员工焦虑
英特尔IDF峰会启示:释放移动互联的信号
杨元庆去年总薪酬1.33亿元