There isn't a Vars() function in CGI.pm. If you're looking for the query 
string try param(). Or if you want to make it a mod_perl program (which is 
what you would normally discuss on this list) Apache::Request::param().

--Jeff


At 04:11 PM 8/29/00 +0400, Alexei V. Barantsev wrote:
>         Dear mod_perl'ers!
>
>I have found strange difference between object and func modes of CGI
>library. More precisely - I have a problem with Vars function.
>
>Let me show an example:
>
>#!/usr/bin/perl -w
>
>use Data::Dumper;
>
>use CGI;
>my $q = new CGI;
>my $args = $q->Vars;
>#use CGI qw(:standard :cgi-lib);
>#my $args = Vars;
>
>print
>   header,
>   start_html,
>   p( Dumper( $args ) ),
>   start_form( -method => "POST", -action => "/~barancev/cgi-perl/test.pl" ),
>   textfield( -name => "name", -size => 50 ),
>   submit( -name => "submit", -value => "Submit" ), submit( -name => 
> "cancel", -value => "Cancel" ),
>   end_form,
>   end_html;
>
>All works ok, when I click button I see what button was pressed and
>what string was entered.
>
>But if I try functional way instead (commented in example) I see that
>$args is empty! In single-process mode (httpd -X) both examples work
>right. Why?
>
>(BTW, both examples was tried on clean, just started Apache)
>
>--
>ab
>ICQ: 3959207

Jeff Beard
__________________________________
Web:            www.cyberxape.com
Email:  jeff at cyberxape dot com
Location:       Boulder, Colorado, USA

Reply via email to