Chinaunix首页 | 论坛 | 博客

acc

  • 博客访问: 791665
  • 博文数量: 170
  • 博客积分: 7011
  • 博客等级: 少将
  • 技术积分: 1660
  • 用 户 组: 普通用户
  • 注册时间: 2006-07-31 12:02
文章分类

全部博文(170)

文章存档

2014年(7)

2010年(2)

2009年(62)

2008年(25)

2007年(67)

2006年(7)

我的朋友

分类:

2007-10-11 12:26:16

老是有人发符号,我给你屏蔽掉,看你还怎么发 ,不信搞不似你们?...嘿嘿!!
 
 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">
<html xmlns="">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
<script language="javascript">
        function check(form1){
         var strname=form1.aa.value;    
            for (var i=0; i<strname.length; i++)
            {     
                 var acc=strname.charCodeAt(i);
                                 
                 if(acc>=0&&acc<48&&acc!=46){
                     alert(acc); return false;
                 }
                 if(acc>57 && acc<65){
                     alert(acc); return false;
                 }
                 if(acc>90 && acc<97){
                     alert(acc); return false;
                 }
                 if(acc>122 && acc<=127){
                     alert(acc); return false;
                 }
            }
    }
</script>
</head>

<body>
<table width="724" border="0" cellpadding="0" cellspacing="0">
  <!--DWLayoutTable-->
  <tr>
    <td width="147" height="140">&nbsp;</td>
    <td width="463">&nbsp;</td>
    <td width="114">&nbsp;</td>
  </tr>
  <tr>
    <td height="105">&nbsp;</td>
    <td valign="top"><form id="form1" name="form1" method="post">
      <label>
        <input type="text" name="aa" />
        </label>
      <label>
      <input type="submit" value="提交" onclick="check(form1)" />
      </label>
    </form>
    </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td height="50">&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
</table>
</body>
</html>

阅读(1604) | 评论(0) | 转发(0) |
0

上一篇:实现滚动图象

下一篇:文字移动代码

给主人留下些什么吧!~~