Help! Sendmail isn't working...
Posted: 29. July 2008 14:03
I've searched the forums, and, for some reason, the threads that appear to possibly be the most helpful, have been edited so that the content is not viewable... It would be great if there was a total step-by-step "this is how you do it" somewhere...
In any event, I'm trying to get sendmail to work, but it's not... I get the following error:
In my sendmail.ini file:
In my php.ini file:
I've restarted apache, and attempted a very simple mail script:
In any event, I'm trying to get sendmail to work, but it's not... I get the following error:
- Code: Select all
Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini
In my sendmail.ini file:
- Code: Select all
smtp_server=smtp.spamarrest.com
smtp_port=25
auth_username=myname
auth_password=mypassword
pop3_server=mail.spamarrest.com
pop3_username=myname
pop3_password=mypassword
In my php.ini file:
- Code: Select all
SMTP = smtp.spamarrest.com
smtp_port = 25
sendmail_from = myname@spamarrest.com
I've restarted apache, and attempted a very simple mail script:
- Code: Select all
$email = 'myemail@yahoo.com';
$from = "From: My Name <myname@spamarrest.com>";
$subject = "it worked";
$body = 'awesome';
if(mail($email,$subject,$body,$from)) { echo 'mail sent'; } else { echo 'mail failed'; }