[Seaside] Updating browser history from an ajax response

Siemen Baader siemenbaader at gmail.com
Fri Apr 12 15:52:47 UTC 2019


Hi,

Not really answering your questions, but I think this is what Iliad is for. There you have access to a restful URL on every (xhr) request and every WAComponent is transparently updated via xhr, including when you use call-answer. 

Just FYI. :)

Siemen

Sent from my iPhone

> On 12 Apr 2019, at 17.23, Johan Brichau <johan at inceptive.be> wrote:
> 
> Hi Esteban,
> 
> I’m interested in this too.
> We have the same kind of application (I guess… using mostly Ajax updates, I mean) but I have just been postponing a retry to address the inconsistency with ajax, server state and the back button for years….
> 
> Within a callback, you can get at the #actionUrl on the renderer. 
> Is that what you want?
> 
> I’m trying to dive into what would be required here… trying to understand what you need:
> Ajax requests always update the same continuation state in Seaside (i.e. they do not create a new continuation)… so if you push that url to the history after each ajax update, the back button will essentially request the same but updated continuation from Seaside, meaning you should see the state as it is in on the server, and not how it was before you made the ajax request (which is what happens now).
> 
> Does that correspond to what you are trying to fix?
> 
> Johan
> 
>> On 12 Apr 2019, at 15:17, Esteban Maringolo <emaringolo at gmail.com> wrote:
>> 
>> I have a Seaside application that is almost 100% AJAX driven to
>> replace the visual components (no call/answer involved).
>> 
>> I plan to to use history.pushState() and history.replaceState()
>> 
>> My plan is to update the browser url after replacing some components,
>> but using the URL building of the existing #updateUrl: (including
>> _s/_k parameters and whatnot).
>> 
>> Is it possible to obtain the URL of the session presenter within the
>> ajax response?
>> 
>> Thanks in advance,
>> 
>> Esteban A. Maringolo
>> _______________________________________________
>> 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


More information about the seaside mailing list