[ Index ]

PHP Cross Reference of Unnamed Project

title

Body

[close]

/auth/imap/ -> config.html (source)

   1  <?php
   2  
   3  // set to defaults if undefined
   4  if (!isset($config->host)) {
   5      $config->host = '127.0.0.1';
   6  }
   7  if (!isset($config->type)) {
   8      $config->type = 'imap';
   9  }
  10  if (!isset($config->port)) {
  11      $config->port = '143';
  12  }
  13  if (!isset($config->changepasswordurl)) {
  14      $config->changepasswordurl = '';
  15  }
  16  
  17  ?>
  18  <table cellspacing="0" cellpadding="5" border="0">
  19  
  20  <tr valign="top" class="required">
  21      <td align="right"><label for="host"><?php print_string('auth_imaphost_key', 'auth_imap') ?>: </label></td>
  22      <td>
  23          <input name="host" id="host" type="text" size="30" value="<?php echo $config->host ?>" />
  24          <?php
  25  
  26          if (isset($err['host'])) {
  27              echo $OUTPUT->error_text($err['host']);
  28          }
  29  
  30          ?>
  31      </td>
  32      <td>
  33          <?php
  34  
  35          print_string('auth_imaphost', 'auth_imap');
  36          print_string('auth_multiplehosts', 'auth');
  37  
  38          ?>
  39      </td>
  40  </tr>
  41  
  42  <tr valign="top" class="required">
  43      <td align="right"><?php echo html_writer::label(get_string('auth_imaptype_key', 'auth_imap'), 'menutype'); ?>: </td>
  44      <td>
  45          <?php
  46  
  47          $imaptypes = array('imap', 'imapssl', 'imapcert', 'imapnosslcert', 'imaptls');
  48          foreach ($imaptypes as $imaptype) {
  49              $imapoptions[$imaptype] = $imaptype;
  50          }
  51          echo html_writer::select($imapoptions, 'type', $config->type, false);
  52  
  53          ?>
  54      </td>
  55      <td><?php print_string('auth_imaptype', 'auth_imap') ?></td>
  56  </tr>
  57  
  58  <tr valign="top" class="required">
  59      <td align="right"><label for="port"><?php print_string('auth_imapport_key', 'auth_imap') ?>: </label></td>
  60      <td>
  61          <input name="port" id="port" type="text" size="6" value="<?php echo $config->port ?>" />
  62          <?php
  63  
  64          if (isset($err['port'])) {
  65              echo $OUTPUT->error_text($err['port']);
  66          }
  67  
  68          ?>
  69      </td>
  70      <td><?php print_string('auth_imapport', 'auth_imap') ?></td>
  71  </tr>
  72  
  73  <tr valign="top">
  74      <td align="right"><label for="changepasswordurl"><?php print_string('auth_imapchangepasswordurl_key', 'auth_imap') ?>: </label></td>
  75      <td>
  76          <input name="changepasswordurl" id="changepasswordurl" type="text" value="<?php echo $config->changepasswordurl ?>" />
  77          <?php
  78  
  79          if (isset($err['changepasswordurl'])) {
  80              echo $OUTPUT->error_text($err['changepasswordurl']);
  81          }
  82  
  83          ?>
  84      </td>
  85      <td><?php print_string('changepasswordhelp', 'auth') ?></td>
  86  </tr>
  87  
  88  <?php
  89  
  90  print_auth_lock_options($this->authtype, $user_fields, get_string('auth_fieldlocks_help', 'auth'), false, false);
  91  
  92  ?>
  93  </table>


Generated: Thu Aug 11 10:00:09 2016 Cross-referenced by PHPXref 0.7.1