PHPMailer – Sending PHP Emails via SMTP

Some hosting service don’t allow users to use PHP to send emails, so need to apply SMTP service like Gmail.


The “Password” for gmail SMTP is not real password of your account, it’s an “Application password” instead. Reference:


Note: ServerZoo don’t allow any outside SMTP service even Gmail. Here is the solution: