Completed
Push — stable13 ( 052469...e0147a )
by Morris
14:32
created
settings/templates/settings/admin/additional-mail.php 2 patches
Braces   +24 added lines, -6 removed lines patch added patch discarded remove patch
@@ -71,11 +71,17 @@  discard block
 block discarded – undo
71 71
 			</select>
72 72
 
73 73
 			<label id="mail_smtpsecure_label" for="mail_smtpsecure"
74
-				<?php if ($_['mail_smtpmode'] !== 'smtp') print_unescaped(' class="hidden"'); ?>>
74
+				<?php if ($_['mail_smtpmode'] !== 'smtp') {
75
+    print_unescaped(' class="hidden"');
76
+}
77
+?>>
75 78
 				<?php p($l->t('Encryption')); ?>
76 79
 			</label>
77 80
 			<select name="mail_smtpsecure" id="mail_smtpsecure"
78
-				<?php if ($_['mail_smtpmode'] !== 'smtp') print_unescaped(' class="hidden"'); ?>>
81
+				<?php if ($_['mail_smtpmode'] !== 'smtp') {
82
+    print_unescaped(' class="hidden"');
83
+}
84
+?>>
79 85
 				<?php foreach ($mail_smtpsecure as $secure => $name):
80 86
 					$selected = '';
81 87
 					if ($secure == $_['mail_smtpsecure']):
@@ -94,7 +100,10 @@  discard block
 block discarded – undo
94 100
 				   value="<?php p($_['mail_domain']) ?>" />
95 101
 		</p>
96 102
 
97
-		<p id="setting_smtpauth" <?php if ($_['mail_smtpmode'] !== 'smtp') print_unescaped(' class="hidden"'); ?>>
103
+		<p id="setting_smtpauth" <?php if ($_['mail_smtpmode'] !== 'smtp') {
104
+    print_unescaped(' class="hidden"');
105
+}
106
+?>>
98 107
 			<label for="mail_smtpauthtype"><?php p($l->t('Authentication method')); ?></label>
99 108
 			<select name="mail_smtpauthtype" id="mail_smtpauthtype">
100 109
 				<?php foreach ($mail_smtpauthtype as $authtype => $name):
@@ -107,11 +116,17 @@  discard block
 block discarded – undo
107 116
 			</select>
108 117
 
109 118
 			<input type="checkbox" name="mail_smtpauth" id="mail_smtpauth" class="checkbox" value="1"
110
-				<?php if ($_['mail_smtpauth']) print_unescaped('checked="checked"'); ?> />
119
+				<?php if ($_['mail_smtpauth']) {
120
+    print_unescaped('checked="checked"');
121
+}
122
+?> />
111 123
 			<label for="mail_smtpauth"><?php p($l->t('Authentication required')); ?></label>
112 124
 		</p>
113 125
 
114
-		<p id="setting_smtphost" <?php if ($_['mail_smtpmode'] !== 'smtp') print_unescaped(' class="hidden"'); ?>>
126
+		<p id="setting_smtphost" <?php if ($_['mail_smtpmode'] !== 'smtp') {
127
+    print_unescaped(' class="hidden"');
128
+}
129
+?>>
115 130
 			<label for="mail_smtphost"><?php p($l->t('Server address')); ?></label>
116 131
 			<input type="text" name="mail_smtphost" id="mail_smtphost" placeholder="smtp.example.com"
117 132
 				   value="<?php p($_['mail_smtphost']) ?>" />
@@ -121,7 +136,10 @@  discard block
 block discarded – undo
121 136
 		</p>
122 137
 	</form>
123 138
 	<form class="mail_settings" id="mail_credentials_settings">
124
-		<p id="mail_credentials" <?php if (!$_['mail_smtpauth'] || $_['mail_smtpmode'] !== 'smtp') print_unescaped(' class="hidden"'); ?>>
139
+		<p id="mail_credentials" <?php if (!$_['mail_smtpauth'] || $_['mail_smtpmode'] !== 'smtp') {
140
+    print_unescaped(' class="hidden"');
141
+}
142
+?>>
125 143
 			<label for="mail_smtpname"><?php p($l->t('Credentials')); ?></label>
126 144
 			<input type="text" name="mail_smtpname" id="mail_smtpname" placeholder="<?php p($l->t('SMTP Username'))?>"
127 145
 				   value="<?php p($_['mail_smtpname']) ?>" />
Please login to merge, or discard this patch.
Indentation   +23 added lines, -23 removed lines patch added patch discarded remove patch
@@ -25,27 +25,27 @@  discard block
 block discarded – undo
