PluginProbe ʕ •ᴥ•ʔ
WP Popular Posts / 5.0.1
WP Popular Posts v5.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 / wordpress-popular-posts.php
wordpress-popular-posts Last commit date
assets 6 years ago i18n 6 years ago src 6 years ago vendor 6 years ago index.php 6 years ago readme.txt 6 years ago uninstall.php 6 years ago wordpress-popular-posts.php 6 years ago
wordpress-popular-posts.php
61 lines
1 <?php
2
3 /**
4 * The plugin bootstrap file
5 *
6 * This file is read by WordPress to generate the plugin information in the plugin
7 * admin area. This file also includes all of the dependencies used by the plugin,
8 * registers the activation and deactivation functions, and defines a function
9 * that starts the plugin.
10 *
11 * @link https://cabrerahector.com/
12 * @since 4.0.0
13 * @package WordPressPopularPosts
14 *
15 * @wordpress-plugin
16 * Plugin Name: WordPress Popular Posts
17 * Plugin URI: https://wordpress.org/plugins/wordpress-popular-posts/
18 * Description: A highly customizable widget that displays the most popular posts on your blog.
19 * Version: 5.0.1
20 * Author: Hector Cabrera
21 * Author URI: https://cabrerahector.com/
22 * License: GPL-2.0+
23 * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
24 * Text Domain: wordpress-popular-posts
25 * Domain Path: /languages
26 */
27
28 if ( ! defined( 'WPINC' ) ) {
29 die();
30 }
31
32 define('WPP_VERSION', '5.0.1');
33 define('WPP_MIN_PHP_VERSION', '5.4');
34 define('WPP_MIN_WP_VERSION', '4.9');
35
36 /** Requirements check */
37 global $wp_version;
38
39 // We're good, continue!
40 if ( version_compare(PHP_VERSION, WPP_MIN_PHP_VERSION, '>=') && version_compare($wp_version, WPP_MIN_WP_VERSION, '>=') ) {
41 $wpp_main_plugin_file = __FILE__;
42 // Load plugin bootstrap
43 require __DIR__ . '/src/Bootstrap.php';
44 } // Nope.
45 else {
46 if ( isset($_GET['activate']) )
47 unset($_GET['activate']);
48
49 function wpp_render_min_requirements_notice() {
50 global $wp_version;
51 echo '<div class="notice notice-error"><p>' . sprintf(
52 __('WordPress Popular Posts requires at least PHP %1$s and WordPress %2$s to function correctly. Your site uses PHP %3$s and WordPress %4$s.', 'wordpress-popular-posts'),
53 WPP_MIN_PHP_VERSION,
54 WPP_MIN_WP_VERSION,
55 PHP_VERSION,
56 $wp_version
57 ) . '</p></div>';
58 }
59 add_action('admin_notices', 'wpp_render_min_requirements_notice');
60 }
61