perl-embperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aaron Johnson <solut...@gina.net>
Subject Re: Problems with %udat
Date Sat, 21 Dec 2002 16:47:12 GMT
On Fri, 2002-12-20 at 15:44, MaurĂ­cio Amorim wrote:
> Hi mailing list,
>  
> I install apache with embperl with the following configuration:
>  
> Platform: SunOS 5.6
>  
> Apache 1.3.26
> mod_perl-1.27
> HTML-Embperl-1.3.4
> Apache-Session-1.54
> Apache-SessionX-2.00b3
>  
> I did a module called mypackage.pm and i declare a function that set
> %udat
>  
> in .epl file a did:
>  
> [- use pct::mypackage; -]
> [- pct::mypackage::createsession("user", "xxxxxx"); -]
> [# $udat{user} = "xxxxxx; #]
> [+ $udat{_session_id} +]
> 
> in mypackage.pm:
>  
> #! /usr/bin/perl
> package pct::mypackage;
> sub createsession {
>     my ($k) = shift;
>     my ($v) = shift;
>     $udat{$k} = $v;
> }
> 1;

If you want to work with the udat hash outside of the epl file, such as
your external module, you need to use the full package name to reference
it.  Such as: $HTML::Embperl::udat{$k} = $v;

NOTE: This is not compatible with 2.0 , there is currently no provision
for accessing the Embperl values in this this manner.  That is
%Embperl::udat is not accessible.

Aaron

>  
> When i run the .epl file in browser, this create an session for each
> submission.
>  
> When i use %udat directly ($udat{user} = "xxxxxx;) the session work.
>  
> Anybody can help me.
>  
> Thank you, Mauricio.


---------------------------------------------------------------------
To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
For additional commands, e-mail: embperl-help@perl.apache.org


Mime
View raw message