I want to use a jQuery UI dialog box to handle part of my form.
I want the code to work something like this.
<form id="MyForm" name="MyForm">
<input type="text" id="Input1" name="Input1">
<input type="text" id="Input2" name="Input2">
<div id="dialog">
<input type="text" id="Input3" name="Input3">
<input type="text" id="Input4" name="Input4">
</div>
<button type="button" onclick="$('#dialog').dialog('open');">Fill out 3 and 4</button>
</form>
I will declare turn the dialog div into a dialog object using a script at the top of the page.
1) Is it possible to include part of the form in a dialog box like this?
2) Is it possible to make it so that the user entered values for Input3 and Input4 are not deleted when the dialog box is closed?