PX : code

Send Form by Alfredo R. Rivera
Download this code


####    Start File Send_from.php   ####
<?
/* Created by Alfredo R. Rivera 
   www.fredotech.com
   PHP Send Mail Form
   Created: 11/23/2001
   Last Modified: 11/24/2001
   Version: 1.0
*/
$msg = \"E-MAIL SENT FROM WWW SITE\\n\";
$msg = \"Sender\'s Name:\\t$sender_name\\n\";
$msg = \"Sender\'s Email:\\t$sender_email\\n\";
$msg = \"Message: \\t$message\\n\\n\";
# Modify this line as you like #
$mailheaders = \"From: www.fredotech.com Automated Web Form <> \\n\";
$mailheaders = \"Reply-To : $sender_email\\n\\n\";

mail($to, $subject, $msg, $mailheaders);

?>

<HTML>
<HEAD>
<TITLE> Feedback Form Sent </TITLE>
</HEAD>
<BODY>

<H1> The Following e-mail has been Sent:</H1>
<P><strong> Your name:</strong><br>
<? echo \"$sender_name\"; ?>
<P><strong> Your Email Address:</strong><br>
<? echo \"$sender_email\"; ?>
<P><strong> Message:</strong><br>
<? echo \"$message\"; ?>

</BODY>

####End File Send_form.php ####

####  Start Form.html   ####

<FORM METHOD=\"post\" ACTION=\"send_form.php\"><BR>
      <B>Reason for Email :</B> <SELECT name=\"subject\">
        <OPTION>General Comments</OPTION>
        <OPTION>Company Comments</OPTION>
        <OPTION>BUG Report</OPTION>
        <OPTION selected>Service Request</OPTION>
      </SELECT><BR><BR>
      <B>Your Name</B>: <INPUT size=\"35\" type=\"text\" name=\"sender_name\"><BR>
      <B>Your Email</B>: <INPUT size=\"35\" type=\"text\" name=\"sender_email\"><BR>
      <BR>
      <B>Comments:</B><BR>
      <TEXTAREA rows=\"8\" cols=\"64\" name=\"message\">Type in your comments     here...</TEXTAREA><BR>
      <BR>
      <INPUT type=\"submit\"><INPUT type=\"reset\">
      <INPUT type=\"hidden\" name=\"to\" value=\"[[Place your Email address here]]\">
</FORM>

Comments or questions?
PX is running PHP 5.2.17
Thanks to Miranda Productions for hosting and bandwidth.
Use of any code from PX is at your own risk.