资料
表格
制度
合同
管理
职场
经营
创业
范文
总结
计划
作文
文章
美文
词句
教程
模板
图片
字体
图标
办公
人事
财务
生产
管理资源吧首页
>>>
教程
>>>
编程
>>>
JavaScript教程
>>>
javascript 新闻切换技术
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=gb2312" /> <title>管理资源吧www.glzy8.com新闻切换技术</title> <style type="text/css"> <!-- body { text-align: center; margin:0; padding:0; background: #FFF; font-size:12px; color:#000;} div,form,img,ul,ol,li,dl,dt,dd {margin: 0; padding: 0; border: 0;} h1,h2,h3,h4,h5,h6 { margin:0; padding:0;} table,td,tr,th{font-size:12px;} a:link {color: #000; text-decoration:none;} a:visited {color: #83006f;text-decoration:none;} a:hover {color: #c00; text-decoration:underline;} a:active {color: #000;} .focusPic{margin:0 auto; width:244px;} .focusPic .pic{margin:0 auto; width:240px; height:180px; padding:2px 0 0;} .focusPic .adPic{margin:0 auto 5px; width:240px; height:29px; overflow:hidden;background:url(http://tech.163.com/newimg/adpic.gif);} .focusPic .adPic .text{float:right; padding:9px 4px 0 0; width:140px;} .focusPic .adPic .text a{color:#1f3a87;} .focusPic .adPic .text a:hover{color:#bc2931;} .focusPic h2{ float:left; width:232px;padding:4px 0 3px 12px; font-size:14px; text-align:left;} .focusPic p{float:left; width:226px;line-height:160%; margin:0; text-align:left;padding:0 0 10px 12px;} .focusPic p img {margin:0px 0 2px;} .focusPic .more{ margin:0 auto; width:240px; } .focusPic .more .textNum{float:right; margin:0 8px 0 0;padding:0 0 4px;} .focusPic .more .textNum .text{float:left; font-weight:bold; padding:7px 6px 0 0; color:#666;} .focusPic .more .textNum .num{float:left; width:113px; height:19px;} .focusPic .more .textNum .bg1{ background:url(http://tech.163.com/newimg/num1.gif);} .focusPic .more .textNum .bg2{ background:url(http://tech.163.com/newimg/num2.gif);} .focusPic .more .textNum .bg3{ background:url(http://tech.163.com/newimg/num3.gif);} .focusPic .more .textNum .bg4{ background:url(http://tech.163.com/newimg/num4.gif);} .focusPic .more .textNum .num ul{ float:left; width:113px;} .focusPic .more .textNum .num li{float:left; width:28px; font-weight:bold;display:block; color:#fff; list-style-type:none; padding:6px 0 0;} .focusPic .more .textNum .num li a{color:#fff; padding:0 5px; } .focusPic .more .textNum .num li a:visited{color:#fff;} .focusPic .more .textNum .num li a:hover{color:#ff0;} --> </style> </head> <body> <img src="/_New/_cj/myeditor/sysimage/space.gif" class="ewebeditor__script" _ewebeditor_fake_tag="script" _ewebeditor_fake_value="%3Cscript%20language%3D%22JavaScript%22%20type%3D%22text%2Fjavascript%22%3E%20%20%0D%0Avar%20nn%3B%20%20%0D%0Ann%3D1%3B%20%20%0D%0AsetTimeout('change_img()'%2C6000)%3B%20%20%0D%0Afunction%20change_img()%20%20%0D%0A%7B%20%20%0D%0A%20if(nn%3E4)%20nn%3D1%20%20%0D%0A%20setTimeout('setFocus1('%2Bnn%2B')'%2C6000)%3B%20%20%0D%0A%20nn%2B%2B%3B%20%20%0D%0A%20tt%3DsetTimeout('change_img()'%2C6000)%3B%20%20%0D%0A%7D%20%20%0D%0Afunction%20setFocus1(i)%20%20%0D%0A%7B%20%20%0D%0A%20selectLayer1(i)%3B%20%20%0D%0A%7D%20%20%0D%0Afunction%20selectLayer1(i)%20%20%0D%0A%7B%20%20%0D%0A%20switch(i)%20%20%0D%0A%20%7B%20%20%0D%0A%20case%201%3A%20%20%0D%0A%20document.getElementById(%22focusPic1%22).style.display%3D%22block%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic2%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic3%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic4%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic1nav%22).style.display%3D%22block%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic2nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic3nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic4nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20break%3B%20%20%0D%0A%20case%202%3A%20%20%0D%0A%20document.getElementById(%22focusPic1%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic2%22).style.display%3D%22block%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic3%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic4%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic1nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic2nav%22).style.display%3D%22block%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic3nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic4nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20break%3B%20%20%0D%0A%20case%203%3A%20%20%0D%0A%20document.getElementById(%22focusPic1%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic2%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic3%22).style.display%3D%22block%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic4%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic1nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic2nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic3nav%22).style.display%3D%22block%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic4nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20break%3B%20%20%0D%0A%20case%204%3A%20%20%0D%0A%20document.getElementById(%22focusPic1%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic2%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic3%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic4%22).style.display%3D%22block%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic1nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic2nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic3nav%22).style.display%3D%22none%22%3B%20%20%0D%0A%20document.getElementById(%22focusPic4nav%22).style.display%3D%22block%22%3B%20%20%0D%0A%20break%3B%20%20%0D%0A%20%7D%20%20%0D%0A%7D%20%20%0D%0A%3C%2Fscript%3E"> <div class="focusPic"> <div id="focusPic1" style="display:block ;"> <div class="pic"> <a href="http://tech.163.com/special/000915SN/soft2005.html" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fspecial%2F000915SN%2Fsoft2005.html"><img src="http://cimg.163.com/tech/2006/1/18/2006011810122068706.jpg" _ewebeditor_ta_src="http%3A%2F%2Fcimg.163.com%2Ftech%2F2006%2F1%2F18%2F2006011810122068706.jpg" alt="网易学院05年软件评选结果" width="240" height="180" border="0" / onclick="javascript:window.open(this.src);" style="CURSOR: pointer" onload="return imgzoom(this,550)"></a> </div> <h2><a href="http://tech.163.com/special/000915SN/soft2005.html" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fspecial%2F000915SN%2Fsoft2005.html">网易学院05年软件评选结果</a></h2> 经过大家的热情投票和我们的辛劳整理,网易学院2005年年度软件评选结果终于出炉啦。点击进入查看……<img src="/newimg/i2.gif" _ewebeditor_ta_src="%2Fnewimg%2Fi2.gif" alt="详细" width="3" height="5" / onclick="javascript:window.open(this.src);" style="CURSOR: pointer" onload="return imgzoom(this,550)"> <a href="http://tech.163.com/special/000915SN/soft2005.html" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fspecial%2F000915SN%2Fsoft2005.html" class="cDRed">详细</a></p> </div> <div id="focusPic2" style="display: none ;"> <div class="pic"> <a href="http://tech.163.com/discover/" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fdiscover%2F"><img src="http://cimg.163.com/tech/2006/1/17/200601171557008cee7.jpg" _ewebeditor_ta_src="http%3A%2F%2Fcimg.163.com%2Ftech%2F2006%2F1%2F17%2F200601171557008cee7.jpg" alt="颠覆丛林动物生存法则" width="240" height="180" border="0" / onclick="javascript:window.open(this.src);" style="CURSOR: pointer" onload="return imgzoom(this,550)"></a> </div> <h2><a href="http://tech.163.com/discover/" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fdiscover%2F">颠覆丛林动物生存法则</a></h2> <p>群居动物的这种行为颠覆了我们通常认为的,在动物世界通行的 "丛林法则",动物不都自私,不都是弱肉强食的。<img src="/newimg/i2.gif" _ewebeditor_ta_src="%2Fnewimg%2Fi2.gif" alt="详细" width="3" height="5" / onclick="javascript:window.open(this.src);" style="CURSOR: pointer" onload="return imgzoom(this,550)"> <a href="http://tech.163.com/discover/" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fdiscover%2F" class="cDRed">详细</a></p> </div> <div id="focusPic3" style="display: none ;"> <div class="pic"> <a href="http://tech.163.com/special/00091MNJ/itobserve015.html" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fspecial%2F00091MNJ%2Fitobserve015.html"><img src="http://cimg.163.com/tech/2006/1/17/2006011711483290a60.jpg" _ewebeditor_ta_src="http%3A%2F%2Fcimg.163.com%2Ftech%2F2006%2F1%2F17%2F2006011711483290a60.jpg" alt="WAPI并非贸易阴谋" width="240" height="180" border="0" / onclick="javascript:window.open(this.src);" style="CURSOR: pointer" onload="return imgzoom(this,550)"></a> </div> <h2><a href="http://tech.163.com/special/00091MNJ/itobserve015.html" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fspecial%2F00091MNJ%2Fitobserve015.html">WAPI并非贸易阴谋</a></h2> <p>近日国家做出决定:"将向其他的国内及国外企业公布该算法"。事实证明中国WAPI标准并非是贸易阴谋。<img src="/newimg/i2.gif" _ewebeditor_ta_src="%2Fnewimg%2Fi2.gif" alt="详细" width="3" height="5" / onclick="javascript:window.open(this.src);" style="CURSOR: pointer" onload="return imgzoom(this,550)"> <a href="http://tech.163.com/special/00091MNJ/itobserve015.html" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fspecial%2F00091MNJ%2Fitobserve015.html" class="cDRed">详细</a></p> </div> <div id="focusPic4" style="display: none ;"> <div class="pic"> <a href="http://tech.163.com/special/00091OSI/horizons.html" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fspecial%2F00091OSI%2Fhorizons.html"><img src="http://cimg.163.com/tech/2006/1/17/200601171002503f251.jpg" _ewebeditor_ta_src="http%3A%2F%2Fcimg.163.com%2Ftech%2F2006%2F1%2F17%2F200601171002503f251.jpg" alt="新视野号探测冥王星特别专题" width="240" height="180" border="0" / onclick="javascript:window.open(this.src);" style="CURSOR: pointer" onload="return imgzoom(this,550)"></a> </div> <h2><a href="http://tech.163.com/special/00091OSI/horizons.html" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fspecial%2F00091OSI%2Fhorizons.html">新视野号探测冥王星特别专题</a></h2> <p>美国宇航局将于北京时间18日凌晨2时24分发射新视野号探测器,造访这颗人类唯一尚未探测过的行星-冥王星。<img src="/newimg/i2.gif" _ewebeditor_ta_src="%2Fnewimg%2Fi2.gif" alt="详细" width="3" height="5" / onclick="javascript:window.open(this.src);" style="CURSOR: pointer" onload="return imgzoom(this,550)"> <a href="http://tech.163.com/special/00091OSI/horizons.html" _ewebeditor_ta_href="http%3A%2F%2Ftech.163.com%2Fspecial%2F00091OSI%2Fhorizons.html" class="cDRed">详细</a></p> </div> <div class="more"> <div class="textNum"> <div class="text">> 更多头图新闻</div> <div class="num bg1" id="focusPic1nav" style="display: block;"> <ul> <li>1</li> <li><a href="javascript:setFocus1(2);" _ewebeditor_ta_href="javascript%3AsetFocus1(2)%3B" target="_self">2</a></li> <li><a href="javascript:setFocus1(3);" _ewebeditor_ta_href="javascript%3AsetFocus1(3)%3B" target="_self">3</a></li> <li><a href="javascript:setFocus1(4);" _ewebeditor_ta_href="javascript%3AsetFocus1(4)%3B" target="_self">4</a></li> </ul> </div> <div class="num bg2" id="focusPic2nav" style="display: none;"> <ul> <li><a href="javascript:setFocus1(1);" _ewebeditor_ta_href="javascript%3AsetFocus1(1)%3B" target="_self">1</a></li> <li>2</li> <li><a href="javascript:setFocus1(3);" _ewebeditor_ta_href="javascript%3AsetFocus1(3)%3B" target="_self">3</a></li> <li><a href="javascript:setFocus1(4);" _ewebeditor_ta_href="javascript%3AsetFocus1(4)%3B" target="_self">4</a></li> </ul> </div> <div class="num bg3" id="focusPic3nav" style="display: none;"> <ul> <li><a href="javascript:setFocus1(1);" _ewebeditor_ta_href="javascript%3AsetFocus1(1)%3B" target="_self">1</a></li> <li><a href="javascript:setFocus1(2);" _ewebeditor_ta_href="javascript%3AsetFocus1(2)%3B" target="_self">2</a></li> <li>3</li> <li><a href="javascript:setFocus1(4);" _ewebeditor_ta_href="javascript%3AsetFocus1(4)%3B" target="_self">4</a></li> </ul> </div> <div class="num bg4" id="focusPic4nav" style="display: none;"> <ul> <li><a href="javascript:setFocus1(1);" _ewebeditor_ta_href="javascript%3AsetFocus1(1)%3B" target="_self">1</a></li> <li><a href="javascript:setFocus1(2);" _ewebeditor_ta_href="javascript%3AsetFocus1(2)%3B" target="_self">2</a></li> <li><a href="javascript:setFocus1(3);" _ewebeditor_ta_href="javascript%3AsetFocus1(3)%3B" target="_self">3</a></li> <li>4</li> </ul> </div> </div> </div> </div> </body> </html>
[Ctrl+A 全选 注:
如需引入外部Js需刷新才能执行
]
教程首页
更多教程