![]() |
Undefined subroutine and paramater
I'm just starting out with CGI..
And my assignment was to create an e-mail form utilizing CGI and perl and forms. I keep getting this error: Undefined subroutine &main:: param called at ./a16.cgi line 26 I've looked at it for several hours, and still can't figure out why it won't work. My instructor also couldn't figure out why. I don't think its recognizing "param" as a function, your help would be very much appreciated! CGI code: Code:
#!/usr/bin/perl -wCode:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
Anyone have any ideas, as to why param doesn't seem to be working?
|
You could use the cgi module to get the params
I hope I am not going to far with a homework help. Code:
use CGI;bazz |
Quote:
Code:
if ($mailTo and $mailFrom and $subjectLine and $message)Code:
unless (!$mailTo || !$mailFrom || !$subjectLine || !$message)bazz |
Thanks a lot! l will give it a try!
Also your not going to far with homework help, as my teacher couldn't figure my problem out either, so I didn't really have anywhere else to turn. |
lol. I meant going too far as per the rules of the forum.
It is unfortunate that tutors have such limitations but, as most coders here seem to accept, it is very difficult to stay on top of a subject, when you are teaching it more than staying up to date. bazz |
This is very true, also I got it working.
Thanks again! |
| All times are GMT +1. The time now is 09:24 PM. |
Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.