mail() says sent but no email received


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

My code is quite simple:

Code: <?php
$to = "Ty44ler@yahoo.com";
Did you know?Explore Trending and Topic pages for more stories like this.
$subject = "Test mail";
$message = "Hey, I just wanted to see if the script worked.";
$from = "Ty44ler@yahoo.com";
$headers = "From: $from";

if (mail($to,$subject,$message,$headers)) {
echo("<p>Message successfully sent!</p>");
}
else {
echo("<p>Message delivery failed</p>");
}
?>
I have the SMTP server correct in the php.ini file as well as the port as it connects fine when I do a telnet. Also checked the spam folder and nothing there...
No comments posted yet

Your Answer:

Login to answer
50 Like 5 Dislike
Previous forums Next forums
Other forums

How to know if online site made with PHP
Hello,
I see some sites that does not display extensions at all , for example:

www.site.co

Extending Exception to contain method name
I was wondering, if there's a way to extend Exception in such a way, that it would contain name of a

How to ask a regex question?
Hi, I thought I'd share some of my insight after seeing too many bad questions that either get ignor

How would I do "Users not logged in since *** delete them"
I know how I would set this up, and delete the user roughly.
I'll create a table called "Use

Echo Tweaking help!
HI. I would like to have the output of the entered variables repeat forever, but it's stopping at th

iterating through an array and escape each value independently.
I have a set up where the variable being escaped is an array and it needs to be iterated and escaped

form problem
Hi all, I think this is going to be easy to resolve but for I have been looking at it to long and I

Need help adding a timestamp to my filename/variable
Hello,

I'm kind of stupid when it comes to php and I need a tiny bit of help. I've got a f

Extracting Long text from message class with parameters
Hi,

I would like to extract the long text from a message class. However, the long text ha

Connecion issue
Hi,

For some reason, I keep getting this error when trying to connect:

Warning: mysql_

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