免費論壇 繁體 | 簡體
Sclub交友聊天~加入聊天室當版主
分享
Board logo

標題: [分享] 一个非常非常漂亮的仿真电子台历,不用可惜 [打印本頁]

作者: dicoscom    時間: 2010-6-6 21:30     標題: 一个非常非常漂亮的仿真电子台历,不用可惜

演示:http://cntex.5d6d.com
  1. <STYLE>A.menuitem {
  2. COLOR: menutext; TEXT-DECORATION: none
  3. }
  4. A.menuitem:hover {
  5. COLOR: highlighttext; BACKGROUND-COLOR: highlight
  6. }
  7. DIV.contextmenu {
  8. BORDER-RIGHT: 2px outset; BORDER-TOP: 2px outset; Z-INDEX: 999; VISIBILITY: hidden; BORDER-LEFT: 2px outset; BORDER-BOTTOM: 2px outset; POSITION: absolute; BACKGROUND-COLOR: buttonface
  9. }
  10. </STYLE>
複製代碼
放头部
  1. <STYLE>A.menuitem {
  2. COLOR: menutext; TEXT-DECORATION: none
  3. }
  4. A.menuitem:hover {
  5. COLOR: highlighttext; BACKGROUND-COLOR: highlight
  6. }
  7. DIV.contextmenu {
  8. BORDER-RIGHT: 2px outset; BORDER-TOP: 2px outset; Z-INDEX: 999; VISIBILITY: hidden; BORDER-LEFT: 2px outset; BORDER-BOTTOM: 2px outset; POSITION: absolute; BACKGROUND-COLOR: buttonface
  9. }</P><P></STYLE>
  10. <SCRIPT language=JavaScript>
  11. function Year_Month(){
  12. var now = new Date();
  13. var yy = now.getYear();
  14. var mm = now.getMonth()+1;
  15. var cl = '<font color="#0000df">';
  16. if (now.getDay() == 0) cl = '<font color="#c00000">';
  17. if (now.getDay() == 6) cl = '<font color="#00c000">';
  18. return(cl + yy + '年' + mm + '月</font>'); }
  19. function Date_of_Today(){
  20. var now = new Date();
  21. var cl = '<font color="#ff0000">';
  22. if (now.getDay() == 0) cl = '<font color="#c00000">';
  23. if (now.getDay() == 6) cl = '<font color="#00c000">';
  24. return(cl + now.getDate() + '</font>'); }
  25. function Day_of_Today(){
  26. var day = new Array();
  27. day[0] = "星期日";
  28. day[1] = "星期一";
  29. day[2] = "星期二";
  30. day[3] = "星期三";
  31. day[4] = "星期四";
  32. day[5] = "星期五";
  33. day[6] = "星期六";
  34. var now = new Date();
  35. var cl = '<font color="#0000df">';
  36. if (now.getDay() == 0) cl = '<font color="#c00000">';
  37. if (now.getDay() == 6) cl = '<font color="#00c000">';
  38. return(cl + day[now.getDay()] + '</font>'); }
  39. function CurentTime(){
  40. var now = new Date();
  41. var hh = now.getHours();
  42. var mm = now.getMinutes();
  43. var ss = now.getTime() % 60000;
  44. ss = (ss - (ss % 1000)) / 1000;
  45. var clock = hh+':';
  46. if (mm < 10) clock += '0';
  47. clock += mm+':';
  48. if (ss < 10) clock += '0';
  49. clock += ss;
  50. return(clock); }
  51. function refreshCalendarClock(){
  52. document.all.calendarClock1.innerHTML = Year_Month();
  53. document.all.calendarClock2.innerHTML = Date_of_Today();
  54. document.all.calendarClock3.innerHTML = Day_of_Today();
  55. document.all.calendarClock4.innerHTML = CurentTime(); }
  56. var webUrl = webUrl;
  57. document.write('<table border="0" cellpadding="0" cellspacing="0"><tr><td>');
  58. document.write('<table id="CalendarClockFreeCode" border="0" cellpadding="0" cellspacing="0" width="60" height="70" ');
  59. document.write('style="position:absolute;visibility:hidden" bgcolor="#eeeeee">');
  60. document.write('<tr><td align="center"><font ');
  61. document.write('style="cursor:hand;color:#ff0000;font-family:宋体;font-size:14pt;line-height:120%" ');
  62. if (webUrl != 'netflower'){
  63. document.write('</td></tr><tr><td align="center"><font ');
  64. document.write('style="cursor:hand;color:#2000ff;font-family:宋体;font-size:9pt;line-height:110%" ');
  65. }
  66. document.write('</td></tr></table>');
  67. document.write('<table border="0" cellpadding="0" cellspacing="0" width="61" bgcolor="#C0C0C0" height="70">');
  68. document.write('<tr><td valign="top" width="100%" height="100%">');
  69. document.write('<table border="1" cellpadding="0" cellspacing="0" width="58" bgcolor="#FEFEEF" height="67">');
  70. document.write('<tr><td align="center" width="100%" height="100%" >');
  71. document.write('<font id="calendarClock1" style="font-family:宋体;font-size:7pt;line-height:120%"> </font><br>');
  72. document.write('<font id="calendarClock2" style="color:#ff0000;font-family:Arial;font-size:14pt;line-height:120%"> </font><br>');
  73. document.write('<font id="calendarClock3" style="font-family:宋体;font-size:9pt;line-height:120%"> </font><br>');
  74. document.write('<font id="calendarClock4" style="color:#100080;font-family:宋体;font-size:8pt;line-height:120%"><b> </b></font>');
  75. document.write('</td></tr></table>');
  76. document.write('</td></tr></table>');
  77. document.write('</td></tr></table>');
  78. setInterval('refreshCalendarClock()',1000);
  79. </SCRIPT>
複製代碼
放到自己需要放的地方
作者: WHSKY    時間: 2014-4-1 06:26

可惜只能放顶部不能换个地方,谢谢




歡迎光臨 SCLUB免費論壇申請-使用者論壇 (http://sclub.com.tw/discuz/) Powered by Discuz! 7.2