在php.ini文件中修改php
[mail function] SMTP = smtp.qq.com smtp_port = 465 sendmail_from = 你的QQ@qq.com sendmail_path =你的QQ@qq.com
要使用SSL,繼續修改php.iniweb
extension=php_openssl.dll
修改config_defaults_inc.php 測試
$g_administrator_email = '你的QQ@qq.com'; $g_webmaster_email = '你的QQ@qq.com'; $g_from_email = '你的QQ@qq.com'; $g_return_path_email = '你的QQ@qq.com'; $g_enable_email_notification = ON; $g_mail_priority = 3; $g_phpMailer_method = PHPMAILER_METHOD_SMTP; $g_smtp_host = 'smtp.qq.com'; $g_smtp_username = '你的QQ@qq.com'; $g_smtp_password = '密碼'; $g_smtp_connection_mode = 'ssl'; $g_smtp_port = 465;
最後測試郵件spa