colap Posted June 4, 2015 Share Posted June 4, 2015 (edited) I have installed ssmtp on debian. /etc/ssmtp/ssmtp.conf looks like this below: root=ssmtpmailtesting@gmail.com mailhub=smtp.gmail.com:587 #rewriteDomain= hostname=mybox UseSTARTTLS=YES AuthUser=ssmtpmailtesting@gmail.com AuthPass=[mypassword] FromLineOverride=YES php mail function: $to = 'shiblyldu60@yahoo.com'; $subject = 'the subject'; $message = 'hello'; $headers = 'From: webmaster@example.com' . "\r\n" . 'Reply-To: webmaster@example.com' . "\r\n" . 'X-Mailer: PHP/' . phpversion(); mail($to, $subject, $message, $headers); From apache error.log i get this message: sendmail: Authorization failed (534 5.7.14 https://support.google.com/mail/answer/78754 nz12sm1965155pdb.49 - gsmtp Which software is used to send mail with php for debian and windows? 1)sendmail 2)ssmtp 3)msmtp Edited June 4, 2015 by php-cola Quote Link to comment https://forums.phpfreaks.com/topic/296634-php-mail-function-cant-send-email/ Share on other sites More sharing options...
blacknight Posted June 4, 2015 Share Posted June 4, 2015 sendmail is the default daemon for php on windows and unix based systems i recomend using it... Quote Link to comment https://forums.phpfreaks.com/topic/296634-php-mail-function-cant-send-email/#findComment-1513137 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.