帝王谷资源网 Design By www.wdxyy.com

方式一:通过submit按钮提交

<!DOCTYPE html>
<html>
<head>
    <title>通过submit按钮提交</title>
    <meta charset="UTF-8"/>
</head>
<body>
    <form action="" method="get" id="form1">
        <input type="text" name="username"></input>
        <input type="submit" value="提交" />
    </form>
</body>
</html>

方式二:通过一般按钮button提交

<!DOCTYPE html>
<html>
<head>
    <title>通过一般按钮提交</title>
    <meta charset="UTF-8"/>
</head>
<body>
    <form action="" method="get" id="form1">
        <input type="text" name="username"></input>
        <input type="button" value="ok" name="sb" onclick="submit1();">
    </form>
    <script type="text/javascript">
        function submit1()
        {
            var form1 = document.getElementById("form1");
            form1.action = " bjpowernode.html";
            form1.submit();
        }
    </script>
</body>
</html>

方式三:通过超链接提交

<!DOCTYPE html>
<html>
<head>
    <title>通过超链接提交</title>
    <meta charset="UTF-8"/>
</head>
<body>
    <a href="bjpowernode.html?username=张三">通过超链接提交</a> 
</body>
</html>
标签:
HTML表单提交,表单提交方式,表单的提交方式

帝王谷资源网 Design By www.wdxyy.com
广告合作:本站广告合作请联系QQ:858582 申请时备注:广告合作(否则不回)
免责声明:本站文章均来自网站采集或用户投稿,网站不提供任何软件下载或自行开发的软件! 如有用户或公司发现本站内容信息存在侵权行为,请邮件告知! 858582#qq.com
帝王谷资源网 Design By www.wdxyy.com