PluginProbe
Adminify – White Label, Admin Menu Editor, Login Customizer / 4.0.5.4
Adminify – White Label, Admin Menu Editor, Login Customizer v4.0.5.4
4.3.2 4.3.1 4.3.0 4.2.26 4.2.25 4.2.24 4.2.23 4.2.22 4.2.21 4.2.20 4.2.19 4.2.18 4.2.17 4.2.16 4.2.15 4.2.14 4.2.13 4.2.12 4.2.11 4.2.10 4.2.9 4.2.8 4.2.7 4.2.6 4.2.5 All 165 releases
← All changes | Inc/Classes/Notifications/What_We_Collect.php +19 -32 4.3.24.0.5.4 View file →
@@ -1,15 +1,11 @@
1 1 <?php
2 2
3 -namespace PXLBSAdminify\Inc\Classes\Notifications;
3 +namespace WPAdminify\Inc\Classes\Notifications;
4 4
5 -if ( ! defined( 'ABSPATH' ) ) {
6 - exit; // Exit if accessed directly.
7 -}
5 +use WPAdminify\Inc\Classes\Notifications\Base\User_Data;
6 +use WPAdminify\Inc\Classes\Notifications\Model\Notice;
8 7
9 -use PXLBSAdminify\Inc\Classes\Notifications\Base\User_Data;
10 -use PXLBSAdminify\Inc\Classes\Notifications\Model\Notice;
11 -
12 8 if (! class_exists('What_We_Collect')) {
13 9 /**
14 10 * Class for what we collect
15 11 *
@@ -30,9 +26,9 @@
30 26 */
31 27 public function __construct()
32 28 {
33 29 parent::__construct();
34 - add_action('wp_ajax_pxlbsadminify_allow_collect', array($this, 'pxlbsadminify_allow_collect'));
30 + add_action('wp_ajax_jltwp_adminify_allow_collect', array($this, 'jltwp_adminify_allow_collect'));
35 31 }
36 32
37 33 /**
38 34 * Allow collect data
@@ -38,27 +34,20 @@
38 34 * Allow collect data
39 35 *
40 36 * @author Jewel Theme <support@jeweltheme.com>
41 37 */
42 - public function pxlbsadminify_allow_collect()
38 + public function jltwp_adminify_allow_collect()
43 39 {
44 - check_ajax_referer('pxlbsadminify_allow_collect_nonce');
40 + check_ajax_referer('jltwp_adminify_allow_collect_nonce');
45 41
46 - // Opting in to send diagnostic data to a third party is a
47 - // site-wide consent and must only be performed by a site
48 - // administrator.
49 - if ( ! current_user_can( 'manage_options' ) ) {
50 - wp_send_json_error( array( 'mess' => __( 'You are not allowed to perform this action.', 'adminify' ) ), 403 );
51 - }
52 -
53 - $this->pxlbsadminify_collect_ajax_data();
42 + $this->jltwp_adminify_collect_ajax_data();
54 43 }
55 44
56 45
57 - public function pxlbsadminify_collect_ajax_data()
46 + public function jltwp_adminify_collect_ajax_data()
58 47 {
59 48
60 - if (!empty(get_option('pxlbsadminify_what_we_collect'))) {
49 + if (!empty(get_option('jltwp_adminify_what_we_collect'))) {
61 50 return;
62 51 }
63 52
64 53 $email = get_bloginfo('admin_email');
@@ -71,9 +60,9 @@
71 60 'first_name' => $full_name,
72 61 'email' => $email,
73 62 ));
74 63
75 - update_option('pxlbsadminify_what_we_collect', 'yes');
64 + update_option('jltwp_adminify_what_we_collect', 'yes');
76 65 return $response;
77 66 }
78 67
79 68
@@ -86,9 +75,9 @@
86 75 public function set_title()
87 76 {
88 77 printf(
89 78 '<h4>Wanna get some discount for %1$s? No Worries!! We got you!! give us your email we will send you the discount code?</h4>',
90 - esc_html__('Adminify', 'adminify')
79 + esc_html__('WP Adminify', 'adminify')
91 80 );
92 81 }
93 82
94 83 /**
@@ -110,21 +99,19 @@
110 99 { ?>
111 100 <div class="wp-adminify-notice-review-box wp-adminify-wwc">
112 101 <p>
113 102 <?php
114 - echo wp_kses_post( sprintf(
115 - /* translators: %1$s: Plugin name */
103 + echo sprintf(
116 104 __('Want to help make <strong>%1$s</strong> even more awesome? Allow %1$s to collect non-sensitive diagnostic data and usage information.', 'adminify'),
117 - esc_html( __('Adminify', 'adminify') )
118 - ) );
105 + __('WP Adminify', 'adminify')
106 + );
119 107 ?>
120 108 (<?php $this->what_we_collect_link(); ?>)</p>
121 109 <div class="wp-adminify-wwc-content" style="display:none">
122 - <?php echo wp_kses_post( sprintf(
123 - /* translators: %1$s: Privacy Policy page URL */
110 + <?php echo sprintf(
124 111 __('Server environment details (php, mysql, server, WordPress versions), Number of users in your site, Site language, Number of active and inactive plugins, Local or Production Site, IP Address, Site name and url, Your name and email address etc. No sensitive data is tracked. Learn more about our <a href="%1$s" target="_blank">Privacy Policy</a>, how we handle and collects your data.', 'adminify'),
125 112 esc_url('https://wpadminify.com/privacy-policy')
126 - ) ); ?>
113 + ); ?>
127 114 </div>
128 115 </div>
129 116
130 117 <?php
@@ -202,16 +189,16 @@
202 189 url: '<?php echo esc_url(admin_url('admin-ajax.php')); ?>',
203 190 method: 'POST',
204 191 crossDomain: true,
205 192 data: {
206 - action: 'pxlbsadminify_allow_collect',
207 - _wpnonce: '<?php echo esc_js(wp_create_nonce('pxlbsadminify_allow_collect_nonce')); ?>',
193 + action: 'jltwp_adminify_allow_collect',
194 + _wpnonce: '<?php echo esc_js(wp_create_nonce('jltwp_adminify_allow_collect_nonce')); ?>',
208 195 }
209 196 })
210 197 .done(function(response) {
211 198 noticeWrapper.children(':not(.notice-dismiss)').hide().end().append('<p class="wp-adminify--notice-message"><strong>' + response.data + '</strong></p>');
212 199 let subsTimeout = setTimeout(function() {
213 - pxlbsadminify_notice_action(null, noticeWrapper.children(), 'disable');
200 + jltwp_adminify_notice_action(null, noticeWrapper.children(), 'disable');
214 201 clearTimeout(subsTimeout);
215 202 }, 1500);
216 203 })
217 204 .always(function() {