posts - 495,comments - 227,trackbacks - 0

          <!--連接打開新窗口form-->
          <FORM name="targetform">
          <!--連接打開新窗口-->
          <INPUT TYPE="checkbox" id="targetnew" NAME="targetnew" ONCLICK="hyperlinks(this.checked)" />
          <label for="targetnew"><b>在新窗口中打開鏈接</b></label>
          </form>
          <!--連接打開新窗口腳本-->
          <SCRIPT LANGUAGE="JavaScript">
          <!--
          //Enter "_blank" for new window (each time), "window2" for a set secondary window
          var newwindow="_blank"

          function hyperlinks(target){
          ?? if (target) where = newwindow;
          ?? else where = "_self";
          ?? for (var i=0; i<=(document.links.length-1); i++){
          ?? if (target && where!="_blank") //DynamicDrive.com added routine- open window in set secondary window
          ????? document.links[i].onclick=function(){
          ??if (window.window2 && !window2.closed)
          ??window2.location=this.href
          ??else
          ??????? ?window2=window.open(this.href)
          ??window2.focus()
          ????? ??return false
          ????? ??}
          ?? else{
          ????? if (newwindow=="window2") document.links[i].onclick = "";???
          ????? document.links[i].target = where;
          ?????? }
          ?? }
          }

          function inithyperlinks(){??? //DynamicDrive.com added routine
          if (document.targetform.targetnew.checked)
          hyperlinks(true)
          }

          window.onload=inithyperlinks;

          // -->
          </SCRIPT>

          posted on 2006-09-14 17:23 SIMONE 閱讀(3167) 評論(0)  編輯  收藏

          只有注冊用戶登錄后才能發表評論。


          網站導航:
          博客園   IT新聞   Chat2DB   C++博客   博問  
           
          主站蜘蛛池模板: 邹城市| 融水| 建阳市| 罗源县| 论坛| 武穴市| 三穗县| 榕江县| 漾濞| 锦州市| 苏尼特右旗| 扶余县| 万宁市| 松潘县| 彭阳县| 古田县| 陵川县| 沛县| 商都县| 靖宇县| 塔城市| 民和| 海城市| 安徽省| 庆云县| 岚皋县| 茌平县| 阳新县| 泰顺县| 江阴市| 来凤县| 岳普湖县| 枣阳市| 甘孜| 休宁县| 资阳市| 五河县| 大关县| 德令哈市| 彭山县| 岢岚县|