PluginProbe
Authorizer / 2.9.0
Authorizer v2.9.0
3.15.3 3.15.2 3.15.1 3.15.0 3.14.3 3.14.4 3.14.2 3.14.1 2.8.1 2.8.2 2.8.3 2.8.4 2.8.5 2.8.6 2.8.7 2.8.8 2.9.0 2.9.1 2.9.10 2.9.11 2.9.12 2.9.13 2.9.2 2.9.3 2.9.6 All 126 releases
authorizer / src / authorizer / options / class-external.php

class-external.php in Authorizer 2.9.0, at src/authorizer/options/class-external.php

57 lines 1.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Authorizer
4 *
5 * @license GPL-2.0+
6 * @link https://github.com/uhm-coe/authorizer
7 * @package authorizer
8 */
9
10 namespace Authorizer\Options;
11
12 use Authorizer\Helper;
13 use Authorizer\Options;
14
15 /**
16 * Contains functions for rendering the External Service tab in Authorizer Settings.
17 */
18 class External extends \Authorizer\Static_Instance {
19
20 /**
21 * Settings print callback.
22 *
23 * @param string $args Args (e.g., multisite admin mode).
24 * @return void
25 */
26 public function print_section_info_external( $args = '' ) {
27 ?>
28 <div id="section_info_external" class="section_info">
29 <p><?php esc_html_e( 'Enter your external server settings below.', 'authorizer' ); ?></p>
30 </div>
31 <?php
32 }
33
34
35 /**
36 * Settings print callback.
37 *
38 * @param string $args Args (e.g., multisite admin mode).
39 * @return void
40 */
41 public function print_select_auth_access_default_role( $args = '' ) {
42 // Get plugin option.
43 $options = Options::get_instance();
44 $option = 'access_default_role';
45 $auth_settings_option = $options->get( $option, Helper::get_context( $args ), 'allow override', 'print overlay' );
46
47 // Print option elements.
48 ?>
49 <select id="auth_settings_<?php echo esc_attr( $option ); ?>" name="auth_settings[<?php echo esc_attr( $option ); ?>]">
50 <?php wp_dropdown_roles( $auth_settings_option ); ?>
51 <option value=""<?php selected( '' === $auth_settings_option ); ?>><?php esc_html_e( '-- None --', 'authorizer' ); ?></option>
52 </select>
53 <?php
54 }
55
56 }
57