http://qs321.pair.com?node_id=7509


in reply to Mail Question

Well, I prefer to do most of everything by hand. Means less overhead from the modules. Please enjoy the following:

The following uses CGI.pm as an easy way to deal with CGI vars. Sends me email from any web form. Prints each var "paco=taco" format.

#!/usr/bin/perl use CGI qw(:standard); @submits = param(); open(MAIL, "|/usr/sbin/sendmail -oi -t") or die "Can't Open Sendmail: +$!"; print MAIL <<EOF; From: Web Page To: patrick\@pacoswithtacos.net Subject: Web Form Submission EOF foreach $item (@submits) { print MAIL "$item=".param($item)."\n"; } close(MAIL); print "Location: ../thank_you.html\n\n";
At the end it tells the browser to go to an html page.