[Seaside] updating form element value
Sebastian Sastre
ssastre at seaswork.com
Wed Oct 3 12:59:08 UTC 2007
Question: How many http requests one should expect from the code of the
updater below?
Sebastian Sastre
> -----Mensaje original-----
> De: seaside-bounces at lists.squeakfoundation.org
> [mailto:seaside-bounces at lists.squeakfoundation.org] En nombre
> de Sebastian Sastre
> Enviado el: Martes, 02 de Octubre de 2007 09:12
> Para: 'Seaside - general discussion'
> Asunto: RE: [Seaside] updating form element value
>
> Lukas,
>
> I supouse I've tested it after a long day of work. Now
> I've changed the previous renderer to this:
>
> ^ [:html|
> html updater
> id: self id;
> callback:[:h| self renderInnerContentOn: h];
> callback:[:v | (self at: aSymbol) model
> setValue: v]
> value: (html formElement
> id: (self at: aSymbol)
> inputElementId;
> value)]
>
> and it does exactly what I was wanting to do.
>
> thanks a lot for the assistance,
>
> Sebastian Sastre
> PS: one key is that one can set the main #callback: (in which
> the updater receives the canvas) *and* then N
> #callback:value: per suajax this was new for me.
>
> > > it's nil. So I'm unable to perform an update of the
> > content. I think
> > > it was possible to receive the value and the canvas to make the
> > > update, maybe I misunderstood something?
> >
> > #callback:value: is not supposed to get a renderer passed
> in, just the
> > value. Use the common #callback: to get the renderer. Check out the
> > documentation in those two methods.
> >
> > 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
>
> _______________________________________________
> Seaside mailing list
> Seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
More information about the Seaside
mailing list