You FORM 'action' tag's value should contain the script to which you are posting to.
You also need to find out the absolute pathname to your mail program (like sendmail) on the server .
Heres a sample script which could be of help to you
===========================================================
use CGI;
$input = new CGI;
# Replace the value in brackets with the name of your first
# text field .
$text1 = $input->param('text1');
# lll'y for the second text field
$text2 = $input->param('text2');
# Recipient Email
$email = $input->param('email')
$mailprog = 'path-to-you-mail-program-here'
open(MAIL,"| $mailprog -t"

or die "Failed to contact mail program'";
select MAIL;
print "From:<sender>";
print "To: $email";
print "Subject:<Subject>\n\n"
print "Mail Body here"
close MAIL ;
select STDOUT;
===========================================================
HTH
regards
C
"Brahmaiva satyam"
-Adi Shankara (788-820 AD)