I am trying to send mail from localhost using PHP. I am using the following code to send the mail :-
Go to your php.ini file and change SMTP = localhost to SMTP = aspmx.l.google.com and uncomment sendmail_from and put in your sending gmail address. and set smtp_port = 25
Restart localhost