You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Hans Poo <ha...@integranet.cl> on 2002/01/04 22:22:53 UTC
Lost form values with direct calls to param in CGI.pm
I'am migrating some scripts to run under Apache::Registry. The scripts are
programmed with the typical: use CGI qw/:standard/ ... and then recover the
parameter values wityh direct call to the function param("somefield").
This is happening with the last versions: apache:1.3.22 and mod_perl 1.26
Detail:
if i do:
use CGI qw/:standard/;
and call the form values with:
print param("somefield");
The form fields don't appear to exist.
Instead if i use the object oriented syntax:
my $q = new CGI;
and then
print $q->param("somefield");
everything works fine...
I have been the whole day chasing this ...
The same thing happen with Apache::PerlRun
To finish, the httpd.conf file is:
------------------------------------------------------------
<VirtualHost 64.76.145.88>
ServerName www.polla.cl
DocumentRoot /home/www/html
Alias /cgi-bin /home/www/cgi-bin
PerlModule Apache::Registry
<Location /cgi-bin>
SetHandler perl-script
PerlHandler Apache::Registry
Options ExecCGI
</Location>
</VirtualHost>
Hans Poo