button enable是FALSE 经过5秒后使其enable为TRUE button enable是FALSE 经过5秒后使其enable为TRUE请问如何实现 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <script type="text/javascript"> function restore() { setTimeout( "document.getElementById('Button1').disabled=false;", 5000); } </script> <asp:Button ID="Button1" runat="server" Text="Button" OnClientClick="this.disabled=true;restore();" /> <script type="text/javascript"> setTimeout( "document.getElementById('Button1').disabled=false;", 5000);</script><asp:Button ID="Button1" runat="server" Text="Button" onclick="Button1_Click" />protected void Button1_Click(object sender, EventArgs e){ Response.Write("OK"); Button1.Attributes["disabled"] = "true";} js写得再细一点:<script type="text/javascript"> function restore() { var btn = document.getElementById('<%= Button1.ClientID %>'); if(btn.disabled == true) btn.disabled = false; } setTimeout('restore()', 5000);</script> <html xmlns="http://www.w3.org/1999/xhtml" ><head runat="server"> <title>无标题页</title> <script type="text/javascript"> var clock; function restore() { var btn = document.getElementById('<%= Button1.ClientID %>'); if(btn.disabled == true) btn.disabled = false; clearTimeout(clock); } function JiaZai() { clock = setTimeout('restore()', 5000); }</script></head><body onload="JiaZai()"> <form id="form1" runat="server"> <div><input id="Button1" disabled="disabled" runat="server" type="button" /> </div> </form></body></html> <html><head><meta http-equiv="Content-Type" content="text/html; charset=gb2312"><title></title></head><body><form id="form1" name="form1" method="post" action=""> <input type="submit" name="Submit" value="同意" /></form><script language="javascript">document.form1.Submit.disabled = true;var speed = 1000; //速度var wait = 5; //停留时间function updateinfo(){ if(wait == 0){ document.form1.Submit.value = "我同意"; document.form1.Submit.disabled = false; } else{ document.form1.Submit.value = "阅读条款"+wait; wait--; window.setTimeout("updateinfo()",speed); }}updateinfo();</script></body></html> iis 401.3错误如何解决 formView中的分行显示问题 excel内容处理. 帮看看这个string type该填什么 把显示当前日期做成用户控件 动态设置CSS元素的属性? webpart的问题 出售基于ASP.NET+C#的工作流平台及OA办公自动化系统各一套(价格可商议) 急:在未装excel的服务器上能否用new Excel.Application()方式导出excel文件? 怎么解决这个问题 c# 如何转义? 有什么好方法在用户控件中解决flash路径问题
function restore()
{
setTimeout( "document.getElementById('Button1').disabled=false;", 5000);
}
</script> <asp:Button ID="Button1" runat="server" Text="Button" OnClientClick="this.disabled=true;restore();" />
setTimeout( "document.getElementById('Button1').disabled=false;", 5000);
</script><asp:Button ID="Button1" runat="server" Text="Button"
onclick="Button1_Click" />protected void Button1_Click(object sender, EventArgs e)
{
Response.Write("OK");
Button1.Attributes["disabled"] = "true";
}
function restore()
{
var btn = document.getElementById('<%= Button1.ClientID %>');
if(btn.disabled == true)
btn.disabled = false;
}
setTimeout('restore()', 5000);
</script>
<head runat="server">
<title>无标题页</title>
<script type="text/javascript">
var clock;
function restore()
{
var btn = document.getElementById('<%= Button1.ClientID %>');
if(btn.disabled == true)
btn.disabled = false;
clearTimeout(clock); }
function JiaZai()
{
clock = setTimeout('restore()', 5000);
}
</script></head>
<body onload="JiaZai()">
<form id="form1" runat="server">
<div>
<input id="Button1" disabled="disabled" runat="server" type="button" />
</div>
</form>
</body>
</html>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title></title>
</head><body>
<form id="form1" name="form1" method="post" action="">
<input type="submit" name="Submit" value="同意" />
</form>
<script language="javascript">
document.form1.Submit.disabled = true;
var speed = 1000; //速度
var wait = 5; //停留时间
function updateinfo(){
if(wait == 0){
document.form1.Submit.value = "我同意";
document.form1.Submit.disabled = false;
}
else{
document.form1.Submit.value = "阅读条款"+wait;
wait--;
window.setTimeout("updateinfo()",speed);
}
}
updateinfo();
</script>
</body></html>