[Seaside] Seaside sessions and ajax

Sebastian Sastre ssastre at seaswork.com
Thu Dec 6 01:23:12 UTC 2007

OK, I was reading a bit and for ajax and back button regard 

1) seems that Yahoo is a winner in simplicity. Yahoo implemented it's
History Manager based on the RSH - Really Simply History framework (ref:
ck-button.html )

Their example seems amazing:

Could be that porting Bori's YUI to Squeak can be a starting point?

2) I've also see that they mention "the tricky part" when they need to
somehow reify the previous state, a thing that, for Seaside Continuations
should be a walk in the park. What I think we'll need is to identify DOM
elements and components 1:1.

I know Seaside does not do that by default by I see no exit for that. Things
seems to be scaling there (I value opinions here). I mean to the need of
having a DOM element wich is an homologue of the Seaside component.

I'm doing it and I'm very satisfied by it. To achieve that I'm using a
component hierarchy that wraps in a div whatever it has to render inside.
When I need to update any of those I know I can by making an updater to work
with it's id. Beside that server-side convenience I use to take advantage of
that id to perform user agent things among elements.

So what I'm saying is that if we need to identify updated elements
corresponding to seaside components we can do it. I don't know yet what will
happen with requestors and evaluators.

Beside that I think we could possibly need to identify updaters, evaluators
and requestors to relate them to a defined continuation. That way we make
YUI to use that unique callbak:

YAHOO.util.History.register ( componentId , initialState , onStateChange ,
obj , override )

I'm thinking about:
componentId <string> the id of the homologue of the seaside component
initialState <string> I don't yet get why they use a string to get such a
complexiy as a state thing. Maybe we don't use this at all.

onStateChange <function> the handler for the change of state. This is good,
here we can put the updater that can make things to go back one step.

obj <object> argument for the handler

override <boolean> if true, the obj passed in becomes the execution scope of
the listener.

	Any comments welcome,


Sebastian Sastre
PS: Here is their API


> -----Mensaje original-----
> De: seaside-bounces at lists.squeakfoundation.org 
> [mailto:seaside-bounces at lists.squeakfoundation.org] En nombre 
> de Lukas Renggli
> Enviado el: Martes, 04 de Diciembre de 2007 04:52
> Para: Seaside - general discussion
> Asunto: Re: [Seaside] Seaside sessions and ajax
> >         I wonder again about the backbutton and ajax. How 
> far or near 
> > we are of making the user agent's back button and Seaside 
> > continuations magic to work with updaters?
> I never worked on this. So if nobody else was looking into that ...
> >         If I want to help to achieve that where would be a 
> place to start?
> > What readings do you have to suggest?
> Have a look at how other frameworks like DoJo, YUI and Google 
> Web Toolkit get the client side working. Be warned that all 
> these solutions are extremely hackish and only work on 
> particular browser versions. Then we can see how to integrate 
> that JavaScript code into Seaside.
> Cheers,
> 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