#!/local/bin/perl require "ctime.pl"; require "cgi-lib.pl"; &ReadParse(*input); $text=$input{'TEXT'}; @FLDS = split(/ /,&ctime(time)); $YEAR = @FLDS[$#FLDS]; chop $YEAR; $address=$ENV{'HTTP_FROM'}; #if($address eq ""){ # print << "EOF"; #Content-type: text/plain #Your web browser is not configured with your email address. I don't #know how to send this message back to you. #EOF # exit; # } open(SM,"|/usr/lib/sendmail -oi bidwell"); print SM << "EOF"; From $address Subject: web based email Mail sent to you by $address from $ENV{'REMOTE_HOST'}. $text EOF close(SM); print << "EOF"; Content-type: text/html\n
\n Your email has been sent to bidwell\@andrews.edu.
Mail sent to you by $address from $ENV{'REMOTE_HOST'}.
$text EOF