Re: [Templates] Objects as hidden variables?

[prev] [thread] [next] [Date index for 2004/12/18]

From: Trond Michelsen
Subject: Re: [Templates] Objects as hidden variables?
Date: 00:42 on 18 Dec 2004
On Fri, Dec 17, 2004 at 02:14:39PM -0500, Larry Leszczynski wrote:
>>> What you'll need to do is create a hidden field for EVERY member of
>>> the session object and then reassemble the object in the subsequent
>>> script:
> Depending on how big your session object is and what kind of stuff is in
> it, another thing you could try is to serialize the entire session into a
> string and use that as your hidden variable, and then unserialize when the
> form is submitted.  You could use something like the Storable module's
> freeze and thaw methods, 

I've actually done this once, and despite it being one of the ugliest
hack I've ever done, it worked surprisingly well :)

        -- 
        Trond Michelsen

_______________________________________________
templates mailing list
templates@xxxxxxxxxxxxxxxx.xxx
http://lists.template-toolkit.org/mailman/listinfo/templates

[Templates] Objects as hidden variables?
Jonathan Mangin 17:08 on 17 Dec 2004

Re: [Templates] Objects as hidden variables?
Sean Kellogg 17:16 on 17 Dec 2004

Re: [Templates] Objects as hidden variables?
Jonathan Mangin 17:32 on 17 Dec 2004

Re: [Templates] Objects as hidden variables?
Larry Leszczynski 19:14 on 17 Dec 2004

Re: [Templates] Objects as hidden variables?
Sean Kellogg 19:36 on 17 Dec 2004

Re: [Templates] Objects as hidden variables?
Jonathan Mangin 19:49 on 17 Dec 2004

Re: [Templates] Objects as hidden variables?
Trond Michelsen 00:42 on 18 Dec 2004

Re: [Templates] Objects as hidden variables?
merlyn (Randal L. Schwartz) 03:30 on 18 Dec 2004

RE: [Templates] Objects as hidden variables?
Simon Matthews 12:34 on 18 Dec 2004

Generated at 08:55 on 15 Mar 2005 by mariachi v0.52