PluginProbe
TablePress – Tables in WordPress made easy / 3.0
TablePress – Tables in WordPress made easy v3.0
3.3.4 3.3.3 3.3.2 3.3.1 trunk 1.12 1.14 1.9.2 2.0.4 2.1.7 2.1.8 2.2 2.2.1 2.2.2 2.2.3 2.2.4 2.2.5 2.3 2.3.1 2.3.2 2.4 2.4.1 2.4.2 2.4.3 2.4.4 All 44 releases
← All changes | tablepress.php +14 -27 2.23.0 View file →
@@ -3,17 +3,17 @@
3 3 * WordPress plugin "TablePress" main file, responsible for initiating the plugin.
4 4 *
5 5 * @package TablePress
6 6 * @author Tobias Bäthge
7 - * @version 2.2
7 + * @version 3.0
8 8 *
9 9 *
10 10 * Plugin Name: TablePress
11 11 * Plugin URI: https://tablepress.org/
12 12 * Description: Embed beautiful and interactive tables into your WordPress website’s posts and pages, without having to write code!
13 - * Version: 2.2
14 - * Requires at least: 6.0
15 - * Requires PHP: 7.2
13 + * Version: 3.0
14 + * Requires at least: 6.2
15 + * Requires PHP: 7.4
16 16 * Author: Tobias Bäthge
17 17 * Author URI: https://tablepress.org/
18 18 * Author email: wordpress@tobias.baethge.com
19 19 * License: GPL 2
@@ -19,9 +19,9 @@
19 19 * License: GPL 2
20 20 * Donate URI: https://tablepress.org/donate/
21 21 *
22 22 *
23 - * Copyright 2012-2023 Tobias Bäthge
23 + * Copyright 2012-2024 Tobias Bäthge
24 24 *
25 25 * TablePress is free software: you can redistribute it and/or modify
26 26 * it under the terms of the GNU General Public License, version 2, as published by
27 27 * the Free Software Foundation.
@@ -33,16 +33,20 @@
33 33 *
34 34 * You should have received a copy of the GNU General Public License
35 35 * along with WordPress. If not, see https://www.gnu.org/licenses/gpl-2.0.html.
36 36 *
37 - * Note: This file must not contain PHP code that does not run on PHP < 7.2!
37 + * Note: This file must not contain PHP code that does not run on PHP < 7.4!
38 38 */
39 39
40 40 // Prohibit direct script loading.
41 41 defined( 'ABSPATH' ) || die( 'No direct script access allowed!' );
42 42
43 +if ( ! defined( 'TABLEPRESS_IS_PLAYGROUND_PREVIEW' ) ) {
44 + define( 'TABLEPRESS_IS_PLAYGROUND_PREVIEW', false );
45 +}
46 +
43 47 if ( function_exists( 'tb_tp_fs' ) ) {
44 - tb_tp_fs()->set_basename( false, __FILE__ ); // @phpstan-ignore-line
48 + tb_tp_fs()->set_basename( false, __FILE__ ); // @phpstan-ignore argument.type (Wrong variable type in Freemius function docblock.)
45 49 } else {
46 50 /**
47 51 * Helper function for easier Freemius SDK access.
48 52 *
@@ -69,9 +73,8 @@
69 73 'slug' => 'tablepress',
70 74 'contact' => false,
71 75 'support' => false,
72 76 'account' => false,
73 - 'pricing' => false,
74 77 ),
75 78 'opt_in_moderation' => array(
76 79 'new' => true,
77 80 'updates' => false,
@@ -77,8 +80,9 @@
77 80 'updates' => false,
78 81 'localhost' => false,
79 82 ),
80 83 'is_live' => true,
84 + 'anonymous_mode' => TABLEPRESS_IS_PLAYGROUND_PREVIEW,
81 85 ) );
82 86 }
83 87
84 88 return $tb_tp_fs;
@@ -86,27 +90,10 @@
86 90
87 91 // Init Freemius.
88 92 tb_tp_fs();
89 93
90 - // Load the TablePress plugin icon for the Freemius opt-in/activation screen.
91 - tb_tp_fs()->add_filter(
92 - 'plugin_icon',
93 - static function () /* No return type declaration, due to required PHP compatibility of this file! */ {
94 - return __DIR__ . '/admin/img/tablepress.png';
95 - }
96 - );
97 -
98 - // Hide the tabs navigation on Freemius screens.
99 - tb_tp_fs()->add_filter( 'hide_account_tabs', '__return_true' );
100 -
101 - // Hide the Powered by Freemius tab from generated pages, like "Upgrade" or "Pricing".
102 - tb_tp_fs()->add_filter( 'hide_freemius_powered_by', '__return_true' );
103 -
104 - // Use different arrow icons in the admin menu.
105 - tb_tp_fs()->override_i18n( array(
106 - 'symbol_arrow-left' => '&larr;',
107 - 'symbol_arrow-right' => '&rarr;',
108 - ) );
94 + // Register Freemius plugin filter hooks.
95 + require_once __DIR__ . '/controllers/freemius-filters.php';
109 96
110 97 // Signal that the SDK was initiated.
111 98 do_action( 'tb_tp_fs_loaded' );
112 99