[Seaside] help with #urlForAction:

Yar Hwee Boon hboon at motionobj.com
Tue Jul 19 14:20:02 CEST 2005


On 19-Jul-05, at PM 08:06, radoslav hodnicak wrote:

>
> You are not using setTimeout correctly. The delay is the second 
> argument. And I don't think it can take an url as action.
>
>
> On Mon, 18 Jul 2005, Jason Rogers wrote:
>
>> Aside from the inherent security risks and what not...
>>
>> I have a method like this:
>>
>> renderShuttingDownOn: html
>> 	| url |
>> 	url := html
>> 				urlForAction: [self shutDownTheImage].
>> 	html
>> 		div: [html text: 'Shutting down in 5 seconds.'].
>> 	html script: 'setTimeout(5000, "' , url , '"); void 0;'
>>
>> The timeout is triggered after 5 seconds, but the block in the
>> #urlForAction: message does not get executed.  Is there something I am
>> doing wrong here?

Use a delay to send #shutDownTheImage. Why bother with setTimeout? :)

--
HweeBoon
http://motionobj.com/blog/
MotionObj
(65) 6764-9774



More information about the Seaside mailing list