JQuery #onAjaxComplete

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

JQuery #onAjaxComplete

John Toohey
Does anyone have an example of using #onAjaxComplete? When I serialize
my form, I want to have a callback fired, so I can save the contents
of the form fields to a database.

--
-JT
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: JQuery #onAjaxComplete

Lukas Renggli
You don't need that event, it happens inside the web browser anyway.
Better do it in the AJAX callback or add a hidden form field with a
callback to the bottom of your form.

Cheers,
Lukas

On 2/19/09, John Toohey <[hidden email]> wrote:

> Does anyone have an example of using #onAjaxComplete? When I serialize
> my form, I want to have a callback fired, so I can save the contents
> of the form fields to a database.
>
> --
> -JT
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>


--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: JQuery #onAjaxComplete

John Toohey-2
I've added a callback, addButton: 'Create' do: (html jQuery ajax
serializeForm callback:[self test]); but its never called. I have
callback on each form element,and they are all called by #serialize,
but I need to invoke a #save method when all the form elements have
been called, so I can persist the object to a DB.

How can I know when all of my form elements have had their callbacks called?

Thanks

On Thu, Feb 19, 2009 at 4:39 PM, Lukas Renggli <[hidden email]> wrote:

> You don't need that event, it happens inside the web browser anyway.
> Better do it in the AJAX callback or add a hidden form field with a
> callback to the bottom of your form.
>
> Cheers,
> Lukas
>
> On 2/19/09, John Toohey <[hidden email]> wrote:
>> Does anyone have an example of using #onAjaxComplete? When I serialize
>> my form, I want to have a callback fired, so I can save the contents
>> of the form fields to a database.
>>
>> --
>> -JT
>> _______________________________________________
>> seaside mailing list
>> [hidden email]
>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>>
>
>
> --
> Lukas Renggli
> http://www.lukas-renggli.ch
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>



--
-JT
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside