"From field" in PHP email form


Posted on 16th Feb 2014 07:03 pm by admin

I used a wizard to create a PHP email form. I was able to customize it with the exception of the From field. I need the email that is sent to be "From" the email that the sender input. Instead it comes "From" a nonexistent email address with "server" in the domain. Here is the processor code I'm using

Code: <?php

$where_form_is="http://".$_SERVER['SERVER_NAME'].strrev(strstr(strrev($_SERVER['PHP_SELF']),"/"));


mail("braintrack@yahoo.com", $_POST['field_3'], "

First Name: " . $_POST['field_1'] . "
Last Name: " . $_POST['field_5'] . "
Email Address: " . $_POST['field_2'] . "
Situation: " . $_POST['field_3'] . "
Message: " . $_POST['field_4'] . "




");

include("confirm.html");

?>
Any help would be greatly apprciated.

No comments posted yet

Your Answer:

Login to answer
101 Like 8 Dislike
Previous forums Next forums
Other forums

Code Review - SQL and Insertion Attacks (Warning: Not for Newbs)
Hey guys,

Its been a while, I know. Use to love coming here to answer peoples questions, but

User feedback after MySQL query has been executed
Hi all, I've just registered on PHPFreaks because I've got a question that I simply can't work out b

Passing Variables
What I'm wanting to do is when the user clicks on Arenas it will know the name of the country it's w

DYNPRO_FIELD_CONVERSION
Hi gurus,

I got a dump when I run one of my program. the dump is described below:

problem with query error
First Thanks to those who helped me on my previous posts, and the following code i'm using is not mi

pls clear my confusion
Hi friends,

Pls solve my query .

what is the exact use of Scope Resolution Operator( i

Insert data in Mysql and move to another page
I'm stuck with this simple problem. I need to insert data in Mysql and then hit submit and move to a

I need to increse 6hours more, and i don't know how???
I need to increse 6hours more, and i don't know how???
<tr>
<t

php problem?
I don't think I'm stupid, but maybe I am.

I am working on a sit for a friend I am try to put

Simple Variable Question
Hi everyone.... again,

I am really getting into php still. Learning more every day. I love it

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash