3 // set to defaults if undefined
4 if (!isset($config->host
)) {
5 $config->host
= '127.0.0.1';
7 if (!isset($config->type
)) {
8 $config->type
= 'imap';
10 if (!isset($config->port
)) {
11 $config->port
= '143';
13 if (!isset($config->changepasswordurl
)) {
14 $config->changepasswordurl
= '';
18 <table cellspacing=
"0" cellpadding=
"5" border=
"0">
20 <tr valign=
"top" class=
"required">
21 <td align=
"right"><?php print_string('auth_imaphost_key', 'auth') ?>:
</td>
23 <input name=
"host" type=
"text" size=
"30" value=
"<?php echo $config->host ?>" />
26 if (isset($err['host'])) {
27 formerr($err['host']);
35 print_string('auth_imaphost', 'auth');
36 print_string('auth_multiplehosts', 'auth');
42 <tr valign=
"top" class=
"required">
43 <td align=
"right"><?php print_string('auth_imaptype_key', 'auth') ?>:
</td>
47 $imaptypes = array('imap', 'imapssl', 'imapcert', 'imaptls');
48 foreach ($imaptypes as $imaptype) {
49 $imapoptions[$imaptype] = $imaptype;
51 choose_from_menu($imapoptions, 'type', $config->type
, '');
55 <td><?php print_string('auth_imaptype', 'auth') ?></td>
58 <tr valign=
"top" class=
"required">
59 <td align=
"right"><?php print_string('auth_imapport_key', 'auth') ?>:
</td>
61 <input name=
"port" type=
"text" size=
"6" value=
"<?php echo $config->port ?>" />
64 if (isset($err['port'])) {
65 formerr($err['port']);
70 <td><?php print_string('auth_imapport', 'auth') ?></td>
74 <td align=
"right"><?php print_string('auth_imapchangepasswordurl_key', 'auth') ?>:
</td>
76 <input name=
"changepasswordurl" type=
"text" value=
"<?php echo $config->changepasswordurl ?>" />
79 if (isset($err['changepasswordurl'])) {
80 formerr($err['changepasswordurl']);
85 <td><?php print_string('changepasswordhelp', 'auth') ?></td>
90 print_auth_lock_options('imap', $user_fields, get_string('auth_fieldlocks_help', 'auth'), false, false);