This guide helps to setup your SMTP2GO server as Outgoing SMTP Server in cakePHP Framework.
This guide provides a simple script to send an email with both html and text bodies using EmailComponent. To know more about EmailComponent, please click here.
Please change the following variables in this guide:
Sender Name: the sender’s name.
email@example.com: the sender’s email address.
Recipient Name: the recipient’s name.
firstname.lastname@example.org: the recipient’s email address.
USERNAME: your SMTP username.
PASSWORD: your SMTP password.
welcome.ctp: the file name of your template.
Define the text and html templates in following files respectively:
Define the text and html layouts in following files respectively:
Add the email component as below in your controller:
Add the following code in your controller:
Try SMTP2GO free for as long as you like:Try SMTP2GO Free → Paid plans available for over 1,000 emails/month.