PluginProbe
Maps Plugin using Google Maps for WordPress – WP Google Map / trunk
Maps Plugin using Google Maps for WordPress – WP Google Map vtrunk
1.9.7 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 1.3.6 1.3.7 1.3.8 1.3.9 1.4.0 1.4.1 1.4.2 1.4.3 1.4.4 1.4.5 1.4.6 1.4.7 1.4.8 1.4.9 1.5.0 1.5.1 1.5.2 1.5.3 All 96 releases
gmap-embed / includes / traits / ActivationHooks.php

ActivationHooks.php in Maps Plugin using Google Maps for WordPress – WP Google Map trunk, at includes/traits/ActivationHooks.php

40 lines 931 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace WGMSRM\Traits;
4
5 if (!defined('ABSPATH')) {
6 exit;
7 }
8
9 /**
10 * Trait ActivationHooks: Do something on plugin activation
11 */
12 trait ActivationHooks
13 {
14
15 /**
16 * Do after activation
17 *
18 * @param $plugin
19 * @param $network_activation
20 */
21 public function wpgmap_do_after_activation($plugin, $network_activation)
22 {
23 // In case of existing installation
24 if (get_option('gmap_embed_activation_time', false) == false) {
25 update_option('gmap_embed_activation_time', time());
26 }
27
28 // In case of existing installation
29 if (get_option('_wgm_enable_direction_form_auto_complete', false) == false) {
30 update_option('_wgm_enable_direction_form_auto_complete', 'Y');
31 }
32
33 // Validate $plugin value before comparison
34 if (is_string($plugin) && $plugin === 'gmap-embed/srm_gmap_embed.php') {
35 //wp_redirect( admin_url( 'admin.php?page=wgm_setup_wizard' ) );
36 //exit;
37 }
38 }
39 }
40