Page Visit Counter - Version 5.1

Version Description

  • 26-03-2019 =
  • minor bug fixed.
Download this release

Release Info

Developer dots
Plugin Icon 128x128 Page Visit Counter
Version 5.1
Comparing to
See all releases

Code changes from version 5.0 to 5.1

README.txt CHANGED
@@ -1,13 +1,13 @@
1
  === Page Visit Counter ===
2
  Plugin Name: Page Visit Counter
3
- Plugin URI: http://multidots.com/
4
- Author: Multidots
5
- Author URI: http://multidots.com/
6
  Contributors: dots, ketuchetan, chiragpatel, jitendrabanjara1991, thedotstore
7
- Stable tag: 5.0
8
  Tags: page counter,page visit, post counter, post visit, wordpress post view, wordpress page view, page visit graph, post visit graph,
9
- Requires at least: 2.1
10
- Tested up to: 5.0.3
11
  Donate link:
12
  Copyright: (c) 2014-2016 Multidots Solutions PVT LTD (info@multidots.com)
13
  License: GPLv3 or later
@@ -62,26 +62,23 @@ In this option you can see all pages listing within Page ID, Page Title and Tota
62
  We always welcome user suggestions. Let us know what you think about this plugin you liked or may have disliked. User's feedback is important for us to improve more our plugins.
63
 
64
  = You can check our other plugins: =
65
-
66
- 1. <a href ="http://bit.ly/2FrC4id">Emporos - Responsive WooCommerce Theme</a>
67
- 2. <a href ="http://bit.ly/2kq5Tqt">Onepage Studio - Multipurpose Landing Page with Page Builder</a>
68
- 3. <a href ="https://store.multidots.com/go/flat-rate">Advance Flat Rate Shipping Method For WooCommerce</a>
69
- 4. <a href ="https://store.multidots.com/go/dotstore-woocommerce-blocker">WooCommerce Blocker - Prevent Fake Orders And Blacklist Fraud Customers</a>
70
- 5. <a href ="https://store.multidots.com/go/dotstore-enhanced-ecommerce-tracking">WooCommerce Enhanced Ecommerce Analytics Integration With Conversion Tracking</a>
71
- 6. <a href ="https://store.multidots.com/go/dotstore-woo-category-banner">Woocommerce Category Banner Management</a>
72
- 7. <a href ="https://store.multidots.com/go/dotstore-woo-extra-fees">Woocommerce Conditional Extra Fees</a>
73
- 8. <a href ="https://store.multidots.com/go/dotstore-woo-product-sizechart">Woocommerce Advanced Product Size Charts</a>
74
- 9. <a href ="https://store.multidots.com/go/dotstore-admenumanager-wp">Advance Menu Manager for WordPress</a>
75
- 10. <a href ="https://store.multidots.com/go/dotstore-woo-savefor-later">Woocommerce Save For Later Cart Enhancement</a>
76
- 11. <a href ="https://store.multidots.com/go/brandagency">Brand Agency- One Page HTML Template For Agency,Startup And Business</a>
77
- 12. <a href ="https://store.multidots.com/go/Meraki">Meraki One Page HTML Resume Template</a>
78
- 13. <a href ="https://store.multidots.com/go/dotstore-aapify-theme">Appify - Multipurpose One Page Mobile App landing page HTML</a>
79
 
80
  == Installation ==
81
 
82
  = Minimum Requirements =
83
 
84
- * WordPress 2.1 or higher
85
 
86
  = Automatic installation =
87
 
@@ -119,6 +116,8 @@ It is compatible from 2.1 to 5.0.3 WordPress version.
119
  Automatic updates should work great for you. As always, though, we recommend backing up your site prior to making any updates just to be sure nothing goes wrong.
120
 
121
  == Changelog ==
 
 
122
 
123
  = 5.0 - 15-02-2019 =
124
  * compatible with WordPress 5.0.x
1
  === Page Visit Counter ===
2
  Plugin Name: Page Visit Counter
