[Seaside] Dynamically updating a WEB page
Roland Hochmuth
rhochmuth at comcast.net
Thu Mar 16 00:44:22 UTC 2006
Hi Lukas, I tried really hard to get your method to work, but so far
I have failed. I took your exact sample, and used it in my
renderContentOn method for the ClockDisplay. The WEB page ends up
with a "Strings only store Characters" error.
Sorry, I'm very new to Smalltalk, Seaside, VW, and WEB programming,
but it is turning into a little bit of an obsession. I'm using VW 7.4
with the SeasideForWebToolkit 2.6a2 image. Any suggestions where I
should look next? Perhaps, I have incompatible images.
Also, my example might have been a little simplistic. I used a clock,
but really I'm modeling a simplistic traffic control system for
helping me learn Smalltalk and Seaside. There is a TrafficLight
Controller, which is a WATask, a TrafficLight, and a
TrafficLightDIsplay. The controller updates the TrafficLight based
on various algorithms. The TrafficLightDisplay is a WAComponent and
displays a red or green image of a traffic light. Ultimately, I would
like the controller to change the light and the display to be updated/
triggered immediately. So, if I set the frequency to say 1 sec, then
your method would probably be sufficient for my purposes right now.
This is only an educational pursuit at the moment. But, I'm wondering
if I'll need to go to SeasideAsync or Scriptaculous or if there is a
way to trigger a new rendering using something more similar to what
you have provided.
Regards --Roland
On Mar 15, 2006, at 11:50 AM, Lukas Renggli wrote:
>> Clock>>renderContentOn: html
>> html paragraph
>> script: (html periodical
>> frequency: 60
>> on: [ :r | r render: Time now ])
>
> Oups, this should rather be:
>
> html paragraph
> script: (html periodical
> frequency: 60;
> callback: [ :r | r render: Time now ])
>
> Sorry,
> 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
More information about the Seaside
mailing list