diff --git a/setup/email.test.php b/setup/email.test.php index 76df1e542..bcf7935d8 100644 --- a/setup/email.test.php +++ b/setup/email.test.php @@ -26,7 +26,7 @@ function CheckEmailSetting($oP) $sPhpIniFile = 'php.ini'; } - $bIsWindows = (array_key_exists('WINDIR', $_SERVER)); + $bIsWindows = (array_key_exists('WINDIR', $_SERVER)); if ($bIsWindows) { $sSmtpServer = ini_get('SMTP'); @@ -62,6 +62,16 @@ function CheckEmailSetting($oP) else { // Not a windows system + $sSendMail = ini_get('sendmail_path'); + if (empty($sSendMail)) + { + $oP->error("The command to send mail is not defined. Please add the 'sendmail_path' directive into $sPhpIniFile. A recommended setting is sendmail_path=sendmail -t -i"); + $bRet = false; + } + else + { + $oP->info("The command to send mail: $sSendMail. To change this value, modify the 'sendmail_path' directive into $sPhpIniFile"); + } } if ($bRet) {