I am using jquery ui dailog box to display a form.When i click on submit, I want the form to perform action in the same div which is used to display the dailog box. But after form submission the response just displays the returned page on the parent window and not within the dialog.
+1
A:
When your form posts, the entire page is refreshed, not just the containing div element. What you need to do is use ajax form submissions and have the server return only the updated div content. Start here. The success ajax handler would then replace the div content with the server's response.
Edit: If you cannot upgrade to ajax forms or modify the response to include only the DIV content, the immediate alternative would be to host the form content in an iframe within the div. This would cause the form post to update itself within the iframe and not affect the containing page / div element.
Chris
2010-01-12 06:26:25
+1
A:
Sounds like you want to use $.get() to do an ajax hit to load some new data or html that you can then fill into the dialog box.
Rob Van Dam
2010-01-12 06:26:32