Reputation: 1103
I have a div that contains an Asp checkboxlist and is opened by jquery ui dialog . I need to manage the postback too, so I add
.parent().appendTo($("form:first"));
The problem is that when dialog is opened all DOM is disabled, it seems that modal:true is extended to all DOM
this is aspx code :
<script type="text/javascript">
$(function () {
$("#modalDialog").dialog({
autoOpen: false,
height: 300,
width: 350,
modal: true,
buttons: {
"Salva": function () {
$("[id*=btn_save]").click();
},
"Annulla": function () {
$(this).dialog("close");
}
},
close: function () {
}
});
$("#modalDialog").parent().appendTo($("form:first"));
});
</script>
<div id="modalDialog" >
<asp:CheckBoxList ID="ckb_eventi" runat="server" DataTextField="NOME" DataValueField="ID_CASSA">
</asp:CheckBoxList>
</div>
<asp:Button ID="btn_save" runat="server" Text="Salva" style = "display:none" OnClick = "btn_save_Click" />
Upvotes: 0
Views: 805
Reputation: 1103
I solved using jquery ui dialog option :
appendTo: "form:first"
instead of using
$("#modalDialog").parent().appendTo($("form:first"));
Upvotes: 1