PluginProbe ʕ •ᴥ•ʔ
Reviews Feed – Add Testimonials and Customer Reviews From Google Reviews, Yelp, TripAdvisor, and More / 2.9.0
Reviews Feed – Add Testimonials and Customer Reviews From Google Reviews, Yelp, TripAdvisor, and More v2.9.0
2.11.0 2.10.0 2.9.0 2.8.0 2.7.0 2.6.7 2.6.8 2.6.5 2.6.4 2.6.3 2.6.2 2.6.0 2.5.5 2.5.4 2.5.3 2.5.2 trunk 1.0 1.0.1 1.0.2 1.0.3 1.1 1.1.1 1.1.2 1.2.0 2.0 2.1.0 2.1.1 2.4.0 2.4.1 2.4.2 2.4.3 2.4.4 2.4.5 2.4.6 2.5.0 2.5.1
reviews-feed / class / Common / Integrations / SBR_GDPR.php
reviews-feed / class / Common / Integrations Last commit date
Analytics 1 month ago Elementor 1 month ago Providers 1 month ago SBR_GDPR.php 1 month ago SBRelay.php 1 month ago
SBR_GDPR.php
102 lines
1 <?php
2
3 /**
4 * Namespace SmashBalloon\Reviews\Common\Integrations
5 */
6
7 namespace SmashBalloon\Reviews\Common\Integrations;
8
9 /**
10 * Class to check if the GDPR is enabled
11 * Hide+Show images/avatars depending on the GDPR settings
12 */
13 class SBR_GDPR
14 {
15 public static function doing_gdpr()
16 {
17 $settings = get_option('sbr_settings', []);
18 if (!is_array($settings)) {
19 $settings = [];
20 }
21
22 $gdpr = !empty($settings['gdpr']) ? $settings['gdpr'] : 'auto';
23
24 if ($gdpr === 'auto') {
25 return self::gdpr_plugins_active() !== false;
26 }
27
28 return $gdpr === 'yes' ? true : false;
29 }
30
31 /**
32 * Check if a GDPR plugin is active
33 *
34 * @return string|false
35 */
36 public static function gdpr_plugins_active()
37 {
38 // WPConsent by the WPConsent team
39 if (function_exists('WPConsent')) {
40 return 'WPConsent by the WPConsent team';
41 }
42
43 // Real Cookie Banner by devowl.io
44 if (defined('RCB_ROOT_SLUG')) {
45 return 'Real Cookie Banner by devowl.io';
46 }
47
48 // GDPR Cookie Compliance by Moove Agency
49 if (function_exists('gdpr_cookie_is_accepted')) {
50 return 'GDPR Cookie Compliance by Moove Agency';
51 }
52
53 // Cookie Notice by dFactory
54 if (class_exists('Cookie_Notice')) {
55 return 'Cookie Notice by dFactory';
56 }
57
58 // GDPR Cookie Consent by WebToffee
59 if (
60 function_exists('run_cookie_law_info')
61 || class_exists('Cookie_Law_Info')
62 ) {
63 return 'GDPR Cookie Consent by WebToffee';
64 }
65
66 // CookieYes | GDPR Cookie Consent by CookieYes
67 if (defined('CKY_APP_ASSETS_URL')) {
68 return 'CookieYes | GDPR Cookie Consent by CookieYes';
69 }
70
71 // Cookiebot by Cybot A/S
72 if (class_exists('Cookiebot_WP')) {
73 return 'Cookiebot by Cybot A/S';
74 }
75
76 // Complianz by Really Simple Plugins
77 if (class_exists('COMPLIANZ')) {
78 return 'Complianz by Really Simple Plugins';
79 }
80
81 // Borlabs Cookie by Borlabs
82 if (
83 function_exists('BorlabsCookieHelper')
84 || (defined('BORLABS_COOKIE_VERSION')
85 && version_compare(BORLABS_COOKIE_VERSION, '3.0', '>='))
86 ) {
87 return 'Borlabs Cookie by Borlabs';
88 }
89
90 // SBR Feed Builder
91 if (
92 is_admin()
93 && !empty($_GET['page'])
94 && $_GET['page'] === 'sbr'
95 ) {
96 return false;
97 }
98
99 return false;
100 }
101 }
102