25 25
 /** @var array $_ */
26 26
 
27 27
 $mail_smtpauthtype = [
28
-	''	=> $l->t('None'),
29
-	'LOGIN'	=> $l->t('Login'),
30
-	'PLAIN'	=> $l->t('Plain'),
31
-	'NTLM'	=> $l->t('NT LAN Manager'),
28
+    ''	=> $l->t('None'),
29
+    'LOGIN'	=> $l->t('Login'),
30
+    'PLAIN'	=> $l->t('Plain'),
31
+    'NTLM'	=> $l->t('NT LAN Manager'),
32 32
 ];
33 33
 
34 34
 $mail_smtpsecure = [
35
-	''		=> $l->t('None'),
36
-	'ssl'	=> $l->t('SSL/TLS'),
37
-	'tls'	=> $l->t('STARTTLS'),
35
+    ''		=> $l->t('None'),
36
+    'ssl'	=> $l->t('SSL/TLS'),
37
+    'tls'	=> $l->t('STARTTLS'),
38 38
 ];
39 39
 
40 40
 $mail_smtpmode = [
41
-	['php', 'PHP'],
42
-	['smtp', 'SMTP'],
41
+    ['php', 'PHP'],
42
+    ['smtp', 'SMTP'],
43 43
 ];
44 44
 if ($_['sendmail_is_available']) {
45
-	$mail_smtpmode[] = ['sendmail', 'Sendmail'];
45
+    $mail_smtpmode[] = ['sendmail', 'Sendmail'];
46 46
 }
47 47
 if ($_['mail_smtpmode'] === 'qmail') {
48
-	$mail_smtpmode[] = ['qmail', 'qmail'];
48
+    $mail_smtpmode[] = ['qmail', 'qmail'];
49 49
 }
50 50
 
51 51
 ?>
@@ -63,10 +63,10 @@  discard block
 block discarded – undo
63 63
 			<label for="mail_smtpmode"><?php p($l->t('Send mode')); ?></label>
64 64
 			<select name="mail_smtpmode" id="mail_smtpmode">
65 65
 				<?php foreach ($mail_smtpmode as $smtpmode):
66
-					$selected = '';
67
-					if ($smtpmode[0] == $_['mail_smtpmode']):
68
-						$selected = 'selected="selected"';
69
-					endif; ?>
66
+                    $selected = '';
67
+                    if ($smtpmode[0] == $_['mail_smtpmode']):
68
+                        $selected = 'selected="selected"';
69
+                    endif; ?>
70 70
 					<option value="<?php p($smtpmode[0])?>" <?php p($selected) ?>><?php p($smtpmode[1]) ?></option>
71 71
 				<?php endforeach;?>
72 72
 			</select>
@@ -78,10 +78,10 @@  discard block
 block discarded – undo
78 78
 			<select name="mail_smtpsecure" id="mail_smtpsecure"
79 79
 				<?php if ($_['mail_smtpmode'] !== 'smtp') print_unescaped(' class="hidden"'); ?>>
80 80
 				<?php foreach ($mail_smtpsecure as $secure => $name):
81
-					$selected = '';
82
-					if ($secure == $_['mail_smtpsecure']):
83
-						$selected = 'selected="selected"';
84
-					endif; ?>
81
+                    $selected = '';
82
+                    if ($secure == $_['mail_smtpsecure']):
83
+                        $selected = 'selected="selected"';
84
+                    endif; ?>
85 85
 					<option value="<?php p($secure)?>" <?php p($selected) ?>><?php p($name) ?></option>
86 86
 				<?php endforeach;?>
87 87
 			</select>
@@ -99,10 +99,10 @@  discard block
 block discarded – undo
99 99
 			<label for="mail_smtpauthtype"><?php p($l->t('Authentication method')); ?></label>
100 100
 			<select name="mail_smtpauthtype" id="mail_smtpauthtype">
101 101
 				<?php foreach ($mail_smtpauthtype as $authtype => $name):
102
-					$selected = '';
103
-					if ($authtype == $_['mail_smtpauthtype']):
104
-						$selected = 'selected="selected"';
105
-					endif; ?>
102
+                    $selected = '';
103
+                    if ($authtype == $_['mail_smtpauthtype']):
104
+                        $selected = 'selected="selected"';
105
+                    endif; ?>
106 106
 					<option value="<?php p($authtype)?>" <?php p($selected) ?>><?php p($name) ?></option>
107 107
 				<?php endforeach;?>
108 108
 			</select>
Please login to merge, or discard this patch.