表单提交的方法。

Posted 莫笑我胡为

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了表单提交的方法。相关的知识,希望对你有一定的参考价值。

<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>

<body>
    <form action="http://www.jb51.net">
        <input type="text" />
        <input type="submit" value="submit" onsubmit="return validate()" />
    </form>
</body>
<script type="text/javascript">
    function validate() {
        if (confirm("提交表单?")) {
            return true;
        } else {
            return false;
        }
    }
</script>

</html>

 

以上是关于表单提交的方法。的主要内容,如果未能解决你的问题,请参考以下文章

HTML 表单提交 的简单代码

php通过记录IP来防止表单重复提交方法分析

改变表单的提交方法

python实战Flask表单提交的方法

在代码中提交 mvc 表单时,jQuery on('submit'...) 方法不起作用

Form标签表单回显与提交