Reputation: 21
i have a problem with nested child element in use asp.net linkbutton within updatepanel.
when i use a linkbutton in updatepanel, onclick event is works fine by ajax request:
<asp:updatepanel runat="server" childrenastriggers="true">
<contenttemplate>
<asp:repeater runat="server" id="myrpt">
<itemtemplate>
<asp:linkbutton runat="server">click me</asp:linkbutton>
</itemtemplate>
</asp:repeater>
</contenttemplate>
</asp:updatepanel>
so, when i insert a html child inside linkbutton, then ajax request not firing and do it as a postback request:
<asp:updatepanel runat="server" childrenastriggers="true">
<contenttemplate>
<asp:repeater runat="server" id="myrpt">
<itemtemplate>
<asp:linkbutton runat="server"><i class="fa fa-times"></i></asp:linkbutton>
</itemtemplate>
</asp:repeater>
</contenttemplate>
</asp:updatepanel>
any body can help me to fix this problem in updatepanel?
Upvotes: 1
Views: 243
Reputation: 21
this problem fixed by this changes in web.config file:
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.web>
<pages clientIDMode="AutoID" />
</system.web>
</configuration>
Upvotes: 1