: : Отправить 按钮 提交
<form action = "mydemand" method = "post"> <pan> 关键字 : < /span> <name = "keywords" type = "text" value = "@Keywords" /> <input type = "Vade" value = "搜索" /> < /form>
第二种方式 : $ ("#DataForm"). AjaxSubmit () 提交
<form id = "dataform" action = "updateUserInfo" ectype = "multipry/form-data" method = "post"> <table cellpadding = "0" cellscess = "0"> <tbody> <tr> <td> 名字 : : </td> <td> <input type = "text" name = "nvc_name" idAme "=" nvc_name "nvc_name" nvc_name ". value = "@model.nvc_name"/> </td> </tr> <tr> <td colspan = "2" align = "center"> <input type = "cutte" value = "保存" id = "btnsubmit"/> </td> </tr> </tbode> </table> </form> <script src = "http://code.jquery.com/jquery-1.11.0.min.js"> </script> <script src = "http://malsup.github.io/jquery.form.js"> </script> // ajaxform 依赖脚本 <script type = "text/javascript"> $. {$ ("#btnsubmit"). Click (function () {if ($ ("[name = 'nvc_name']"). val () == "") {alert ("请填写名字"); $ ("[name = 'nvc_name']"). Focus (); return;} $ ("#dataform") (r.success) {location.reload ();}})})}); </script>第三种方式 : Post 提交
<Таблица CellPadding = "0" cellSpacing = "0"> <Tbody> <tr> <td align = "rught"> 手机号 : </td> <td> <input type = "text" waceholder = "请输入手机号" id = "nvc_user_name"/> </td> </tr> <tr> <td colspan = "2" align "/> </td> </tr> <tr> <td colspan =" align "=" = "=" = "=" = "=" = "=" = "=" = "=" = "=" = "=" = "=" = "=" = "=" = "=" = "=" = "=" = "=" = "=". value = "保存" id = "btnsubmit"/> </td> </tr> </tbody> </table> <script type = "text/javascript"> $ (function () {$ ("#btnsubmit"). Click () {var nvc_user_name = document.getElementById ('nvc_user_name'); $. post ('/interface/modefiypwd', {nvc_user_name: nvc_user_name.value,}, function (data) {if (data.success) {$ ("#ediv"). {layer.msg (data.msg);}});});}) </script>以上所述是小编给大家介绍的 mvc 中 форма 表单提交的三种方式 (推荐) , 希望对大家有所帮助 , 如果大家有任何疑问请给我留言 , 小编会及时回复大家的。在此也非常感谢大家对武林网网站的支持!