Still a perl newbie here...I've been editing others' scripts for a few months now. Maybe its time to really sit and learn it?
I have a script that collects data from an html form as an array. It has been usually sending this info to a tab delimited text file like this:
The final lines of this SURVEY package are:
Question - how can I print this to an e-mail instead of the text file? Just for testing, I've added the following code (from formail.pl) which doesn't even have any data from @lines, but I still get the typical HTTP 500 "Page cannot be displayed" in IE5 after a significant pause. Unfortunately, I don't have access to the log right now.
Thanks in advance...
I have a script that collects data from an html form as an array. It has been usually sending this info to a tab delimited text file like this:
$t = "\t";
$whyvisit = &import_textbox($SURVEY::whyvisit);
$survey = $today_date.$t.
$today_time.$t.
"{name}".$t.
"{organization}".$t.
"{homepage}".$t.
"{email}".$t.
"{profession}".$t.
$whyvisit.$t.
The final lines of this SURVEY package are:
@lines = &fill_template("type" => "STRING",
"source" => "survey",
"package" => "SURVEY");
print OUTF @lines;
close (OUTF);
Question - how can I print this to an e-mail instead of the text file? Just for testing, I've added the following code (from formail.pl) which doesn't even have any data from @lines, but I still get the typical HTTP 500 "Page cannot be displayed" in IE5 after a significant pause. Unfortunately, I don't have access to the log right now.
open(MAIL,"|/usr/lib/sendmail -i -t");
print MAIL "To: emailhere@email.com\n";
print MAIL "From: emailhere@email.com\n";
close MAIL;
Thanks in advance...