|
| Register now to interact with over 11,000 members! Registered users have Posting Privileges, free access to Private Messaging, Email Notifications and more. |
|
|||||||
![]() |
|
|
Thread Tools |
|
|
#1 |
|
Guest
Posts: n/a
|
I had a simple CGI script that was working fine, but when I added a function call to retrieve the entire parameter list as a hash (as described in perldoc CGI) the perl script dies on the very statement which is attempting to retrieve the parameters list.
The relevant portion of the CGI script is as follows : #!/usr/bin/perl -w use CGI; # load CGI routines use Data: umper;use English; $query = new CGI; # create new CGI object print $query->header, # create the HTTP header $query->start_html('hello world'), # start the HTML $query->h1('hello world'); # level 1 header @names = $query->param; %parms = $query->Vars; print "<BR>Parameters passed to script : ",join(", ",@names),"<BR><BR>\n"; When I executed the URL which ran the CGI script, all the output that I saw was "hello world", which leads me to believe that this call to the "Vars" method is exploding. Note that when I remove the call to the "Vars" method I see all the output that I expect to see. What am I doing wrong with the "Vars" method ? Also is there a way to redirect standard errors generated by Perl back to the browser ? |
![]() |
| Thread Tools | |
|
|