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

PHP template help
Ok, I don't know if anyone can help me but I am using PHP templates to make a site. I am a newbie an

Problem with the Update command used with a sqldataadapter
I'm connected to a database on an SQL Server and I'm using a sqldataadapter, sqlconnection, sqldatas

Retrieving innerHTML with cURL?
Hey all (sorry I know I'm a leecher, but I soon won't be. This is my first PHP project, but not my l

connect() succeeds but accept() does not?
Please help me with this problem. I'm working on a time-sensitive project where I'm using TCP socket

Count of reciepients in php mailer
How can i sent a mail to large no of reciepients say 10,00,00 Using PHP MAILER

Locking mysql tables with php
Hi

BACKGROUND:
I have multiple instances of the same php script running in a WAMP environ

Random date selection
i want to select random date with time(hour+minutes+sec) where date is specified(10/22/2009) and tim

PHP Include w/If IE Condition Statement?
I was having a problem with Internet Exploder (big surprise, right?) displaying my drop down menus i

Need help with PHP/MySQL drop down menu
I need help on how I can implement a drop down menu which queries mysql database and output the avai

Referential Integrity problem when inserting into 2 tables at same time
Hello Everyone,

Im relativity new to PHP and MySQL and i have come up against a problem. i h

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