我正在使用更新面板进行异步回发。在异步回发按钮单击两次之后。我不知道为什么我使用 jQuery 来连接一些鼠标悬停效果在 UpdatePanel 内的元素上。事件绑定在 $(document).ready
<script type="text/javascript">
window.onload = body_load;
function body_load()
{
BindEvents();
}
function BindEvents()
{
$(function ()
{$(".csstablelisttd").mousedown(function (e)
{//mouse down code});
$("#contentPlaceHolderMain_btnFix").click(function (e)
{alert("Alert");//here alert is generate two times an then postback occurs
//btn click code
}
}
}
</script>
<asp:UpdatePanel ID="updatePanelTableAppointment" runat="server">
<ContentTemplate>
<table id="table" runat="server">
//table data
</table>
<script type="text/javascript">Sys.Application.add_init(body_load);
</script>
</ContentTemplate><Triggers>
<asp:AsyncPostBackTrigger ControlID="btnFix" EventName="Click" />
</Triggers>
</asp:UpdatePanel>