Ok, assuming you're working on some type of unix or unix clone, and this is
not CGI(as I've not done this elsewhere, and haven't written CGI)
$ENV refers to the environment of the current shell - for instance, if you
use bash, the results of typing "set" on the command line. For tcsh, it's
setenv, etc etc.
>From the shell, try "echo $QUERY_STRING" and see if anything pops up. If it
does, then that's what the variable is set to. If nothing does, then it's
not set. And in that case, I've no idea what it could be, as that will
depend on the context it's used in.
Environment variables in the shell are a way fo keeping things persistent
across multiple tasks. it's not particularly portable, however, so unless
there's a reason you need to do things that way, it's generally not the best
idea.
(note: CGI might do something completely different with it. As I said, it's
dependent entirely on context.
Your mileage may vary.
hope that helps,
Andrew Nelson
-----Original Message-----
From: Bradshaw, Brian [mailto:[EMAIL PROTECTED]]
Sent: Thursday, June 07, 2001 10:53 AM
To: [EMAIL PROTECTED]
Subject: the ENV command? parameter?
Hi list.
I am trying to learn PERL and decipher some code somone else wrote. I have
the code snip -- $ENV{'QUERY_STRING'} --
I have not found this in the archives, so I am hoping someone will answer
this:
I cannot figure out exaclty what the ENV is.The book says it contains the
current environment. OK, but what is in this environment. I can't find info
what the environment consists of. What does the 'Query_String' mean?
Please help me out? Thanks in advance.
Brian Bradshaw
Systems Engineer
McGraw-Hill Education
McGraw-Hill Companies
860-409-2603
[EMAIL PROTECTED]