PluginProbe
Two Factor Authentication / 1.12.2
Two Factor Authentication v1.12.2
1.12.2 1.13.0 1.14.10 1.14.11 1.14.14 1.14.15 1.14.16 1.14.17 1.14.23 1.14.24 1.14.26 1.14.27 1.14.3 1.14.4 1.14.5 1.14.7 1.14.8 1.15.5 1.16.0 1.2.10 1.2.12 1.2.13 1.2.14 1.2.15 1.2.16 All 98 releases
two-factor-authentication / includes / user_settings.php

user_settings.php in Two Factor Authentication 1.12.2, at includes/user_settings.php

60 lines 2.0 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 if (!defined('ABSPATH')) die('Access denied.');
4
5 global $current_user, $simba_two_factor_authentication;
6
7 ?>
8 <style>
9 #icon-tfa-plugin {
10 background: transparent url('<?php print plugin_dir_url(__FILE__); ?>img/tfa_admin_icon_32x32.png' ) no-repeat;
11 }
12 .inside > h3, .normal {
13 cursor: default;
14 margin-top: 20px;
15 }
16 </style>
17 <div class="wrap">
18
19 <h2><?php echo __('Two Factor Authentication', 'two-factor-authentication').' '.__('Settings', 'two-factor-authentication'); ?></h2>
20
21 <?php
22
23 if (!empty($tfa_settings_saved)) {
24 echo '<div class="updated notice is-dismissible">'."<p><strong>".__('Settings saved.', 'two-factor-authentication')."</strong></p></div>";
25 }
26
27 $simba_two_factor_authentication->include_template('settings-intro-notices.php');
28
29 ?>
30
31 <form method="post" action="<?php print esc_url(add_query_arg('settings-updated', 'true', $_SERVER['REQUEST_URI'])); ?>">
32
33 <?php wp_nonce_field('tfa_activate', '_tfa_activate_nonce', false, true); ?>
34
35 <h2><?php _e('Activate two factor authentication', 'two-factor-authentication'); ?></h2>
36 <p>
37 <?php
38 $utc_date = gmdate('Y-m-d H:i:s');
39 $date_now = get_date_from_gmt($utc_date, 'Y-m-d H:i:s');
40 echo sprintf(__('N.B. Getting your TFA app/device to generate the correct code depends upon a) you first setting it up by entering or scanning the code below into it, and b) upon your web-server and your TFA app/device agreeing upon the UTC time (within a minute or so). The current UTC time according to the server when this page loaded: %s, and in the time-zone you have configured in your WordPress settings: %s', 'two-factor-authentication'), htmlspecialchars($utc_date), htmlspecialchars($date_now));
41 ?>
42 </p>
43 <p>
44 <?php
45 $simba_two_factor_authentication->paint_enable_tfa_radios($current_user->ID);
46 ?></p>
47 <?php submit_button(); ?>
48 </form>
49 <?php
50
51 $simba_two_factor_authentication->current_codes_box();
52
53 $simba_two_factor_authentication->advanced_settings_box();
54
55 do_action('simba_tfa_user_settings_after_advanced_settings');
56
57 ?>
58
59 </div>
60