[安装]“ 用于Windows的伪sendmail ”。如果您不使用XAMPP,则可以在这里下载:http ://glob.com.au/sendmail/sendmail.zip
@H_419_6@[Modify] the PHP.ini file to use it (commented out the other lines): [mail function] ; For Win32 only. ; SMTP = smtp.gmail.com ; smtp_port = 25 ; For Win32 only. ; sendmail_from = <e-mail username>@gmail.com ; For Unix only. You may supply arguments as well (default: "sendmail -t
-i”). sendmail_path = “C:\xampp\sendmail\sendmail.exe -t”
(忽略“仅Unix”位,因为我们实际上正在使用sendmail)
然后,您必须在安装sendmail的目录中配置“ sendmail.ini”文件:
@H_419_6@[sendmail] smtp_server=smtp.gmail.com smtp_port=25 error_logfile=error.log debug_logfile=debug.log auth_username=<username> auth_password=<password> force_sender=<e-mail username>@gmail.com