[Seaside] Seaside 2.9-A2 JQuery serialize forms

John Toohey johnptoohey at gmail.com
Fri Feb 6 22:13:42 UTC 2009


Thanks for the quick reply. I am using Mold for the field validation, and
straight HTML fields (not JQuery form fields. My original form had a submit
button to invoke the callback to validate the Mold). Is is possible to add a
callback to the #fieldset that will be invoked when I serialize the form, or
do I have to use the JQuery form fields and add callbacks to each of them.

On Fri, Feb 6, 2009 at 2:43 PM, Lukas Renggli <renggli at gmail.com> wrote:

> > addButton: 'Create' do: (html jQuery ajax serializeForm callback: [self
> > halt]);
> > addButton: 'Close' do: html jQuery new dialog close);
> > with: [html render: self createTournamentComponent].
> > I'm not sure what to pass in as the callback, in order to retrieve the
> > serialized fields. The #callback does not accept any parameters. Just
> > getting started with Seaside, and may be thinking about this in the wrong
> > way.
>
> #serialize:, #serializeForm, and #serializeThis all do not need a
> special callback, they simply trigger the callbacks that you assigned
> to your form and form fields. So just write (html jQuery ajax
> serializeForm) what will look for all form elements in the enclosing
> form and trigger their respective callbacks with the correct values.
>
> Btw, this is exactly the same as with #triggerForm: and
> #triggerFormElement: in Scriptaculous.
>
> Cheers,
> Lukas
>
> --
> Lukas Renggli
> http://www.lukas-renggli.ch
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>



-- 
-JT

Eolas faoi run ata sa riomhphost seo agus i gceangaltan ar bith ata leis
agus is le haghaidh iul agus usaid an te a bhi beartaithe lena fhail agus do
siud amhain a sainiodh e. D'fheadfadh an t-eolas seo a bheith faoi reir ag
pribhleid dli no ghairmiuil agus go mbeadh cearta sealuchais intleachtuil
san aireamh.  Mas amhlaidh nach tu an faighteoir a beartaiodh, ni mor duit
gan an teachtaireacht seo na aon chuid de a usaid, a nochtadh, a choipeail,
a scaipeadh, na a choimead. Mas tri dhearmad a fuair tu an riomhphost seo
cuir e sin in iul don te a sheol chugat e laithreach agus scrios amach gach
coip de as do choras riomhaireachta.  Cibe tuairimi a chuirtear in iul sa
teachtaireacht seo is leis an seoltoir fein iad ach amhain i gcas go ndeir
an seoltoir go sonrach gurbh iad tuairimi ParsPro iad.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/seaside/attachments/20090206/204a9b04/attachment-0001.htm


More information about the seaside mailing list