On Mon, 2005-06-20 at 20:22 +0200, Kjetil Kjernsmo wrote: > > No, you want the hash, not the object it's tied to: > > $r->pnotes('session' => \%session); > > > > Then use it like this: > > my $session_ref = $r->pnotes('session'); > > $session->{'key'} = 'value'; > > Uh, actually, that's what I did in my first version, as it is the intuitive > thing to do, and couldn't get it to do what it should... To me, it looked as > if just the hash was passed, not the tied object... Of course, it could be > that I did something else entirely wrong....
You just need to call tied() on the hash to get the object at any time. > Since I was going to retrieve this session reference from pnotes maaany times > in the code, I created a little sub for it, perhaps that wasn't such a good > idea...? But I think it looked as if only the hash was passed allready in > there, so I don't think that was the problem... No alarm bells are going off > for me here, any for you? I'm not sure what you're talking about here. Show me the code you're referring to. - Perrin