--- Marcello <m.romani at spinsoft.it> wrote:
> Marcello ha scritto:
>
> The problem was I was not familiar with tied references...
>
> I changed my code to modify the session this way:
> get a reference to the session variable
> my $a=$r->{session}->{constraints}
> modify the session variable
> $a->{customer} = 4
> store the modified session variable into the session
> $r->{session}->{constraints} = $a
> This ensures the changes to the session are saved.
>
> Marcello
>
That's right. Apache::Session only looks in the top level for changes when
deciding whether to write session or not. So it was looking at the constraints
hash ref and not seeing any change (its still hash at same address) and it
doesn't look down in the hash for changes.
Another way to do it is to timestamp the session every time you update it as
mentioned in Apache;:Session manual.
$r->session->{timstamp} = localtime;
or what not.
=====
pjs
__________________________________
Do you Yahoo!?
The all-new My Yahoo! - Get yours free!
http://my.yahoo.com
_______________________________________________
maypole mailing list
maypole at lists.netthink.co.uk
http://lists.netthink.co.uk/listinfo/maypole
This archive was generated by hypermail 2.1.3 : Thu Feb 24 2005 - 22:25:58 GMT