防止ASP.NET按钮多次提交的办法
来源:互联网 发布:淘宝装修辅助工具源码 编辑:程序博客网 时间:2024/06/10 07:17
防止ASP.NET按钮多次提交的办法
//方法一:在提交时调用一段客户端的代码。
function a()
{
document.getElementById("btnok").onclick=function(){return false;};
function a()
{
document.getElementById("btnok").onclick=function(){return false;};
document.getElementById("btnok").value = '正在提交';
return true;
}
<input id="btnok" runat="server" type="submit" value="确定" onclick="return a();"
onserverclick="Submit1_ServerClick" />
//方法二:必需要是 Asp.net服务器控件。(注意UseSubmitBehavior属性)
<asp:Button ID="btnSumbit" runat="server" UseSubmitBehavior="false"
OnClientClick="this.value='正在提交';this.disabled=true; "
Text="提交" OnClick="btnSumbit_Click" />
return true;
}
<input id="btnok" runat="server" type="submit" value="确定" onclick="return a();"
onserverclick="Submit1_ServerClick" />
//方法二:必需要是 Asp.net服务器控件。(注意UseSubmitBehavior属性)
<asp:Button ID="btnSumbit" runat="server" UseSubmitBehavior="false"
OnClientClick="this.value='正在提交';this.disabled=true; "
Text="提交" OnClick="btnSumbit_Click" />
- 【ASP.NET】防止ASP.NET按钮多次提交的办法
- 【ASP.NET】防止ASP.NET按钮多次提交的办法
- 【ASP.NET】防止ASP.NET按钮多次提交的办法
- [Asp.Net]防止ASP.NET按钮多次提交的办法
- 防止ASP.NET按钮多次提交的办法
- 防止ASP.NET按钮多次提交的办法
- 防止ASP.NET按钮多次提交的办法
- 防止ASP.NET按钮多次提交的办法
- 防止ASP.NET按钮多次提交的办法
- 防止ASP.NET按钮多次提交的办法 .
- 防止ASP.NET按钮多次提交的办法
- 防止ASP.NET按钮多次提交的办法
- 防止ASP.NET按钮多次提交的办法
- 防止ASP.NET按钮多次提交的办法
- 防止按钮多次提交的办法
- 防止ASP.NET按钮多次提交代码
- 防止ASP.NET按钮多次提交代码
- 笔记:ASP.NET 防止按钮多次提交
- SQL语句执行顺序分析
- oracle及操作系统对于文件大小的限制
- 悬而未决:DELL服务器真“品牌”呀,一点都不“兼容”!
- sql 存储过程中的事务
- 海思HI3512视频开发平台使用(一)
- 防止ASP.NET按钮多次提交的办法
- 构建企业级项目管理体系(07)-资源有限,必须做出选择
- putenv,setenv,unsetenv 的使用
- 离鸿围
- Oracle工具篇之Oradim【转】
- 我Harvis
- 寂寞程序员
- Domain Name and Domain Name System
- Java解析XML (DOM解析XML)