On 13/07/2010, Marc Delisle marc@infomarc.info wrote:
<snip> >> A few more things : >> * the 'add user' page doesn't seem to like it when you hit enter to >> submit your data. I got some kind of 'unable to execute : undefined' >> error, even if I clicked on the 'Add user' button. > Hitting "enter" does nothing for me. Is this a normal behavior for > jQuery dialog? </snip> jQuery dialogs will submit that form when we click on one of the buttons. I'm trying to figure out if I can trigger the same event by hooking up the same functions on the form's submit event.
For this to work, I believe that the create button would need to be highlighted to show that it's the action of the Enter key.
I just tried here http://jqueryui.com/demos/dialog/#modal-form and the Enter key does not work; maybe it's not intended to work.
A possible work around to this would be to not use the jQueryUI dialog buttons to post the form. Instead, we can attach the ajax post to the submit event for the form, and just keep a cancel button, the way it is on the new table form. I realised this yesterday when I was testing the appending of the new table to the list of tables.