PluginProbe
WP Coder – Insert & Manage Code Snippets / 3.4
WP Coder – Insert & Manage Code Snippets v3.4
4.5.1 1.1 2.3.1 2.3.2 2.4.1 2.5.1 2.5.2 2.5.3 2.5.4 2.5.5 2.5.6 3.0 3.0.1 3.0.2 3.0.3 3.0.4 3.0.5 3.1 3.1.1 3.2 3.2.1 3.3 3.4 3.5 3.5.1 All 39 releases
← All changes | classes/Admin/AdminInitializer.php +10 -1 3.2.13.4 View file →
@@ -61,10 +61,11 @@
61 61
62 62 add_submenu_page( $slug, $title, $menu_title, $capability, $slug, [ __CLASS__, 'plugin_page' ] );
63 63
64 64 add_submenu_page( $slug, $title, 'Add new', $capability, $slug . '-settings', [ __CLASS__, 'settings' ] );
65 + add_submenu_page( $slug, $title, 'Snippets', $capability, $slug . '-snippets', [ __CLASS__, 'snippets' ] );
65 66 add_submenu_page( $slug, $title, 'Global PHP', $capability, $slug . '-global', [ __CLASS__, 'global_php' ] );
66 - add_submenu_page( $slug, $title, 'Tools', $capability, $slug . '-tools', [ __CLASS__, 'tools' ] );
67 + add_submenu_page( $slug, $title, 'Import / Export', $capability, $slug . '-tools', [ __CLASS__, 'tools' ] );
67 68 add_submenu_page( $slug, $title, 'Support', $capability, $slug . '-support', [ __CLASS__, 'support' ] );
68 69 add_submenu_page( $slug, $title, 'Upgrade to Pro', $capability, $url_update );
69 70 }
70 71
@@ -81,8 +82,16 @@
81 82 }
82 83
83 84 public static function settings(): void {
84 85 $page_path = DashboardHelper::get_folder_path( 'pages' ) . '/2.settings.php';
86 +
87 + if ( file_exists( $page_path ) ) {
88 + require_once $page_path;
89 + }
90 + }
91 +
92 + public static function snippets() {
93 + $page_path = DashboardHelper::get_folder_path( 'pages' ) . '/3.snippets.php';
85 94
86 95 if ( file_exists( $page_path ) ) {
87 96 require_once $page_path;
88 97 }