[Seaside] Re: Differences in calling render: from ajax?
tamackinnon at gmail.com
Mon Aug 16 14:18:26 UTC 2010
Nick Ager wrote:
> ^ 'window.location.reload();'
> or more brute force:
> ^ 'window.location.href= "', self requestContext request
> uri withoutQuery greaseString, '"' [untested]
Thanks Nick - I finally tracked down my problem - don't do:
jsScript << (self generateUpdateScriptWith: jsScript) ]
And then in generateUpdateScriptWith: jsScript
^aJScript goto: anActionUrl withoutQuery
Its very subtle, but << is appending something that you've already added
to the JSScript collection (above), and so it gets it knickers in a big
knot and hangs the VM (should that be possible?).
So now I've come full circle, I can update my page with components that
have callbacks. but now because I'm reloading my page - my ajax call to
make a noise gets lost (because the page is re-loading). Sigh...
Maybe an IFrame? Or maybe a url parameter that signals to make a noise?
Its all a bit yucky - its a shame I don't know enough to tidy up the
comet pusher (or if it even can be tidied to handle callbacks).
More information about the seaside