[ Index ]

PHP Cross Reference of Unnamed Project

title

Body

[close]

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

   1  <?php
   2  
   3      global $CFG;
   4  
   5      // Set to defaults if undefined
   6      if (!isset($config->auth_instructions) or empty($config->user_attribute)) {
   7          $config->auth_instructions = get_string('auth_shib_instructions', 'auth_shibboleth', $CFG->wwwroot.'/auth/shibboleth/index.php');
   8      }
   9      if (!isset ($config->user_attribute)) {
  10          $config->user_attribute = '';
  11      }
  12      if (!isset ($config->convert_data)) {
  13          $config->convert_data = '';
  14      }
  15      if (!isset($config->changepasswordurl)) {
  16          $config->changepasswordurl = '';
  17      }
  18  
  19  ?>
  20  <table cellspacing="0" cellpadding="5" border="0">
  21  
  22  <tr valign="top" class="required">
  23      <td align="right"><label for="user_attribute"><?php print_string("username") ?>: </label></td>
  24      <td>
  25          <input id="user_attribute" name="user_attribute" type="text" size="30" value="<?php echo $config->user_attribute ?>" />
  26      </td>
  27      <td><?php print_string("auth_shib_username_description", "auth_shibboleth") ?></td>
  28  </tr>
  29  
  30  <tr valign="top">
  31      <td align="right"><label for="convert_data"><?php print_string("auth_shib_convert_data", "auth_shibboleth") ?>: </label></td>
  32      <td>
  33          <input name="convert_data" id="convert_data" type="text" size="30" value="<?php echo $config->convert_data?>" />
  34          <?php
  35  
  36          if ($config->convert_data and $config->convert_data != '' and !is_readable($config->convert_data)) {
  37                echo '<br/><span class="notifyproblem">';
  38                print_string("auth_shib_convert_data_warning", "auth_shibboleth");
  39                echo '</span>';
  40          }
  41  
  42          ?>
  43      </td>
  44      <td><?php print_string("auth_shib_convert_data_description", "auth_shibboleth"); echo (isset($config->alt_login) ? $config->alt_login : '') ?></td>
  45  </tr>
  46  
  47  <tr valign="top">
  48      <td align="right"><?php print_string("auth_shib_integrated_wayf", "auth_shibboleth") ?>:</td>
  49      <td>
  50          <input name="alt_login" type="checkbox" <?php
  51          if ( isset($config->alt_login) and $config->alt_login == 'on' ){
  52                  echo 'checked="checked"';
  53              }
  54          ?> />
  55      </td>
  56      <td><?php print_string("auth_shib_integrated_wayf_description", "auth_shibboleth") ?></td>
  57  </tr>
  58  
  59  <tr valign="top">
  60      <td align="right"><?php print_string("auth_shib_idp_list", "auth_shibboleth") ?>:</td>
  61      <td>
  62          <textarea name="organization_selection" rows="10" cols="30" style="overflow: auto;"
  63  ><?php
  64          if (!isset($config->organization_selection)){
  65              echo  'urn:mace:organization1:providerID, Example Organization 1
  66  https://another.idp-id.com/shibboleth, Other Example Organization, /Shibboleth.sso/DS/SWITCHaai
  67  urn:mace:organization2:providerID, Example Organization 2, /Shibboleth.sso/WAYF/SWITCHaai';
  68          } else {
  69              echo htmlentities($config->organization_selection);
  70          }
  71          ?>
  72  </textarea>
  73      <?php
  74         if (isset($config->organization_selection) && empty($config->organization_selection) && isset($config->alt_login) && $config->alt_login == 'on') {
  75                echo '<br/><span class="notifyproblem">';
  76                print_string("auth_shib_no_organizations_warning", "auth_shibboleth");
  77                echo '</span>';
  78          }
  79      ?>
  80      </td>
  81      <td><?php print_string("auth_shib_idp_list_description", "auth_shibboleth") ?></td>
  82  </tr>
  83  
  84  <tr valign="top">
  85      <td align="right"><label for="logout_handler"><?php print_string("auth_shib_logout_url", "auth_shibboleth") ?>: </label></td>
  86      <td>
  87          <input name="logout_handler" id="logout_handler" type="text" size="30" value="<?php
  88          if ( isset($config->logout_handler) and !empty($config->logout_handler)){
  89              echo $config->logout_handler;
  90          }
  91          ?>" />
  92      </td>
  93      <td><?php print_string("auth_shib_logout_url_description", "auth_shibboleth") ?></td>
  94  </tr>
  95  
  96  <tr valign="top">
  97      <td align="right"><label for="logout_return_url"><?php print_string("auth_shib_logout_return_url", "auth_shibboleth") ?>: </label></td>
  98      <td>
  99          <input name="logout_return_url" id="logout_return_url" type="text" size="30" value="<?php
 100          if ( isset($config->logout_return_url) and !empty($config->logout_return_url)){
 101              echo $config->logout_return_url;
 102          }
 103          ?>" />
 104      </td>
 105      <td><?php print_string("auth_shib_logout_return_url_description", "auth_shibboleth") ?></td>
 106  </tr>
 107  
 108  <tr valign="top">
 109      <td align="right"><label for="login_name"><?php print_string("auth_shib_auth_method", "auth_shibboleth") ?>: </label></td>
 110      <td>
 111          <input name="login_name" id="login_name" type="text" size="30" value="<?php
 112          if ( isset($config->login_name) and !empty($config->login_name)){
 113              echo htmlentities($config->login_name);
 114          } else {
 115              echo 'Shibboleth Login';
 116          }
 117          ?>" />
 118      </td>
 119      <td><?php print_string("auth_shib_auth_method_description", "auth_shibboleth") ?></td>
 120  </tr>
 121  
 122  <tr valign="top">
 123      <td align="right"><label for="changepasswordurl"><?php print_string('auth_shib_changepasswordurl', 'auth_shibboleth') ?>: </label></td>
 124      <td>
 125          <input name="changepasswordurl" id="changepasswordurl" type="text" value="<?php echo $config->changepasswordurl ?>" />
 126          <?php
 127  
 128          if (isset($err['changepasswordurl'])) {
 129              echo $OUTPUT->error_text($err['changepasswordurl']);
 130          }
 131  
 132          ?>
 133      </td>
 134      <td><?php print_string('changepasswordhelp', 'auth') ?></td>
 135  </tr>
 136  
 137  
 138  
 139  <?php
 140  
 141  print_auth_lock_options($this->authtype, $user_fields, '<!-- empty help -->', true, false, $this->get_custom_user_profile_fields());
 142  
 143  ?>
 144  </table>


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