【发布时间】:2016-03-22 21:19:48
【问题描述】:
我正在尝试将我的 WAMP 服务器配置为通过 sendmail 发送电子邮件我什至设置了 gmail 帐户和所有内容。在此之前,我的 wamp 服务器运行良好(绿色)。但现在它的橙色(2 项服务中的 1 项正在工作)我是使用 WAMP 服务器的新手,所以我不知道问题出在哪里。当我在 Apache 上启用 ssl_module 时问题就开始了
php.ini(来自 WAMP 界面)
[mail function]
; For Win32 only.
; http://php.net/smtp
SMTP = localhost
; http://php.net/smtp-port
smtp_port = 25
; For Win32 only.
; http://php.net/sendmail-from
sendmail_from ="admin@wampserver.invalid"
; For Unix only. You may supply arguments as well (default: "sendmail -t -i").
; http://php.net/sendmail-path
sendmail_path ="C:\wamp\sendmail\sendmail.exe -t -i"
; Force the addition of the specified parameters to be passed as extra parameters
; to the sendmail binary. These parameters will always replace the value of
; the 5th parameter to mail().
;mail.force_extra_parameters =
; Add X-PHP-Originating-Script: that will include uid of the script followed by the filename
mail.add_x_header = On
; The path to a log file that will log all mail() calls. Log entries include
; the full path of the script, line number, To address and headers.
;mail.log =
; Log mail to syslog (Event Log on Windows).
;mail.log = syslog
sendmail.ini
[sendmail]
smtp_server=stmp.gmail.com
smtp_port=465
smtp_ssl=ssl
default_domain=localhost
error_logfile=error.log
debug_logfile=debug.log
auth_username= myemail@gmail.com
auth_password= mypassword
pop3_server=
pop3_username=
pop3_password=
force_sender=
force_recipient=
hostname=localhost
【问题讨论】:
-
橙色表示您的网络服务器未启动,可能是由于您的配置错误。请提供您的服务器的启动日志。
-
@Chris 是 apache 错误日志还是访问日志?...对不起,我是 WAMP 新手