[Seaside] Accessing the Post body/content from an, expired/cached page before initialRequest

Philippe Marschall philippe.marschall at gmail.com
Tue Mar 20 18:27:35 UTC 2012


Am 19. März 2012 08:36 schrieb Ramshreyas <ramshreyas.rao at gmail.com>:
> "WARequest>>  #fields / #queryFields / #postFields should work if you're
> using Comanche.."
>
> Have succesfully made it work with a plain (non-seaside-served) html page
> using a Get method: (I could've used updateUrl but it serves my purpose to
> deliver that menu page statically anyway).
>
> Will get to work on the post method as you suggest soon.
>
> But in the current scenario (statically served page with Get method), new
> question:
>
> each incoming get request from my static page is treated as a new session -
> so if a user performs multiple transactions, each is traeated as a new
> session, requiring multiple logins, etc.

Right if the session information is lost. If you just want to serve
some PDFs and don't need session information then the easiest way is
to just implement a WARequestHandler or add a WARequestFilter to you
application. Then no new session will be created.

> Is it possible to 'pass' control back to the initial session?

If you know the session and continuation key.

> I can get the user's IP address with:
>
> nativeRequest := self session currentRequest nativeRequest
> ipAddress := nativeRequest remoteAddress.

That's Seaside 2.8 code, in 3.0 you can use
self requestContest request remoteAddress

> Do you think I should use the announcements framework which I dimly grok...
>
> Only want direction, will do the leg work myself...

Cheers
Philippe


More information about the seaside mailing list