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?
Question about Icefaces and valueChangeListener
How do I add a selected value to ice:selectOneMenu?
JSF snippet to center an image in a panel grid
Handling a complex Bean-tree in JSF
I haven't tested the submission will be submitted OK, but I don't think there will be a problem.
Rich Faces Tree Control for handheld device
2) Yes, in fact this is the default behaviour.
Custom JSF component attribute list
Access managed bean from separate web application on same server?
Is there a free JSF Webhost out there? [closed]
You might want to try using a tool like FireFox's Web Developer plugin, which would let you show/hide various parts of the page.
. The UI dialog just uses a "display:none;" tag to hide the div that you turn into a dialog.
It doesn't really go anywhere.. You could fill out the dialog, then remove the style tag that sets the DIV to hidden to see that the values are still there in the input boxes..