Bluehost.com Web Hosting $6.95

$parse_form ... anybody know how it works ?

This is a discussion on $parse_form ... anybody know how it works ? within the Windows Web Servers forums, part of the Web Server and Related Forums category; When I tried to pass data from first.cgi to second.pl with GET method, I got error. See the ...


Go Back   Usenet Forums > Web Server and Related Forums > Windows Web Servers

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 01-19-2005
latt
 
Posts: n/a
Default $parse_form ... anybody know how it works ?

When I tried to pass data from first.cgi to second.pl with GET method,
I got error. See the following error messgae. I used $parse_form
module. But I got error for it. Anybody help me??



[error] [client 127.0.0.1] Undefined subroutine &main::parse_form
called at C:/Program Files/Apache Group/Apache2/cgi-bin/second.pl line
6.\r, referer: http://localhost/cgi-bin/first.cgi
PS. I used ActivePerl.

  #2 (permalink)  
Old 01-20-2005
latt
 
Posts: n/a
Default Re: $parse_form ... anybody know how it works ?

////////////////////// first.cgi
/////////////////////////////////////

!c:/Perl/bin/Perl.exe -w
print "Content-type: text/html\n\n";
&parse_form;
print <<OKAY;
<form method="get" action="second.pl"><br>
A = <input name="a" size=3 value="$FORM{a}"><br>
B = <input name="b" size=3 value="$FORM{b}">
<input type="hidden" name="match" value=1>
<input type="submit" value="Calc"></form>
OKAY

////////////////////////////////////// second.pl
////////////////////////////////

#!c:/Perl/bin/Perl.exe -w
print "Content-Type: text/html\n\n";
&parse_form;
if ($FORM{'match'} == 1){
print "A + B = ",$FORM{'a'}+$FORM{'b'},"<br>";

//////////////////////////////// error
///////////////////////////////

If I used $parse_form in first.cgi, there was no error message. But it
didn't work. ( I didn't see any edit box and button. )

If I used $parse_form in second.pl, I got following error.
[error] [client 127.0.0.1] Undefined subroutine &main::parse_form

  #3 (permalink)  
Old 01-20-2005
latt
 
Posts: n/a
Default Re: $parse_form ... anybody know how it works ?

I am really sorry. I got it. It was my mistake.

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT +1. The time now is 11:41 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0