鼠标点入文本框浮出验证码特效

<html>
<head>
<meta http-equiv="content-Type" content="text/html;charset=gb2312">
<title>一个和论坛验证码相似的功能</title>
<style type="text/css">
.header
{
   width:60px;
   height:40px;
   background-color:#009999;
   font-size:14px;
   color:#000000;
   display:none;
}
</style>
</head>
<script language="javascript">
<!--
 function dian()
   {
       if(txt.value="")
    {
       document.getElementsByTagName("span")[0].style.display="none";
    }
    else
    {
       document.getElementsByTagName("span")[0].style.display="block";
    }
   }
-->
</script>
<body>
<span class="header">2314</span>
<input type="text" size="20" id="txt" value="" onClick="dian()">
</body>
</html></font>
手机app制作平台