heyman has asked for the wisdom of the Perl Monks concerning the following question:
I have two questions in one.
1) I recently inquired about using Javscript.pm here javascript, javascript.pm, data::Javascript, cgi, installing, using, perl module from cpan and I had a problem with all the ways of doing it; What am I missing there or is there another way.
2)When I use a script and I set a Environment variable i do this
These of course are samples above. Is this the RIGHT WAY to set environment variables for a current page; or is there a RIGHT or BETTER way; also when i use the print while statement above am I getting the right info as the browser or the server would have or is the "while print" distorted by my declarations above "EG. $ENV{}>#!/usr/bin/perl $ENV{HTTP_HOST} = "http://www.perlmonks.org"; $ENV{SERVER_NAME} = "http://www.perlmonks.org"; $ENV{SCRIPT_URI} = "/cgi-bin/gg.cgi"; foreach $var_name ( sort keys %ENV ) { print "<p><b>$var_name</b><br>"; print $ENV{$var_name}; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: $ENV{HTTP}, environment variables, javascript, javascript.pm, setting for a current page
by chromatic (Archbishop) on Mar 31, 2001 at 06:19 UTC | |
|
Re: $ENV{HTTP}, environment variables, javascript, javascript.pm, setting for a current page
by strredwolf (Chaplain) on Mar 31, 2001 at 06:29 UTC | |
|
Re: $ENV{HTTP}, environment variables, javascript, javascript.pm, setting for a current page
by heyman (Novice) on Mar 31, 2001 at 11:15 UTC | |
by myocom (Deacon) on Mar 31, 2001 at 11:21 UTC |