⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 829text4.htm

📁 javascript各种效果的实例及源代码
💻 HTM
字号:
<html>
<head>
<title>点击出现链接</title>
<style type="text/css">
<!--
body {  font-family: "宋体"; font-size: 9pt; margin-top: 0px; margin-left: 4px; margin-right: 0px}
A { COLOR: black; FONT-SIZE: 13px; FONT-WEIGHT: 400; TEXT-DECORATION: none }
 A:hover { COLOR: red; FONT-SIZE: 13px; FONT-WEIGHT: 400; TEXT-DECORATION: underline }
a:active     { font: 12pt "宋体"; cursor: hand; color: #FF0033 }
--></style>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>
<body bgcolor="#fef4d9">
<br>
<center><font color=red face="隶书" size=6>点击出现链接</font></center>
<br>
<center>
<table border=5 bordercolor=blue borderlight=green>
<tr><td align=center><font size=5 color=red face="Arial, Helvetica, sans-serif"><strong>下面框中为脚本显示区</strong></font></td></tr>
<tr><td align=left height=90 width=400>
<div id=Out0 style="position:relative; left:20; top:+15px; width:90%;" >
  <span id=Out1 class=Outline style="hand: hand; "></span><b id=Out1 class=Outline style="cursor: hand; ">点击这里出现链接</b>
  <div id=Out1details style="display:None; position:relative; left:12;">
       <P>
<u><a href=http://www.163.com/ target=_blank>网易</a></u>
<P>
        <U><a href=http://www.sohu.com/ target=_blank>搜狐</a></u>
<P>
<u><a href=http://www.sina.com.cn/ target=_blank>新浪</a></u>
<P>     <U><a href=http://www.yahoo.com/ target=_blank>雅虎</a></u>
<P>
<u><a href=http://www.263.com/ target=_blank>北京在线</a></u>
<P>     <U><a href=http://www.njcatv.net/ target=_blank>南京有线宽带网</a></u>
<P>
<u><a href=http://www.the9.com/ target=_blank>第九城市</a></u>
<p>
  </div>
</div>
<script language=JavaScript>

function clickHandler() {
  var targetId, srcElement, targetElement;
  srcElement = window.event.srcElement;
  if (srcElement.className == "Outline") {
     targetId = srcElement.id + "details";
     targetElement = document.all(targetId);
     if (targetElement.style.display == "none") {
        targetElement.style.display = "";
     } else {
        targetElement.style.display = "none";
     }
  }
}

document.onclick = clickHandler;

</script>
</td></tr></table></center>
<br>
<br><br>
<center>

<SCRIPT LANGUAGE="JavaScript">

<!-- hide
function goHist(a)
{
   history.go(a);
}
//-->
</script>
<FORM METHOD="post">
<INPUT TYPE="button" VALUE="返回" onClick="goHist(-1)" style="background-color: #8000FF; color: rgb(255,255,255)">
</form>
</center>
<br>
<center>
<textarea name=source rows=12 cols=55 class=yk9>
脚本说明:
把如下代码加入<body>区域中:
<div id=Out0 style="position:relative; left:20; top:+15px; width:90%;" >
  <span id=Out1 class=Outline style="hand: hand; "></span><b id=Out1 class=Outline style="cursor: hand; ">Click here for some cool links</b>
  <div id=Out1details style="display:None; position:relative; left:12;">
        <U>Not a link</u>
<P>
<u>Not a link</u>
<P>
        <U>Not a link</u>
<P>
<u>Not a link</u>
<P>     <U>Not a link</u>
<P>
<u>Not a link</u>
<P>     <U>Not a link</u>
<P>
<u>Not a link</u>
<P>     <U>Not a link</u>
<P>
<u>Not a link</u>
<P>



  </div>
</div>
<script language=JavaScript>

function clickHandler() {
  var targetId, srcElement, targetElement;
  srcElement = window.event.srcElement;
  if (srcElement.className == "Outline") {
     targetId = srcElement.id + "details";
     targetElement = document.all(targetId);
     if (targetElement.style.display == "none") {
        targetElement.style.display = "";
     } else {
        targetElement.style.display = "none";
     }
  }
}

document.onclick = clickHandler;

</script>
</textarea>
<br>

<br>
</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -