ASP.NET禁止重复提交
来源:互联网 发布:独步天下 知乎 编辑:程序博客网 时间:2024/04/28 04:35
<html>
<style>
.disable
{
border-style:none;
border-width: thin;
background-color:Transparent;
color: #CCCCCC;
cursor:wait;
}
</style>
<script type="text/javascript" language="javascript">
function DisableButton()
{
document.getElementById("Button1").className = "disable";
document.getElementById("Button1").value = '正在提交.请稍候!';
document.getElementById("Button1").onclick=Function("return false;");
return true;
}
document.onkeydown=mykeydown;
function mykeydown()
{
if(event.keyCode==116) //屏蔽F5刷新键
{
window.event.keyCode=0;
return false;
}
}
</script>
<body>
<form id="form1" runat="server">
<asp:Button ID="Button1" runat="server" OnClick="Button1_Click" CssClass="button112" />
</form>
</body>
</html>
.CS文件
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
this.Button1.Attributes.Add("onclick", "return DisableButton();");
}
}
- 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 MVC 重复提交
- ASP.NET实现禁止用户重复登录
- asp.net如何禁止从外部提交
- 如何禁止重复提交
- 如何禁止重复提交
- 如何禁止重复提交
- PHP汉字转拼音的函数
- UsernameToken
- EXCEL二级数据有效性的设置问题
- 实践xml缓存技术构建高性能web站点
- asp获取文件md5值
- ASP.NET禁止重复提交
- 如何使生产模式(Prodect Mode)的weblogic应用服务器启动时(startWebLogic)不需要输入用户名(username)和口令(password)
- 让red hat9.0与xp组成双系统
- Why JQUERY
- ettercap
- MicrosoftReportViewer rdlc 打印最后多一页
- 安装双系统
- 优秀网站源码、编程源码下载网站大集中
- CSDN的SD2C大会结束了 收获非常非常多