PluginProbe
CBX Map for Google Map & OpenStreetMap / trunk
CBX Map for Google Map & OpenStreetMap vtrunk
trunk 1.1.10 1.1.11 1.1.12 1.1.5 1.1.6 1.1.7 1.1.8 1.1.9 2.0.0 2.0.1 2.0.2 2.0.3 2.0.4 2.0.5
cbxgooglemap / uninstall.php

uninstall.php in CBX Map for Google Map & OpenStreetMap trunk, at uninstall.php

51 lines 1.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 // If this file is called directly, abort.
3 if ( ! defined( 'WPINC' ) ) {
4 die;
5 }
6
7 /**
8 * Fired when the plugin is uninstalled.
9 *
10 * When populating this file, consider the following flow
11 * of control:
12 *
13 * - This method should be static
14 * - Check if the $_REQUEST content actually is the plugin name
15 * - Run an admin referrer check to make sure it goes through authentication
16 * - Verify the output of $_GET makes sense
17 * - Repeat with other user roles. Best directly by using the links/query string parameters.
18 * - Repeat things for multisite. Once for a single site in the network, once sitewide.
19 *
20 * This file may be updated more in future version of the Boilerplate; however, this is the
21 * general skeleton and outline for how the file should work.
22 *
23 * For more information, see the following discussion:
24 * https://github.com/tommcfarlin/WordPress-Plugin-Boilerplate/pull/123#issuecomment-28541913
25 *
26 * @link https://codeboxr.com
27 * @since 1.0.0
28 *
29 * @package Cbxgooglemap
30 */
31
32 // If uninstall not called from WordPress, then exit.
33 if ( ! defined( 'WP_UNINSTALL_PLUGIN' ) ) {
34 exit;
35 }
36
37 require_once plugin_dir_path( __FILE__ ) . "vendor/autoload.php";
38
39 /**
40 * The code that runs during plugin uninstall.
41 */
42 function cbxgooglemap_uninstall() {
43 require_once plugin_dir_path( __FILE__ ) . 'includes/CBXGoogleMapUninstall.php';
44
45 CBXGoogleMapUninstall::uninstall();
46 }//end function cbxgooglemap_uninstall
47
48 if ( ! defined( 'CBXGOOGLEMAP_PLUGIN_NAME' ) ) {
49 cbxgooglemap_uninstall();
50 }
51