[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Confused about variable scope.


The approach I'm using is the suggested approach in the mod perl book.

Basically setup the environment in order to pass information to apache so that
it's available in httpd.conf and then in httpd.conf to use mod perl to
interrogate %ENV. One problem is that mod_perl clears out %ENV so what you see
below is a way to repopulate it after that has happened.

Quoting Jonathan Vanasco <suppressed>:

> 
> On Aug 1, 2006, at 4:38 PM, suppressed wrote:
> >         for (`env`) {
> > 	 next unless /^X_/;
> > 	 /(.*)=(.*)/;
> > 	 $ENV{$1} = $2;
> > 	 push @PassEnv, $1;
> > 	 #print "$_\n";
> > 	}
> >
> > and I then do
> >
> >         my $somevariable = $ENV{'X_KEY'};
> 
> my question is what exactly are you trying to do?  this sounds like a  
> really assbackwards way to do what you really want done.
> 




----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.


Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.