It does not matter if you are building your company website, an application that will be used only inside the company you work at, or an e-commerce solution. Eventually, you will need to send e-mails. It is fair to say that every web application has the need, at some point, to send e-mails.
In this recipe, we will learn how to send plain text e-mails using Gmail's SMTP server.
You can use the code of the examples we have used in the previous recipe, or you can start a new project.
Carry out the following steps: