ASP.NET + jQuery UI Modal: load aspx page into modal dialog
- by kilonet
I need to load aspx page into jQuery UI's modal dialog window.
I used following approach: load page content via ajax call into dialog's div and show it:
$.get('Page.aspx', function(response){
$('#dialog').html(response);
$("#dialog").dialog('open');
});
but I've got very strange error (IE8) in line 137215738 (!): 'theForm.elements.length' - is null or not an object. JS debbuger says that source code is not available for such location. I have an assumption that this error happens because of multiple 'form' tags that appears on page after ajax call
I wonder, how can i fix this? Or maybe some other way of showing aspx page in modal dialog?