如何在客户端清除 服务器端 textbox 里的内容,避免页面刷新
rt
谢谢
------解决方案--------------------function ClearIt()
{
document.getElementById( "TextBox1 ").value= " ";
}
<input id= "btn " type = "button " onclick= "ClearIt() ">
------解决方案-------------------- <asp:TextBox ID= "TextBox1 " runat= "server "> </asp:TextBox>
<a href=# onclick= "dd() "> asdfasdfasfd </a>
<script type= "text/javascript ">
function dd()
{
document.getElementById( " <%= this.TextBox1.ClientID%> ").value= " ";
}
</script>