I dont think that you can use gmail as your local smtp server. The link was given as a trivial information. If you want to use the mail() function of PHP via Gmail maybe you should look at the one I gave you or use your FAI smtp or install a smtp server on your machine. I may be wrong but using some smtp servers sometimes requires you to first connect via pop or imap and then you can use the smtp.
Mail couldn't send using gmail smtp in php localhost
Question
I'm trying to send emails from my php localhost.
I edited the following files according to a working tutorial (https://www.youtube.com/watch?v=TO7MfDcM-Ho)
php.ini
and sendmail.ini
Used gmail smtp server in sendmail.ini
smtp_server=smtp.gmail.com
smtp_port=587
auth_username=myemail
auth_password=mypass
When I tried to send the mail, there isn't any error but the mail isn't receiving.
Can anybody tell me where did I go wrong? Should I change anything in the gmail account which I used for the authentication in sendmail.ini
?
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow