0

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 ?

user1012181
  • 7,800
  • 8
  • 54
  • 96

1 Answers1

0

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.

AMS
  • 419
  • 2
  • 12
  • In the example given in the question, it works really well for 90% of the people who tried it. So that's why I got this doubt. – user1012181 Mar 25 '14 at 16:23
  • my bad post your sendmail.ini maybe you forgot something, and post your mail() function. – AMS Mar 26 '14 at 08:01