[Seaside] Accessing SURequest / SUAjax post parameters
Lukas Renggli
renggli at gmail.com
Tue Apr 15 05:58:26 UTC 2008
> > > html anchor
> > > onClick: (html request
> > > callback: [ self updateModel: testParamValue ];
> > > callback: [ :value | testParamValue := value ] value: 'abc');
> > > with: 'SURequest example'
Why doesn't this code work?
I only notice now that you are using a #request, so you can even make
it simpler:
html request callback: [ :value | self updateModel: value ] value: 'abc'
> myModel.toJson() -- so what I want to end up with is a callback that
> returns the json data to my Seaside component.
The #callback:value:'s first argument is the callback block with the
value, the second argument is the JSON data (in this case a string)
that is serialized on the browser side and brought to the server side.
See the method comment for details.
Lukas renggli
--
Lukas Renggli
http://www.lukas-renggli.ch
More information about the seaside
mailing list