Mail From Help

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
Ice2257
Forum Newbie
Posts: 8
Joined: Thu Feb 05, 2009 1:17 pm

Mail From Help

Post by Ice2257 »

I have php code setup

When someone fills out my form http://www.tacobills.com/form.html

I want the email address field to be the FROM in the email header that I receive

Here is my current php

Code: Select all

<?php
 
//$mail_body = $_POST['submitterName'];
$mail_body .= $_POST['submitterEmail'];
$mail_body .= "\n";
$mail_body .= "\n";
$mail_body .= $_POST['submitterPhone'];
$mail_body .= "\n";
$mail_body .= "\n";
$mail_body .= $_POST['submitterComments'];
 
 
$recipient = 'Ice2257@gmail.com';
$subject = 'You have an order from ' . $_POST['submitterName'];
 
 
mail($recipient, $subject,$mail_body)
 
header("location: thankyou.html");
 
?>
samsolomonraj
Forum Newbie
Posts: 12
Joined: Mon Feb 09, 2009 3:34 am
Location: India, Chennai

Re: Mail From Help

Post by samsolomonraj »

what you are trying to say??? What is your need???
samsolomonraj
Forum Newbie
Posts: 12
Joined: Mon Feb 09, 2009 3:34 am
Location: India, Chennai

Re: Mail From Help

Post by samsolomonraj »

In your mail() the from address is missing.. You add from address by using header field in the mail function.

Bye...
Post Reply