I am using Amazon EC2 Instance for one of my project, I have installed LAMP on linux server and now while I am trying to send email using simple function it is not sending email
I solved this issue just by installing sendmail in my instance. Just run bellow command in your terminal
sudo apt-get install sendmail
That worked for me