TA的每日心情 | 擦汗 2018-1-24 08:13 |
---|
签到天数: 492 天 连续签到: 2 天 [LV.9]测试副司令
|
我用mantis+xampp搭建的mantis,邮箱配置这块按照网络上的教程进行配置,总是不成功,请教我下面的config_defaults_inc.php配置哪里不对?
/***************************
* MantisBT Email Settings *
***************************/
/**
* Administrator Email address
* @global string $g_administrator_email
*/
/*$g_administrator_email = 'administrator@example.com';
*/
$g_administrator_email = 'xxxxx@126.com';
/**
* Webmaster email
* @global string $g_webmaster_email
*/
/*$g_webmaster_email = 'webmaster@example.com';*/
$g_webmaster_email = 'xxxxx@126.com';
/**
* the sender email, part of 'From: ' header in emails
* @global string $g_from_email
*/
/*$g_from_email = 'noreply@example.com';*/
$g_from_email = 'xxxxx@126.com';
/**
* the sender name, part of 'From: ' header in emails
* @global string $g_from_name
*/
/*$g_from_name = 'Mantis Bug Tracker';*/
$g_from_name = 'xxxxx';
/**
* the return address for bounced mail
* @global string $g_return_path_email
*/
/*$g_return_path_email = 'admin@example.com';*/
$g_return_path_email = 'xxxxx@126.com';
/**
* Allow email notification.
* Set to ON to enable email notifications, OFF to disable them. Note that
* disabling email notifications has no effect on emails generated as part
* of the user signup process. When set to OFF, the password reset feature
* is disabled. Additionally, notifications of administrators updating
* accounts are not sent to users.
* @global int $g_enable_email_notification
*/
$g_enable_email_notification = ON;
$g_default_notify_flags = array('reporter' => ON,
'handler' => ON,
'monitor' => ON,
'bugnotes' => ON,
'explicit' => ON,
'threshold_min' => NOBODY,
'threshold_max' => NOBODY);
/**
* We don't need to send these notifications on new bugs
* (see above for info on this config option)
* @todo (though I'm not sure they need to be turned off anymore
* - there just won't be anyone in those categories)
* I guess it serves as an example and a placeholder for this
* config option
* @see $g_default_notify_flags
* @global array $g_notify_flags
*/
$g_notify_flags['new'] = array('bugnotes' => OFF,
'monitor' => OFF);
$g_notify_flags['monitor'] = array( 'reporter' => OFF,
'handler' => OFF,
'monitor' => OFF,
'bugnotes' => OFF,
'explicit' => ON,
'threshold_min' => NOBODY,
'threshold_max' => NOBODY);
/**
* Whether user's should receive emails for their own actions
* @global int $g_email_receive_own
*/
$g_email_receive_own = OFF;
/**
* set to OFF to disable email check
* @global int $g_validate_email
*/
$g_validate_email = ON;
/**
* set to OFF to disable email check
* @global int $g_check_mx_record
*/
$g_check_mx_record = OFF;
/**
* if ON, allow the user to omit an email field
* note if you allow users to create their own accounts, they
* must specify an email at that point, no matter what the value
* of this option is. Otherwise they wouldn't get their passwords.
* @global int $g_allow_blank_email
*/
$g_allow_blank_email = OFF;
/**
* Only allow and send email to addresses in the given domain
* For example:
* $g_limit_email_domain = 'users.sourceforge.net';
* @global string|int $g_limit_email_domain
*/
$g_limit_email_domain = OFF;
/**
* This specifies the access level that is needed to get the mailto: links.
* @global int $g_show_user_email_threshold
*/
$g_show_user_email_threshold = NOBODY;
/**
* This specifies the access level that is needed to see realnames on user view page
* @global int $g_show_user_realname_threshold
*/
$g_show_user_realname_threshold = NOBODY;
/**
* If use_x_priority is set to ON, what should the value be?
* Urgent = 1, Not Urgent = 5, Disable = 0
* Note: some MTAs interpret X-Priority = 0 to mean 'Very Urgent'
* @global int $g_mail_priority
*/
$g_mail_priority = 3;
/**
* select the method to mail by:
* PHPMAILER_METHOD_MAIL - mail()
* PHPMAILER_METHOD_SENDMAIL - sendmail
* PHPMAILER_METHOD_SMTP - SMTP
* @global int $g_phpMailer_method
*/
$g_phpMailer_method = PHPMAILER_METHOD_MAIL;
/**
* This option allows you to use a remote SMTP host. Must use the phpMailer script
* One or more hosts, separated by a semicolon, can be listed.
* You can also specify a different port for each host by using this
* format: [hostname:port] (e.g. "smtp1.example.com:25;smtp2.example.com").
* Hosts will be tried in order.
* @global string $g_smtp_host
*/
/*$g_smtp_host = 'localhost';*/
$g_smtp_host = 'smtp.126.com:25';
/**
* These options allow you to use SMTP Authentication when you use a remote
* SMTP host with phpMailer. If smtp_username is not '' then the username
* and password will be used when logging in to the SMTP server.
* @global string $g_smtp_username
*/
/*$g_smtp_username = '';*/
$g_smtp_username = 'xxxxx';
/**
* SMTP Server Authentication password
* @global string $g_smtp_password
*/
/*$g_smtp_password = '';*/
$g_smtp_password = 'sss';
/**
* This control the connection mode to SMTP server. Can be 'ssl' or 'tls'
* @global string $g_smtp_connection_mode
*/
$g_smtp_connection_mode = '';
/**
* The smtp port to use. The typical SMTP ports are 25 and 587. The port to use
* will depend on the SMTP server configuration and hence others may be used.
* @global int $g_smtp_port
*/
$g_smtp_port = 25;
/**
* It is recommended to use a cronjob or a scheduler task to send emails.
* The cronjob should typically run every 5 minutes. If no cronjob is used,
* then user will have to wait for emails to be sent after performing an action
* which triggers notifications. This slows user performance.
* @global int $g_email_send_using_cronjob
*/
$g_email_send_using_cronjob = OFF;
/**
* Specify whether e-mails should be sent with the category set or not. This is tested
* with Microsoft Outlook. More testing for this feature + other formats will be added
* in the future.
* OFF, EMAIL_CATEGORY_PROJECT_CATEGORY (format: [Project] Category)
* @global int $g_email_set_category
*/
$g_email_set_category = OFF;
/**
* email separator and padding
* @global string $g_email_separator1
*/
$g_email_separator1 = str_pad('', 70, '=');
/**
* email separator and padding
* @global string $g_email_separator2
*/
$g_email_separator2 = str_pad('', 70, '-');
/**
* email separator and padding
* @global int $g_email_padding_length
*/
$g_email_padding_length = 28;
问题1 :这段代码加粗的地方哪里设置不对吗?反正还是不能发送邮件。
问题2:phpmailer需要自己下载放在特定位置吗?需要另外配置phpmailer吗?
问题3:配置中输入的邮箱全部是同一个邮箱账户吗?是否分收件邮箱和发件邮箱?
问题4:配置为126的smtp,也可以收发foxmail邮箱的邮件吧? |
|