PluginProbe ʕ •ᴥ•ʔ
WP Popular Posts / 6.0.1
WP Popular Posts v6.0.1
4.0.8 4.0.9 4.1.0 4.1.1 4.1.2 4.2.0 4.2.1 4.2.2 5.0.0 5.0.1 5.0.2 5.1.0 5.2.0 5.2.1 5.2.2 5.2.3 5.2.4 5.3.0 5.3.1 5.3.2 5.3.3 5.3.4 5.3.5 5.3.6 5.4.0 5.4.1 5.4.2 5.5.0 5.5.1 6.0.0 6.0.1 6.0.2 6.0.3 6.0.4 6.0.5 6.1.0 6.1.1 6.1.2 6.1.3 6.1.4 6.2.0 6.2.1 6.3.0 6.3.1 6.3.2 6.3.3 6.3.4 6.4.0 6.4.1 6.4.2 7.0.0 7.0.1 7.1.0 7.2.0 7.3.0 7.3.1 7.3.2 7.3.3 7.3.4 7.3.5 7.3.6 7.3.7 7.3.8 7.4.0 trunk 2.3.7 3.0.0 3.0.1 3.0.2 3.0.3 3.1.0 3.1.1 3.2.0 3.2.1 3.2.2 3.2.3 3.3.0 3.3.1 3.3.2 3.3.3 3.3.4 4.0.0 4.0.1 4.0.10 4.0.11 4.0.12 4.0.13 4.0.2 4.0.3 4.0.5 4.0.6
wordpress-popular-posts / src / Admin / screen-debug.php
wordpress-popular-posts / src / Admin Last commit date
Admin.php 3 years ago admin-page.php 3 years ago screen-debug.php 3 years ago screen-stats.php 3 years ago screen-tools.php 3 years ago
screen-debug.php
71 lines
1 <?php
2 if ( 'debug' == $current ) {
3
4 if ( ! current_user_can('edit_others_posts') ) {
5 echo '<p style="text-align: center;">' . __('Sorry, you do not have enough permissions to do this. Please contact the site administrator for support.', 'wordpress-popular-posts') . '</p>';
6 }
7 else {
8 global $wpdb, $wp_version;
9
10 $my_theme = wp_get_theme();
11 $site_plugins = get_plugins();
12 $plugin_names = [];
13 $performance_nag = get_option('wpp_performance_nag');
14
15 if ( ! $performance_nag ) {
16 $performance_nag = [
17 'status' => 0,
18 'last_checked' => null
19 ];
20 }
21
22 switch($performance_nag['status']) {
23 case 0:
24 $performance_nag_status = 'Inactive';
25 break;
26 case 1:
27 $performance_nag_status = 'Active';
28 break;
29 case 2:
30 $performance_nag_status = 'Remind me later';
31 break;
32 case 3:
33 $performance_nag_status = 'Dismissed';
34 break;
35 default:
36 $performance_nag_status = 'Inactive';
37 break;
38 }
39
40 foreach( $site_plugins as $main_file => $plugin_meta ) :
41 if ( ! is_plugin_active($main_file) )
42 continue;
43 $plugin_names[] = sanitize_text_field($plugin_meta['Name'] . ' ' . $plugin_meta['Version']);
44 endforeach;
45 ?>
46 <div id="wpp_debug">
47 <h3>Plugin Configuration</h3>
48 <p><strong>Performance Nag:</strong> <?php echo $performance_nag_status; ?></p>
49 <p><strong>Log Limit:</strong> <?php echo ( $this->config['tools']['log']['limit'] ) ? 'Yes, keep data for ' . esc_html($this->config['tools']['log']['expires_after']) . ' days' : 'No'; ?></p>
50 <p><strong>Log Views From:</strong> <?php echo ( 0 == $this->config['tools']['log']['level'] ) ? 'Visitors only' : ( (2 == $this->config['tools']['log']['level']) ? 'Logged-in users only' : 'Everyone' ); ?></p>
51 <p><strong>Data Caching:</strong> <?php echo ( $this->config['tools']['cache']['active'] ) ? 'Yes, ' . $this->config['tools']['cache']['interval']['value'] . ' ' . esc_html($this->config['tools']['cache']['interval']['time']) : 'No'; ?></p>
52 <p><strong>Data Sampling:</strong> <?php echo ( $this->config['tools']['sampling']['active'] ) ? 'Yes, with a rate of ' . esc_html($this->config['tools']['sampling']['rate']) : 'No'; ?></p>
53 <p><strong>External object cache:</strong> <?php echo ( wp_using_ext_object_cache() ) ? 'Yes' : 'No'; ?></p>
54 <p><strong>WPP_CACHE_VIEWS:</strong> <?php echo ( defined('WPP_CACHE_VIEWS') && WPP_CACHE_VIEWS ) ? 'Yes' : 'No'; ?></p>
55
56 <br />
57
58 <h3>System Info</h3>
59 <p><strong>PHP version:</strong> <?php echo phpversion(); ?></p>
60 <p><strong>PHP extensions:</strong> <?php echo implode(', ', get_loaded_extensions()); ?></p>
61 <p><strong>Database version:</strong> <?php echo $wpdb->get_var("SELECT VERSION();"); ?></p>
62 <p><strong>InnoDB availability:</strong> <?php echo $wpdb->get_var("SELECT SUPPORT FROM INFORMATION_SCHEMA.ENGINES WHERE ENGINE = 'InnoDB';"); ?></p>
63 <p><strong>WordPress version:</strong> <?php echo $wp_version; ?></p>
64 <p><strong>Multisite:</strong> <?php echo ( function_exists('is_multisite') && is_multisite() ) ? 'Yes' : 'No'; ?></p>
65 <p><strong>Active plugins:</strong> <?php echo implode(', ', $plugin_names); ?></p>
66 <p><strong>Theme:</strong> <?php echo $my_theme->get('Name') . ' (' . $my_theme->get('Version') . ') by ' . $my_theme->get('Author'); ?></p>
67 </div>
68 <?php
69 }
70 }
71