diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2018-06-07 20:36:17 +0200 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2018-07-04 08:28:33 +0200 |
commit | 0dd4a3e0cfb5ef34ef0cbba0a6b7ac82f469b8be (patch) | |
tree | b2c4cbcf789e2693886ac0f9be103f2545dd2c8e | |
parent | 65bcef8fb3afc71ed85de6cd9d5480a1846568ee (diff) | |
download | nextcloud-server-0dd4a3e0cfb5ef34ef0cbba0a6b7ac82f469b8be.tar.gz nextcloud-server-0dd4a3e0cfb5ef34ef0cbba0a6b7ac82f469b8be.zip |
Kill php mail from settings
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
-rw-r--r-- | config/config.sample.php | 11 | ||||
-rw-r--r-- | lib/private/Settings/Admin/Mail.php | 4 | ||||
-rw-r--r-- | settings/templates/settings/admin/additional-mail.php | 1 |
3 files changed, 7 insertions, 9 deletions
diff --git a/config/config.sample.php b/config/config.sample.php index 68f27ed0323..5c6ca58a640 100644 --- a/config/config.sample.php +++ b/config/config.sample.php @@ -328,24 +328,19 @@ $CONFIG = array( 'mail_smtpdebug' => false, /** - * Which mode to use for sending mail: ``sendmail``, ``smtp``, ``qmail`` or - * ``php``. + * Which mode to use for sending mail: ``sendmail``, ``smtp`` or ``qmail``. * * If you are using local or remote SMTP, set this to ``smtp``. * - * If you are using PHP mail you must have an installed and working email system - * on the server. The program used to send email is defined in the ``php.ini`` - * file. - * * For the ``sendmail`` option you need an installed and working email system on * the server, with ``/usr/sbin/sendmail`` installed on your Unix system. * * For ``qmail`` the binary is /var/qmail/bin/sendmail, and it must be installed * on your Unix system. * - * Defaults to ``php`` + * Defaults to ``smtp`` */ -'mail_smtpmode' => 'php', +'mail_smtpmode' => 'smtp', /** * This depends on ``mail_smtpmode``. Specify the IP address of your mail diff --git a/lib/private/Settings/Admin/Mail.php b/lib/private/Settings/Admin/Mail.php index 74a94a4c7a0..fc20b7eeb3f 100644 --- a/lib/private/Settings/Admin/Mail.php +++ b/lib/private/Settings/Admin/Mail.php @@ -63,6 +63,10 @@ class Mail implements ISettings { $parameters['mail_smtppassword'] = '********'; } + if ($parameters['mail_smtpmode'] === '' || $parameters['mail_smtpmode'] === 'php') { + $parameters['mail_smtpmode'] = 'smtp'; + } + return new TemplateResponse('settings', 'settings/admin/additional-mail', $parameters, ''); } diff --git a/settings/templates/settings/admin/additional-mail.php b/settings/templates/settings/admin/additional-mail.php index adcc5293ff1..1e0b458f60f 100644 --- a/settings/templates/settings/admin/additional-mail.php +++ b/settings/templates/settings/admin/additional-mail.php @@ -38,7 +38,6 @@ $mail_smtpsecure = [ ]; $mail_smtpmode = [ - ['php', 'PHP'], ['smtp', 'SMTP'], ]; if ($_['sendmail_is_available']) { |