关于text文本框的OnChange事件

来源:互联网 发布:人工智能李开复txt微盘 编辑:程序博客网 时间:2024/06/11 13:33

<script   language="javascript"   >  
        function   textChanged(thisObj,thisEvent){  
                var   thisValue   =   thisObj.value;  
                 
                if   (   thisValue   ==   'aa'   ){  
                        thisObj.form.submit();  
                }  
        }  
  </script>  
   
  <!--   HTML   -->  
  <form   name="form1"   action=""   method="pos">  
  <input   type="text"   name="value"   OnChange="textChanged(this,event);">  
  </form>  

原创粉丝点击