Hi Jonathan -

> > 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:
> >
> > my $session = new Session;
> > $session->{uid} = $q->param('uid');

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, or maybe the Data::Serializer module:

http://search.cpan.org/~neely/Data-Serializer-0.28/lib/Data/Serializer.pm

I haven't tried that one myself but it look interesting, it has options
for which serializer gets used (including Storable) as well as optional
encryption, compression, and ascii-armoring via hex or base64 (which
you'd definitely want to make it safe to put in an HTML page).


HTH,
Larry Leszczynski




_______________________________________________
templates mailing list
[EMAIL PROTECTED]
http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to