On Monday 28 Mar 2011 23:39:48 Hector Virgen wrote:
> You'll need to use AJAX to show the result of the form submission in the
> dialog box.
> 
> I'm not familiar with Dojo but generally the implementation goes something
> like this:
> 
>    1. Attach an event handler to the form's "submit" event to trigger a
>    callback function when the submit event is fired.
>    2. Within that callback, gather the form's value and submit it via AJAX
>    to your webserver.
>    3. While still in your callback, return false or use whatever Dojo
>    provides to prevent the form from actually submitting.
>    4. Set up a callback for AJAX success that updates the dialog with what
>    the server responded with.
>    5. Don't forget to set up callbacks for error responses.
> 
> I hope this helps.

I wrote some time ago a short how-to about the control of error messages from 
a Zend_Form (more client-side based). It's based on a JSON context (with the 
contextSwitch) and jQuery, but the working principle is the same as described 
above.

The focus was to insert errors for a form from an AJAX response like it has 
been rendered by Zend_Form itself: 
http://juriansluiman.nl/en/article/107/zend_form-style-errors-after-ajax-post

Regards, Jurian
-- 
Jurian Sluiman
Soflomo - http://soflomo.com

-- 
List: [email protected]
Info: http://framework.zend.com/archives
Unsubscribe: [email protected]


Reply via email to