zoukankan      html  css  js  c++  java
  • html表单的方便操作

    //表单阻止复制粘贴

    <input class="pass" type="text" oncopy="return false" oncut="return false" placeholder="密  码:" title="password"></input>

    //表单阻止重复提交

    <input type="button" value="确定" onclick="this.disabled=true; this.form.submit();"/>

    //空格提醒

    <script type="text/javascript">
    function deal(form){
    for(i=0; i < form.length; i++){
    if(form.elements[i].value == ''){
    alert(form.elements[i].title + "不能为空");
    }
    }
    }
    </script><form name="form1">

    <tr>
    <td>销售编号:</td>
    <td><input type="text" name="num" title="销售编号"></td>
    </tr>
    <input type="button" onClick="deal(this.form);" id="change" value="提交">
    <input type="reset" value="重置"/>
    </form>
    ---------------------
    参考
    原文:https://blog.csdn.net/u012310056/article/details/78050985

  • 相关阅读:
    决策树分类
    集群服务器 获取COOKIE错误
    React 自写Loading
    HTB-靶机-Unattended
    HTB-靶机-LaCasaDePapel
    HTB-靶机-FriendZone
    HTB-靶机-CTF
    HTB-靶机-FluJab
    HTB-靶机-Help
    HTB-靶机-Chaos
  • 原文地址:https://www.cnblogs.com/nature-wind8/p/10609194.html
Copyright © 2011-2022 走看看