Saving Browser State without Cookies
Luca Fini
lfini at arcetri.astro.it
Wed Feb 6 04:35:06 EST 2002
On Tue, 5 Feb 2002, Gerson Kurz wrote:
> On Tue, 5 Feb 2002 12:48:29 -0700, "Orr, Steve" <sorr at rightnow.com>
> wrote:
> >
> >I need to migrate a web application from PHP to Python and I have a
> >requirement to save state info WITHOUT using cookies where much of the state
> >data MUST not be visible to the end users. The PHP application allows users
I made a DB interface years ago which maintained state from one step to
the following without using cookies. It was written in perl, but the
technique has nothing to do with the language used.
It was based on the "HIDDEN" field of HTML Forms. If you define such a
field in a form generated by your application, it is sent back by the
browser when the form data are sent as any other field in the same form.
The HIDDEN field is not invisible to the user (he can look at it by
showing the HTML source) but neither are cookies, so you solve the problem
exactly in the same way as you do for cookies: you might encode
the status information as you like, perhaps using criptography.
I hope this is helpful,
l.f.
--
--------------------------------------------------------------------------
-- ) Luca Fini Tel: +39 055 2752 307
___ |\ Osservatorio Astrofisico di Arcetri Fax: +39 055 2752 292
/ | | |-_ L.go E.Fermi, 5 +-----------------------------------------
(___|___//___) 50125 Firenze / WWW: http://www.arcetri.astro.it/~lfini
(_) (_) Italia / e-mail: lfini at arcetri.astro.it
-----------------------------+--------------------------------------------
More information about the Python-list
mailing list