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

[MacPerl] Problem with ENV hash array?



I've just re-subscribed to this list after a long absence, and I'm trying
to find a problem with a new CGI script. It's called by an HTML FORM, but I
can't seem to get the variables set in the FORM. In fact, I can't seem to
get anything at all from the ENV hash array. I did write a bunch of CGI
scripts a while back using an older MacPerl, so I know that this stuff used
to work. In desperation, I tried a very simple script:

   #!perl
   foreach $key (keys %ENV) {
       print "$key=$ENV{$key}\n";
       }
   print "Done\n";

All it prints is the "Done", as if ENV were empty. Similar code embedded in
an otherwise functioning ACGI script also fails to display anything. I even
tried the demo.acgi program that's included with MacPerl 5.1.3r2; it
displays an empty "Environmental Variables" section.

Can someone point out the error of my ways? Do you get anything from the
demo.acgi?

I'm using NetPresenz 4.1 as my Web server, and I've tried this on two
PowerMacs running 7.5.5 and on 7.6b4, if that makes any difference.

Thanks for any help.

*                                       Herman Collins
*
* 128 McVey Hall                        herman@pop.uky.edu
* University of Kentucky                Voice: 606-257-2256
* Lexington, Ky.  40506-0045            Fax: 606-323-1978

* "I'll only say what I have to, if that ..."  Chilli Palmer