问题
I simply added the following SMTP details:

What's wrong with my configuration then?
Why is that I can't receive any new emails on my gmail account.
Please help me with these. Thank you.
回答1:
I recently came across this issue. Specifically for Gmail I had go to my Google Account Settings and first enable 2-Step Verification. Once that was enabled I could create 'App Passwords'.
This creates a custom password for login and bypasses the 2-step verification. Copy and paste that in your password for login.
The reason this did not work for me even without 2-Step verification enabled is because it was presenting the application originally with a Captcha to solve.
来源:https://stackoverflow.com/questions/23426062/email-configuration-troubleshooting-in-localhost-website