Not showing whole name with mail () script


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

I sent up a simple mail form with the PHP mail() script. One problem is when it sends an email with the form's contents, the From header only reads the first name and shows @domain.com in the From column.

Example:

Did you know?Explore Trending and Topic pages for more stories like this.
A user inputs "John Smith" into the form as their name.

When the email arrives in my inbox it's say "John@yahoo.com", the domain name depends on which email I'm using, could say "John@hotmail.com" if I had a hotmail email address. It basically ignores the "space" and "Smith" in the name input part of the form and replaces it with "@domain.com".

How can I get it to put the whole "John Smith" instead? FYI: I'm very new to this, so not sure if this is considered an "easy fix" or not.

Thanks!
No comments posted yet

Your Answer:

Login to answer
96 Like 35 Dislike
Previous forums Next forums
Other forums

PHP - HTTP Digest Authentication - Understanding Code Help
Hi Everyone,

This is my first time on your website and please excuse if I am asking silly que

Typing math
I've added support for typesetting math using LaTeX on the forums.

Example:
Code: [Select]

using file_get_contents??
okay how would i create a script using file_get_contents() in php have it grab search pages 1-20 and

Points for Wiki contribution
Hi everyone,

I want to know how long does it take for the moderator to award points for a

ORA-01017: invalid username/password; logon denied
Dear All,

I am facing problem in taken backup from db13 it comes up with the following l

Getting PHP to ammended the selected in option field
Hey Guys

thanks for everyones help so far. This site and its users are oozing awesomness.

Email with Attachments in PHP
Hi Friends

How to send email in PHP with attachment.
I know simple mail can be sent with

Print 'a' to 'z' via for loop
A very simple problem..
How Can I print a to z NOT a to y ?
It is a part of a code where
<

Adding to an Int row in db
Hi, i have a database which houses all of the users of my site. One of the columns is for points whi

Warning: session_start() [function.session-start]: Cann.....
hi, can someone help me with this? I keep getting this error....

Warning: session_start() [fu

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