You are viewing a plain text version of this content. The canonical link for it is here.
Posted to embperl@perl.apache.org by Angus Lees <gu...@switchonline.com.au> on 2000/11/03 00:26:58 UTC
trying to GetSession
in my EMBPERL_OBJECT_HANDLER_CLASS, i want to get to %udat
if the cookie (and thus the session) already exists, $self->GetSession
works fine
if the session does not yet exist, GetSession returns undef since
$udat->getid isn't defined yet, and SetupSession returns undef since
$r is defined (see beginning of SetupSession).
if i use %HTML::Embperl::udat directly, all works fine, but i don't
think i'm supposed to do that..
($HTML::Embperl::SessionMgnt is 2)
--
- Gus
Re: trying to GetSession
Posted by Gerald Richter <ri...@ecos.de>.
> in my EMBPERL_OBJECT_HANDLER_CLASS, i want to get to %udat
>
> if the cookie (and thus the session) already exists, $self->GetSession
> works fine
>
> if the session does not yet exist, GetSession returns undef since
> $udat->getid isn't defined yet,
Yes, you are right. That's a bug in GetSession. For now simply remove the
"if ($udat -> getid)" at the end of the line inside GetSession. As long as
you are inside your EMBPERL_OBJECT_HANDLER_CLASS this works.
> and SetupSession returns undef since
> $r is defined (see beginning of SetupSession).
>
The problem here is that SubReq returns true, but this doesn't matter.
Sessions are already setup at this point and should setup again, so the
behaviour is correct, but we could make SetupSession a little smarter and
return the already setuped %udat.
> if i use %HTML::Embperl::udat directly, all works fine, but i don't
> think i'm supposed to do that..
>
of course
Gerald
-------------------------------------------------------------
Gerald Richter ecos electronic communication services gmbh
Internetconnect * Webserver/-design/-datenbanken * Consulting
Post: Tulpenstrasse 5 D-55276 Dienheim b. Mainz
E-Mail: richter@ecos.de Voice: +49 6133 925151
WWW: http://www.ecos.de Fax: +49 6133 925152
-------------------------------------------------------------