3
+ Plugin URI: https://www.thedotstore.com/
4
+ Author: Thedotstore
5
+ Author URI: https://www.thedotstore.com/
6
  Contributors: dots, ketuchetan, chiragpatel, jitendrabanjara1991, thedotstore
7
+ Stable tag: 5.1
8
  Tags: page counter,page visit, post counter, post visit, wordpress post view, wordpress page view, page visit graph, post visit graph,
9
+ Requires at least: 3.0
10
+ Tested up to: 5.1.1
11
  Donate link:
12
  Copyright: (c) 2014-2016 Multidots Solutions PVT LTD (info@multidots.com)
13
  License: GPLv3 or later
62
  We always welcome user suggestions. Let us know what you think about this plugin you liked or may have disliked. User's feedback is important for us to improve more our plugins.
63
 
64
  = You can check our other plugins: =
65
+ <ol>
66
+ <li> <a href ="http://bit.ly/2FrC4id">Emporos - Responsive WooCommerce Theme</a></li>
67
+ <li> <a href ="http://www.thedotstore.com/advanced-flat-rate-shipping-method-for-woocommerce">Advance Flat Rate Shipping Method For WooCommerce</a></li>
68
+ <li> <a href ="https://www.thedotstore.com/woocommerce-blocker-lite-prevent-fake-orders-blacklist-fraud-customers/">WooCommerce Blocker Prevent Fake Orders And Blacklist Fraud Customers</a></li>
69
+ <li> <a href ="http://www.thedotstore.com/woocommerce-enhanced-ecommerce-analytics-integration-with-conversion-tracking">WooCommerce Enhanced Ecommerce Analytics Integration With Conversion Tracking</a></li>
70
+ <li> <a href ="https://www.thedotstore.com/woocommerce-category-banner-management/">Woocommerce Category Banner Management</a></li>
71
+ <li> <a href ="https://www.thedotstore.com/woocommerce-conditional-product-fees-checkout/">Woocommerce Conditional Extra Fees</a></li>
72
+ <li> <a href ="https://www.thedotstore.com/woocommerce-advanced-product-size-charts/">Woocommerce Advanced Product Size Charts</a></li>
73
+ <li> <a href ="http://www.thedotstore.com/advance-menu-manager-wordpress/">Advance Menu Manager for WordPress</a></li>
74
+ <li> <a href ="http://www.thedotstore.com/woocommerce-save-for-later-cart-enhancement">Woocommerce Save For Later Cart Enhancement</a></li>
75
+ </ol>
 
 
 
76
 
77
  == Installation ==
78
 
79
  = Minimum Requirements =
80
 
81
+ * WordPress 3.0 or higher
82
 
83
  = Automatic installation =
84
 
116
  Automatic updates should work great for you. As always, though, we recommend backing up your site prior to making any updates just to be sure nothing goes wrong.
117
 
118
  == Changelog ==
119
+ = 5.1 - 26-03-2019 =
120
+ * minor bug fixed.
121
 
122
  = 5.0 - 15-02-2019 =
123
  * compatible with WordPress 5.0.x
admin/class-page-visit-counter-admin.php CHANGED
@@ -1500,6 +1500,18 @@ class page_visit_counter_Admin {
1500
  //add_option( 'contact_db_version', $contact_db_version );
1501
  }
1502
  }
 
 
 
 
 
 
 
 
 
 
 
 
1503
 
1504
  function get_page_visit_record_report() {
1505
  global $wpdb;
1500
  //add_option( 'contact_db_version', $contact_db_version );
1501
  }
1502
  }
1503
+ function check_page_visit_plugin_row_meta( $links, $file ) {
1504
+
1505
+ if ( strpos( $file, 'page_visit_counter.php' ) !== false ) {
1506
+ $new_links = array(
1507
+ 'support' => '<a href="https://www.thedotstore.com/support/" target="_blank">Support</a>',
1508
+ );
1509
+
1510
+ $links = array_merge( $links, $new_links );
1511
+ }
1512
+
1513
+ return $links;
1514
+ }
1515
 
