Re: email form results
| From: | Miles Thompson | Date: | Tue, 21 Dec 2004 19:48:08 +0000 |
| Subject: | Re: email form results | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-204875@lists.php.net to get a copy of this message | ||
Assemble all of your data into the message body (see $message below) and mail it to yourself.
How you trigger this processing and the call to the mail() function depends on how you've constructed your logic.
$message .= $name ."\n";
$message .= $phone . "\n";
$message .= $email;
mail( "processing@subscriptionservices.com", "Free Trial Request",
$message, "From: $email" );One logic construct is for the form's ACTION to call itself, like so: IF $email is NOT set
display the form and to record the informationELSEIF test for critical fields being empty
displaying a message if they are and a reload buttonELSE
to the code above
display Thanks & we'll be in touch, or whatever.
Regards - Miles Thompson
At 02:10 PM 12/21/2004, Ken Bolton wrote:
Is there a simple way to send the results of a form to an email address? I have created a form with multiple categories of radio boxes and I have created a response PHP file that will give the user a confirmation. I'm just not sure how to send the results through email. I've checked the documentation with no luck. Thanks.