[Seaside] answer: and jQuery

Malte Grunwald malte.grunwald at googlemail.com
Thu Mar 15 15:16:31 UTC 2012

Thank you so far,

the nick ager extension, sounds good, but I am working on Dolphin, so I 
first have to implement it in Dolphin.
Another problem with dolphin is, the call: method does not work... so I 
control my components with
/show: something onAnswer: [show: something onAnswer:[...]]/. It is the 
only way it works with dolphin as I know.

What I tried is to change the value of a variable with ajax  in the 
dialog and then refresh the component with javascript.
I have this code at the beginning of the renderContentOn:
/html form:
             [self variable
                     [html XXXX callback:
                             [self answer: self soemthing]]]./

Do you have maybe an idea, what I can insert for XXXX to create an 
event, to trigger the callback  without an actual user interaction?

Thank you guys!

Am 15.03.2012 15:25, schrieb Bany, Michel:
> FWIW, we have been successfully using the JQuery extensions from Nick 
> Ager (JQuery-Extensions-NickAger.2.mcz) in VisualWorks and I believe 
> it would do what you are after. It allows you to "call" a component in 
> a JQuery dialog and get a response object from the component when the 
> dialog closes. Works a bit like the now old-fashioned #lightbox: method.
>     ------------------------------------------------------------------------
>     *From:* seaside-bounces at lists.squeakfoundation.org
>     [mailto:seaside-bounces at lists.squeakfoundation.org] *On Behalf Of
>     *Robert Sirois
>     *Sent:* jeudi, 15. mars 2012 15:14
>     *To:* seaside at lists.squeakfoundation.org
>     *Subject:* RE: [Seaside] answer: and jQuery
>     Ajax is asynchronous. In Seaside's case, it is independent of the
>     regular call/answer continuation stack. I can't remember if it
>     works or not, but if you reload the page, has your component
>     answered after firing the ajax call with #answer?
>     RS
>     ------------------------------------------------------------------------
>     Date: Thu, 15 Mar 2012 08:59:41 +0100
>     From: malte.grunwald at googlemail.com
>     To: seaside at lists.squeakfoundation.org
>     Subject: [Seaside] answer: and jQuery
>     Hello everybody.
>     My problem:
>     I  am working with a JQDialog and when the "okay" button is
>     clicked, I want to use a /callback:/ and /answer:/ to get back to
>     the /go /method in my Task class.
>     Example:
>     /renderOptionsOn: html id: anIdString width: anInteger
>         (html div)
>             id: anIdString;
>             script: (((html jQuery id: anIdString) dialog)
>                         title: 'test';
>                         autoOpen: false;
>                         modal: true;
>                         width: anInteger;
>                         height: 'auto';
>                         resizable: false;
>                         addButton: 'Okay'
>                             do: (html jQuery ajax script:
>                                         [:s |
>                                         s
>     << (s jQuery id: anIdString , 'form') serialize;
>     << (s jQuery id: #Settings) dialog close;
>     << (s jQuery ajax callback: [self answer: self something])]);
>                         addButton: (self textAt: #CancelTx) do: html
>     jQuery new dialog close);
>             with:
>                     [self
>                         renderInputsOn: html
>                         commands: self settings
>                         id: anIdString,'test']/
>     I read a comment of Lukas Renggli from 2010, it says it is not
>     possible to /answer: /from jQuery is this still up to date?
>     Does anyone have an idea how I can solve the problem?
>     Thank you!
>     Regards
>     _______________________________________________ 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

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/seaside/attachments/20120315/f6d920bb/attachment-0001.htm

More information about the seaside mailing list