1516
  function get_page_visit_record_report() {
1517
  global $wpdb;
includes/class-page-visit-counter.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  // If this file is called directly, abort.
3
- if ( !defined( 'ABSPATH' ) ) {
4
- exit;
5
  }
6
  /**
7
  * The file that defines the core plugin class
@@ -38,7 +38,7 @@ class page_visit_counter {
38
  *
39
  * @since 1.0.0
40
  * @access protected
41
- * @var Woo_Extra_Flat_Rate_Loader $loader Maintains and registers all hooks for the plugin.
42
  */
43
  protected $loader;
44
 
@@ -47,7 +47,7 @@ class page_visit_counter {
47
  *
48
  * @since 1.0.0
49
  * @access protected
50
- * @var string $plugin_name The string used to uniquely identify this plugin.
51
  */
52
  protected $plugin_name;
53
 
@@ -56,7 +56,7 @@ class page_visit_counter {
56
  *
57
  * @since 1.0.0
58
  * @access protected
59
- * @var string $version The current version of the plugin.
60
  */
61
  protected $version;
62
 
@@ -73,7 +73,7 @@ class page_visit_counter {
73
  public function __construct() {
74
 
75
  $this->plugin_name = 'page-visit-counter';
76
- $this->version = '1.0.0';
77
  $this->load_dependencies();
78
  $this->set_locale();
79
  $this->define_admin_hooks();
@@ -82,7 +82,7 @@ class page_visit_counter {
82
  }
83
 
84
  private function load_dependencies() {
85
-
86
  /**
87
  * The class responsible for orchestrating the actions and filters of the
88
  * core plugin.
@@ -104,6 +104,7 @@ class page_visit_counter {
104
  $this->loader = new page_visit_counter_Loader();
105
 
106
  }
 
107
  /**
108
  * Define the locale for this plugin for internationalization.
109
  *
@@ -121,7 +122,18 @@ class page_visit_counter {
121
  $this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );
122
 
123
  }
124
-
 
 
 
 
 
 
 
 
 
 
 
125
  /**
126
  * Register all of the hooks related to the admin area functionality
127
  * of the plugin.
@@ -131,67 +143,76 @@ class page_visit_counter {
131
  */
132
  private function define_admin_hooks() {
133
  global $wp, $wpdb;
134
-
135
  $plugin_admin = new page_visit_counter_Admin( $this->get_plugin_name(), $this->get_version() );
136
 
137
- $this->loader->add_action( 'admin_enqueue_scripts',$plugin_admin, 'enqueue_styles' );
138
- $this->loader->add_action( 'admin_enqueue_scripts',$plugin_admin, 'enqueue_scripts' );
139
-
140
- $this->loader->add_action( 'admin_menu',$plugin_admin, 'page_visit_counter_menu' );
141
- $this->loader->add_action( 'wp_dashboard_setup',$plugin_admin, 'my_custom_dashboard_widgets' );
142
-
143
- $this->loader->add_action( 'wp_ajax_get_page_visit_record_report', $plugin_admin, 'get_page_visit_record_report' );
144
  $this->loader->add_action( 'wp_ajax_nopriv_get_page_visit_record_report', $plugin_admin, 'get_page_visit_record_report' );
145
-
146
- $this->loader->add_action( 'wp_ajax_select_input_page_value', $plugin_admin, 'select_input_page_value' );
147
  $this->loader->add_action( 'wp_ajax_nopriv_select_input_page_value', $plugin_admin, 'select_input_page_value' );
148
-
149
  $this->loader->add_action( 'wp_ajax_add_plugin_user_pvcp', $plugin_admin, 'wp_add_plugin_userfn' );
150
 
151
  $this->loader->add_action( 'admin_init', $plugin_admin, 'add_custom_meta_box_page_visit' );
152
-
153
  $this->loader->add_action( 'save_post', $plugin_admin, 'save_custom_meta_box_page_visit' );
154
-
155
- $this->loader->add_action('admin_init', $plugin_admin, 'welcome_page_visit_counter_screen_do_activation_redirect');
156
- //admin menu intilization hooks
157
- $this->loader->add_action('admin_menu', $plugin_admin, 'welcome_pages_screen_page_visit_counter');
158
 
159
- $this->loader->add_action('page_visit_counter_about', $plugin_admin, 'page_visit_counter_about');
 
 
160
 
161
- $this->loader->add_action('admin_print_footer_scripts', $plugin_admin, 'custom_admin_pointers_footer');
 
 
 
 
 
162
 
163
- $this->loader->add_action( 'admin_post_submit_form_pvc',$plugin_admin, 'add_page_count_option');
164
- $this->loader->add_action( 'admin_post_nopriv_submit_form_pvc',$plugin_admin, 'add_page_count_option');
165
-
166
  $this->loader->add_action( 'plugins_loaded', $plugin_admin, 'check_page_visit_history_table_exisit' );
167
-
168
- add_action( 'wp_loaded', function ()
169
- {
170
- $fetchSelecetedPostTypes = json_decode(get_option('wfap_post_type'));
171
- if (isset($fetchSelecetedPostTypes) && !empty($fetchSelecetedPostTypes)) {
172
- foreach ($fetchSelecetedPostTypes as $postsingle) {
173
- add_filter("manage_edit-".$postsingle."_columns", "add_new_selected_post_columns");
174
- add_action("manage_".$postsingle."_posts_custom_column" , "custom_columns_add_page_visit_count",10,2);
175
- }
176
- } else {
177
- // Get all the registered post type
178
- global $wp_post_types;
179
- $post_types = get_post_types();
180
-
181
- foreach ($post_types as $cpost) {
182
- if($cpost != "attachment" && $cpost != "revision" && $cpost != "nav_menu_item" && $cpost != "product_variation" && $cpost != "shop_order" && $cpost != "shop_order_refund" && $cpost != "shop_coupon" && $cpost != "shop_webhook" && $cpost != "scheduled-action" && $cpost != "shop_subscription"&& $cpost != "wpcf7_contact_form"&& $cpost != "mc4wp-form") {
183
- add_filter("manage_edit-".$cpost."_columns", "add_new_selected_post_columns");
184
- add_action("manage_".$cpost."_posts_custom_column" , "custom_columns_add_page_visit_count",2,2);
185
- }
186
- }
187
- }
188
- });
189
-
190
- $this->loader->add_action( 'wp_ajax_get_visit_page_result_after_update_admin', $plugin_admin, 'get_visit_page_result_after_update_admin' );
191
  $this->loader->add_action( 'wp_ajax_nopriv_get_visit_page_result_after_update_admin', $plugin_admin, 'get_visit_page_result_after_update_admin' );
192
-
 
 
 
 
 
 
 
 
 
 
193
  }
194
-
195
  /**
196
  * Register all of the hooks related to the public-facing functionality
197
  * of the plugin.
@@ -201,27 +222,27 @@ class page_visit_counter {
201
  */
202
  private function define_public_hooks() {
203
  global $wp, $wpdb;
204
-
205
  $plugin_public = new page_visit_counter_Public( $this->get_plugin_name(), $this->get_version() );
206
 
207
  $this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_styles' );
208
  $this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_scripts' );
209
-
210
  $this->loader->add_action( 'wp_ajax_display_page_visit_counter_ajax', $plugin_public, 'display_page_visit_counter_ajax' );
211
  $this->loader->add_action( 'wp_ajax_nopriv_display_page_visit_counter_ajax', $plugin_public, 'display_page_visit_counter_ajax' );
212
-
213
  $this->loader->add_action( 'wp', $plugin_public, 'insert_page_visit_counter' );
214
-
215
- $this->loader->add_action( 'the_content', $plugin_public, 'insert_page_visit_counter_total_block',99 );
216
-
217
- if (in_array( 'woocommerce/woocommerce.php',apply_filters('active_plugins',get_option('active_plugins')))) {
218
- $this->loader->add_filter( 'woocommerce_paypal_args', $plugin_public, 'paypal_bn_code_filter',99,1 );
219
- $this->loader->add_action( 'woocommerce_after_shop_loop', $plugin_public, 'insert_page_visit_counter_total_block_shop_page',99 );
220
- $this->loader->add_action( 'woocommerce_single_product_summary', $plugin_public, 'insert_page_visit_counter_total_block_shop_page',99 );
221
  }
222
-
223
  }
224
-
225
  /**
226
  * Run the loader to execute all of the hooks with WordPress.
227
  *
@@ -230,18 +251,7 @@ class page_visit_counter {
230
  public function run() {
231
  $this->loader->run();
232
  }
233
-
234
- /**
235
- * The name of the plugin used to uniquely identify it within the context of
236
- * WordPress and to define internationalization functionality.
237
- *
238
- * @since 1.0.0
239
- * @return string The name of the plugin.
240
- */
241
- public function get_plugin_name() {
242
- return $this->plugin_name;
243
- }
244
-
245
  /**
246
  * The reference to the class that orchestrates the hooks with the plugin.
247
  *
@@ -251,14 +261,4 @@ class page_visit_counter {
251
  public function get_loader() {
252
  return $this->loader;
253
  }
254
-
255
- /**
256
- * Retrieve the version number of the plugin.
257
- *
258
- * @since 1.0.0
259
- * @return string The version number of the plugin.
260
- */
261
- public function get_version() {
262
- return $this->version;
263
- }
264
  }
1
  <?php
2
  // If this file is called directly, abort.
3
+ if ( ! defined( 'ABSPATH' ) ) {
4
+ exit;
5
  }
6
  /**
7
  * The file that defines the core plugin class
38
  *
39
  * @since 1.0.0
40
  * @access protected
41
+ * @var Woo_Extra_Flat_Rate_Loader $loader Maintains and registers all hooks for the plugin.
42
  */
43
  protected $loader;
44
 
47
  *
48
  * @since 1.0.0
49
  * @access protected
50
+ * @var string $plugin_name The string used to uniquely identify this plugin.
51
  */
52
  protected $plugin_name;
53
 
56
  *
57
  * @since 1.0.0
58
  * @access protected
59
+ * @var string $version The current version of the plugin.
60
  */
61
  protected $version;
62
 
73
  public function __construct() {
74
 
75
  $this->plugin_name = 'page-visit-counter';
76
+ $this->version = '1.0.0';
77
  $this->load_dependencies();
78
  $this->set_locale();
79
  $this->define_admin_hooks();
82
  }
83
 
84
  private function load_dependencies() {
85
+
86
  /**
87
  * The class responsible for orchestrating the actions and filters of the
88
  * core plugin.
104
  $this->loader = new page_visit_counter_Loader();
105
 
106
  }
107
+
108
  /**
109
  * Define the locale for this plugin for internationalization.
110
  *
122
  $this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );
123
 
124
  }
125
+
126
+ /**
127
+ * The name of the plugin used to uniquely identify it within the context of
128
+ * WordPress and to define internationalization functionality.
129
+ *
130
+ * @since 1.0.0
131
+ * @return string The name of the plugin.
132
+ */
133
+ public function get_plugin_name() {
134
+ return $this->plugin_name;
135
+ }
136
+
137
  /**
138
  * Register all of the hooks related to the admin area functionality
139
  * of the plugin.
143
  */
144
  private function define_admin_hooks() {
145
  global $wp, $wpdb;
146
+
147
  $plugin_admin = new page_visit_counter_Admin( $this->get_plugin_name(), $this->get_version() );
148
 
149
+ $this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_styles' );
150
+ $this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts' );
151
+
152
+ $this->loader->add_action( 'admin_menu', $plugin_admin, 'page_visit_counter_menu' );
153
+ $this->loader->add_action( 'wp_dashboard_setup', $plugin_admin, 'my_custom_dashboard_widgets' );
154
+
155
+ $this->loader->add_action( 'wp_ajax_get_page_visit_record_report', $plugin_admin, 'get_page_visit_record_report' );
156
  $this->loader->add_action( 'wp_ajax_nopriv_get_page_visit_record_report', $plugin_admin, 'get_page_visit_record_report' );
157
+
158
+ $this->loader->add_action( 'wp_ajax_select_input_page_value', $plugin_admin, 'select_input_page_value' );
159
  $this->loader->add_action( 'wp_ajax_nopriv_select_input_page_value', $plugin_admin, 'select_input_page_value' );
160
+
161
  $this->loader->add_action( 'wp_ajax_add_plugin_user_pvcp', $plugin_admin, 'wp_add_plugin_userfn' );
162
 
163
  $this->loader->add_action( 'admin_init', $plugin_admin, 'add_custom_meta_box_page_visit' );
164
+
165
  $this->loader->add_action( 'save_post', $plugin_admin, 'save_custom_meta_box_page_visit' );
 
 
 
 
166
 
167
+ $this->loader->add_action( 'admin_init', $plugin_admin, 'welcome_page_visit_counter_screen_do_activation_redirect' );
168
+ //admin menu intilization hooks
169
+ $this->loader->add_action( 'admin_menu', $plugin_admin, 'welcome_pages_screen_page_visit_counter' );
170
 
171
+ $this->loader->add_action( 'page_visit_counter_about', $plugin_admin, 'page_visit_counter_about' );
172
+
173
+ $this->loader->add_action( 'admin_print_footer_scripts', $plugin_admin, 'custom_admin_pointers_footer' );
174
+
175
+ $this->loader->add_action( 'admin_post_submit_form_pvc', $plugin_admin, 'add_page_count_option' );
176
+ $this->loader->add_action( 'admin_post_nopriv_submit_form_pvc', $plugin_admin, 'add_page_count_option' );
177
 
 
 
 
178
  $this->loader->add_action( 'plugins_loaded', $plugin_admin, 'check_page_visit_history_table_exisit' );
179
+ $this->loader->add_action( 'plugin_row_meta', $plugin_admin, 'check_page_visit_plugin_row_meta',10,2 );
180
+
181
+ add_action( 'wp_loaded', function () {
182
+ $fetchSelecetedPostTypes = json_decode( get_option( 'wfap_post_type' ) );
183
+ if ( isset( $fetchSelecetedPostTypes ) && ! empty( $fetchSelecetedPostTypes ) ) {
184
+ foreach ( $fetchSelecetedPostTypes as $postsingle ) {
185
+ add_filter( "manage_edit-" . $postsingle . "_columns", "add_new_selected_post_columns" );
186
+ add_action( "manage_" . $postsingle . "_posts_custom_column", "custom_columns_add_page_visit_count", 10, 2 );
187
+ }
188
+ } else {
189
+ // Get all the registered post type
190
+ global $wp_post_types;
191
+ $post_types = get_post_types();
192
+
193
+ foreach ( $post_types as $cpost ) {
194
+ if ( $cpost != "attachment" && $cpost != "revision" && $cpost != "nav_menu_item" && $cpost != "product_variation" && $cpost != "shop_order" && $cpost != "shop_order_refund" && $cpost != "shop_coupon" && $cpost != "shop_webhook" && $cpost != "scheduled-action" && $cpost != "shop_subscription" && $cpost != "wpcf7_contact_form" && $cpost != "mc4wp-form" ) {
195
+ add_filter( "manage_edit-" . $cpost . "_columns", "add_new_selected_post_columns" );
196
+ add_action( "manage_" . $cpost . "_posts_custom_column", "custom_columns_add_page_visit_count", 2, 2 );
197
+ }
198
+ }
199
+ }
200
+ } );
201
+
202
+ $this->loader->add_action( 'wp_ajax_get_visit_page_result_after_update_admin', $plugin_admin, 'get_visit_page_result_after_update_admin' );
203
  $this->loader->add_action( 'wp_ajax_nopriv_get_visit_page_result_after_update_admin', $plugin_admin, 'get_visit_page_result_after_update_admin' );
204
+
205
+ }
206
+
207
+ /**
208
+ * Retrieve the version number of the plugin.
209
+ *
210
+ * @since 1.0.0
211
+ * @return string The version number of the plugin.
212
+ */
213
+ public function get_version() {
214
+ return $this->version;
215
  }
 
216
  /**
217
  * Register all of the hooks related to the public-facing functionality
218
  * of the plugin.
222
  */
223
  private function define_public_hooks() {
224
  global $wp, $wpdb;
225
+
226
  $plugin_public = new page_visit_counter_Public( $this->get_plugin_name(), $this->get_version() );
227
 
228
  $this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_styles' );
229
  $this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_scripts' );
230
+
231
  $this->loader->add_action( 'wp_ajax_display_page_visit_counter_ajax', $plugin_public, 'display_page_visit_counter_ajax' );
232
  $this->loader->add_action( 'wp_ajax_nopriv_display_page_visit_counter_ajax', $plugin_public, 'display_page_visit_counter_ajax' );
233
+
234
  $this->loader->add_action( 'wp', $plugin_public, 'insert_page_visit_counter' );
235
+
236
+ $this->loader->add_action( 'the_content', $plugin_public, 'insert_page_visit_counter_total_block', 99 );
237
+
238
+ if ( in_array( 'woocommerce/woocommerce.php', apply_filters( 'active_plugins', get_option( 'active_plugins' ) ) ) ) {
239
+ $this->loader->add_filter( 'woocommerce_paypal_args', $plugin_public, 'paypal_bn_code_filter', 99, 1 );
240
+ $this->loader->add_action( 'woocommerce_after_shop_loop', $plugin_public, 'insert_page_visit_counter_total_block_shop_page', 99 );
241
+ $this->loader->add_action( 'woocommerce_single_product_summary', $plugin_public, 'insert_page_visit_counter_total_block_shop_page', 99 );
242
  }
243
+
244
  }
245
+
246
  /**
247
  * Run the loader to execute all of the hooks with WordPress.
248
  *
251
  public function run() {
252
  $this->loader->run();
253
  }
254
+
 
 
 
 
 
 
 
 
 
 
 
255
  /**
256
  * The reference to the class that orchestrates the hooks with the plugin.
257
  *
261
  public function get_loader() {
262
  return $this->loader;
263
  }
 
 
 
 
 
 
 
 
 
 
264
  }
page_visit_counter.php CHANGED
@@ -1,15 +1,15 @@
1
  <?php
2
 
3
  /*
4
- * @link http://www.multidots.com/
5
  * @since 1.1
6
  * @package page-visit-counter
7
  * Plugin Name: Page Visit Counter
8
- * Plugin URI: http://www.multidots.com/
9
  * Description: This plugin will count the total visits of your sites pages.
10
- * Author: Multidots
11
- * Version: 5.0
12
- * Author URI: http://www.multidots.com/
13
  */
14
  // If this file is called directly, abort.
15
  if (!defined('WPINC')) {
1
  <?php
2
 
3
  /*
4
+ * @link https://www.thedotstore.com/
5
  * @since 1.1
6
  * @package page-visit-counter
7
  * Plugin Name: Page Visit Counter
8
+ * Plugin URI: https://www.thedotstore.com/
9
  * Description: This plugin will count the total visits of your sites pages.
10
+ * Author: Thedotstore
11
+ * Version: 5.1
12
+ * Author URI: https://www.thedotstore.com/
13
  */
14
  // If this file is called directly, abort.
15
  if (!defined('WPINC')) {