Many friends are worried about PHP's MAIL function. In fact, the key is its SMTP service problem. Most of the currently used 163, sina, etc. do not support anonymous sending of emails, which means that even if you set the smtp in php.ini to smtp.163.net/smtp.sina.com.cn, an error will be prompted. What to do? Today I got an email service software called IMAIL. I gave it a try and it actually worked. The method is now explained as follows:
1. Install IMAIL. According to the default installation, generally if the name of your machine is server, then its SMTP service name is also server.
2. Check "Control Panel" - "Services" to see if the IMAIL SMTP SERVER is up.
3. Modify php.ini. Set smtp= server
4. Test it.
echo "