Version Description
- Improved code quality
- Security & Sanitize functions extended
- Added reset settings button
- Bugfixes
Download this release
Release Info
Developer | MooveAgency |
Plugin | GDPR Cookie Compliance |
Version | 3.2.0 |
Comparing to | |
See all releases |
Code changes from version 3.1.1 to 3.2.0
- moove-modules-view.php → class-gdpr-modules-view.php +8 -6
- class-gdpr-modules.php +392 -0
- moove-view.php → class-gdpr-view.php +6 -4
- moove-actions.php → class-moove-gdpr-actions.php +78 -49
- class-moove-gdpr-content.php +498 -0
- moove-options.php → class-moove-gdpr-options.php +12 -8
- controllers/class-moove-gdpr-controller.php +471 -0
- controllers/class-moove-gdpr-license-manager.php +228 -0
- controllers/class-moove-gdpr-updater.php +287 -0
- controllers/moove-controller.php +0 -424
- controllers/moove-license-manager.php +0 -189
- controllers/moove-plugin-updater.php +0 -227
- dist/scripts/admin.js +1 -1
- dist/scripts/main.js +2 -2
- dist/styles/admin.css +1 -1
- gdpr-functions.php +400 -0
- gdpr-modules/branding-styles.php +10 -10
- gdpr-modules/modal/company-logo.php +1 -1
- gdpr-modules/modal/modal-base-onepage.php +1 -1
- gdpr-modules/modal/modal-base-tabs.php +1 -1
- gdpr-modules/modal/tab-footer-buttons.php +2 -2
- gdpr-modules/modal/tab-navigation.php +5 -5
- moove-content.php +0 -442
- moove-controller.php +0 -9
- moove-functions.php +0 -381
- moove-gdpr.php +75 -33
- moove-modules.php +0 -378
- readme.txt +7 -1
- views/moove/admin/settings/accept-on-scroll.php +10 -2
- views/moove/admin/settings/advanced-cookies.php +253 -0
- views/moove/admin/settings/advanced_cookies.php +0 -254
- views/moove/admin/settings/banner-settings.php +198 -0
- views/moove/admin/settings/banner_settings.php +0 -193
- views/moove/admin/settings/branding.php +180 -175
- views/moove/admin/settings/cookie-banner-manager.php +10 -2
- views/moove/admin/settings/cookie-policy.php +114 -0
- views/moove/admin/settings/cookie_policy.php +0 -107
- views/moove/admin/settings/export-import.php +10 -2
- views/moove/admin/settings/floating-button.php +143 -0
- views/moove/admin/settings/floating_button.php +0 -129
- views/moove/admin/settings/full-screen-mode.php +10 -2
- views/moove/admin/settings/general-settings.php +169 -0
- views/moove/admin/settings/general_settings.php +0 -136
- views/moove/admin/settings/geo-location.php +10 -1
- views/moove/admin/settings/help.php +183 -229
- views/moove/admin/settings/iframe-blocker.php +9 -1
- views/moove/admin/settings/licence.php +126 -118
- views/moove/admin/settings/multisite-settings.php +11 -2
- views/moove/admin/settings/plugin-boxes.php +121 -0
- views/moove/admin/settings/plugin_boxes.php +0 -118
- views/moove/admin/settings/privacy-overview.php +91 -0
- views/moove/admin/settings/privacy_overview.php +0 -83
- views/moove/admin/settings/settings-page.php +160 -0
- views/moove/admin/settings/settings_page.php +0 -159
- views/moove/admin/settings/stats.php +11 -1
- views/moove/admin/settings/strictly-necessary-cookies.php +168 -0
- views/moove/admin/settings/strictly_necessary_cookies.php +0 -155
- views/moove/admin/settings/third-party-cookies.php +280 -0
- views/moove/admin/settings/third_party_cookies.php +0 -256
- views/moove/admin/settings/video-tutorial.php +13 -3
moove-modules-view.php → class-gdpr-modules-view.php
RENAMED
@@ -1,6 +1,4 @@
|
|
1 |
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
3 |
-
|
4 |
/**
|
5 |
* GDPR_Modules_View File Doc Comment
|
6 |
*
|
@@ -9,6 +7,10 @@ if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
|
9 |
* @author Gaspar Nemes
|
10 |
*/
|
11 |
|
|
|
|
|
|
|
|
|
12 |
/**
|
13 |
* GDPR_Modules_View Class Doc Comment
|
14 |
*
|
@@ -22,13 +24,13 @@ class GDPR_Modules_View {
|
|
22 |
*
|
23 |
* Parameters:
|
24 |
*
|
25 |
-
* @param string $view
|
26 |
-
* @param mixed $
|
27 |
*/
|
28 |
public static function load( $view, $content ) {
|
29 |
$view_file_origin = dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'gdpr-modules';
|
30 |
-
$view_name
|
31 |
-
$locate_template
|
32 |
$view_file_origin = $locate_template ? $locate_template : $view_file_origin . DIRECTORY_SEPARATOR . $view_name;
|
33 |
if ( file_exists( $view_file_origin ) ) :
|
34 |
ob_start();
|
1 |
<?php
|
|
|
|
|
2 |
/**
|
3 |
* GDPR_Modules_View File Doc Comment
|
4 |
*
|
7 |
* @author Gaspar Nemes
|
8 |
*/
|
9 |
|
10 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
11 |
+
exit;
|
12 |
+
} // Exit if accessed directly
|
13 |
+
|
14 |
/**
|
15 |
* GDPR_Modules_View Class Doc Comment
|
16 |
*
|
24 |
*
|
25 |
* Parameters:
|
26 |
*
|
27 |
+
* @param string $view // the view to load, dot used as directory separator, no file extension given.
|
28 |
+
* @param mixed $content // The data to display in the view (could be anything, even an object).
|
29 |
*/
|
30 |
public static function load( $view, $content ) {
|
31 |
$view_file_origin = dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'gdpr-modules';
|
32 |
+
$view_name = str_replace( '.', DIRECTORY_SEPARATOR, $view ) . '.php';
|
33 |
+
$locate_template = locate_template( 'gdpr-modules' . DIRECTORY_SEPARATOR . $view_name );
|
34 |
$view_file_origin = $locate_template ? $locate_template : $view_file_origin . DIRECTORY_SEPARATOR . $view_name;
|
35 |
if ( file_exists( $view_file_origin ) ) :
|
36 |
ob_start();
|
class-gdpr-modules.php
ADDED
@@ -0,0 +1,392 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* GDPR_Modules File Doc Comment
|
4 |
+
*
|
5 |
+
* @category GDPR_Modules
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
11 |
+
exit;
|
12 |
+
} // Exit if accessed directly
|
13 |
+
|
14 |
+
/**
|
15 |
+
* GDPR_Modules Class Doc Comment
|
16 |
+
*
|
17 |
+
* @category Class
|
18 |
+
* @package Moove_Modules
|
19 |
+
* @author Gaspar Nemes
|
20 |
+
*/
|
21 |
+
class GDPR_Modules {
|
22 |
+
/**
|
23 |
+
* GDPR Options.
|
24 |
+
*
|
25 |
+
* @var array $gdpr_options GDPR Options.
|
26 |
+
*/
|
27 |
+
protected $gdpr_options;
|
28 |
+
|
29 |
+
/**
|
30 |
+
* Language code.
|
31 |
+
*
|
32 |
+
* @var string $wmpl_lang Language code.
|
33 |
+
*/
|
34 |
+
protected $wpml_lang;
|
35 |
+
|
36 |
+
/**
|
37 |
+
* Construct function
|
38 |
+
*/
|
39 |
+
public function __construct() {
|
40 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
41 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
42 |
+
$modal_options = get_option( $option_name );
|
43 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
44 |
+
$this->gdpr_options = $modal_options;
|
45 |
+
$this->wpml_lang = $wpml_lang;
|
46 |
+
}
|
47 |
+
|
48 |
+
/**
|
49 |
+
* GDPR Module - Floating Button view & content
|
50 |
+
*/
|
51 |
+
public function get_floating_button() {
|
52 |
+
$view_controller = new GDPR_Modules_View();
|
53 |
+
$modal_options = $this->gdpr_options;
|
54 |
+
$wpml_lang = $this->wpml_lang;
|
55 |
+
$floating_button_visibility = 'display: block;';
|
56 |
+
$floating_button_class = '';
|
57 |
+
$infobar_hidden = isset( $modal_options['moove_gdpr_infobar_visibility'] ) && 'hidden' === $modal_options['moove_gdpr_infobar_visibility'] ? true : false;
|
58 |
+
if ( $infobar_hidden ) :
|
59 |
+
$floating_button_class = 'button-visible';
|
60 |
+
endif;
|
61 |
+
$floating_button_position = isset( $modal_options['moove_gdpr_floating_button_position'] ) ? $modal_options['moove_gdpr_floating_button_position'] : '';
|
62 |
+
$data = new stdClass();
|
63 |
+
$data->options = $modal_options;
|
64 |
+
$data->wpml_lang = $wpml_lang;
|
65 |
+
$data->is_enabled = ( isset( $modal_options['moove_gdpr_floating_button_enable'] ) && 1 === intval( $modal_options['moove_gdpr_floating_button_enable'] ) ) ? true : false;
|
66 |
+
$data->styles = $floating_button_visibility . $floating_button_position;
|
67 |
+
$data->class = $floating_button_class;
|
68 |
+
if ( $floating_button_position ) :
|
69 |
+
$data->class = $floating_button_class .= ' gdpr-floating-button-custom-position';
|
70 |
+
endif;
|
71 |
+
$data->label = ( isset( $modal_options[ 'moove_gdpr_floating_button_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_floating_button_label' . $wpml_lang ] ) ? $modal_options[ 'moove_gdpr_floating_button_label' . $wpml_lang ] : __( 'Change cookie settings', 'gdpr-cookie-compliance' );
|
72 |
+
return $view_controller->load( 'infobar.floating-button', $data );
|
73 |
+
}
|
74 |
+
|
75 |
+
/**
|
76 |
+
* GDPR Module - Base structure
|
77 |
+
*/
|
78 |
+
public function get_modal_base() {
|
79 |
+
$view_controller = new GDPR_Modules_View();
|
80 |
+
$modal_options = $this->gdpr_options;
|
81 |
+
$wpml_lang = $this->wpml_lang;
|
82 |
+
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
83 |
+
$tab_title = isset( $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] : __( 'Privacy Overview', 'gdpr-cookie-compliance' );
|
84 |
+
$data = new stdClass();
|
85 |
+
$data->logo_position = isset( $modal_options['moove_gdpr_logo_position'] ) ? $modal_options['moove_gdpr_logo_position'] : 'left';
|
86 |
+
$data->theme = 'moove_gdpr_modal_theme_' . $layout;
|
87 |
+
$modal_theme = 'moove_gdpr_modal_theme_' . $layout;
|
88 |
+
$data->modal_title = 'v1' === $layout ? false : $tab_title;
|
89 |
+
$view_type = 'v1' === $layout ? 'tabs' : 'onepage';
|
90 |
+
return $view_controller->load( 'modal.modal-base-' . $view_type, $data );
|
91 |
+
}
|
92 |
+
|
93 |
+
/**
|
94 |
+
* GDPR Module - Infobar structure
|
95 |
+
*/
|
96 |
+
public function get_infobar_base() {
|
97 |
+
$view_controller = new GDPR_Modules_View();
|
98 |
+
$modal_options = $this->gdpr_options;
|
99 |
+
$wpml_lang = $this->wpml_lang;
|
100 |
+
$data = new stdClass();
|
101 |
+
$infobar_classes = array(
|
102 |
+
'moove-gdpr-info-bar-hidden',
|
103 |
+
'moove-gdpr-align-center',
|
104 |
+
);
|
105 |
+
$modal_scheme = isset( $modal_options['moove_gdpr_colour_scheme'] ) ? ( ( 1 === intval( $modal_options['moove_gdpr_colour_scheme'] ) || 2 === intval( $modal_options['moove_gdpr_colour_scheme'] ) ) ? intval( $modal_options['moove_gdpr_colour_scheme'] ) : 1 ) : 1;
|
106 |
+
|
107 |
+
$scheme_class = 2 === $modal_scheme ? 'moove-gdpr-light-scheme' : 'moove-gdpr-dark-scheme';
|
108 |
+
$infobar_position = isset( $modal_options['moove_gdpr_infobar_position'] ) ? $modal_options['moove_gdpr_infobar_position'] : 'bottom';
|
109 |
+
$infobar_classes[] = $scheme_class;
|
110 |
+
$infobar_classes[] = 'gdpr_infobar_postion_' . $infobar_position;
|
111 |
+
$infobar_classes = apply_filters( 'gdpr_info_bar_class_extension', $infobar_classes );
|
112 |
+
$infobar_hidden = isset( $modal_options['moove_gdpr_infobar_visibility'] ) && 'hidden' === $modal_options['moove_gdpr_infobar_visibility'] ? true : false;
|
113 |
+
$data->show = $infobar_hidden ? false : true;
|
114 |
+
$data->class = implode( ' ', $infobar_classes );
|
115 |
+
$infobar_content = apply_filters( 'gdpr_info_bar_popup_content', $view_controller->load( 'infobar.infobar-base', $data ) );
|
116 |
+
return $infobar_content;
|
117 |
+
|
118 |
+
}
|
119 |
+
|
120 |
+
/**
|
121 |
+
* GDPR Module - Infobar Main Content
|
122 |
+
*/
|
123 |
+
public function get_infobar_content() {
|
124 |
+
$view_controller = new GDPR_Modules_View();
|
125 |
+
$modal_options = $this->gdpr_options;
|
126 |
+
$wpml_lang = $this->wpml_lang;
|
127 |
+
$_content = '<p>' . __( 'This website uses cookies to provide you with the best browsing experience.', 'gdpr-cookie-compliance' ) . '</p>' .
|
128 |
+
'<p>' . __( 'Find out more or adjust your [setting]settings[/setting].', 'gdpr-cookie-compliance' ) . '</p>';
|
129 |
+
$content = isset( $modal_options[ 'moove_gdpr_info_bar_content' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_info_bar_content' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_info_bar_content' . $wpml_lang ] : $_content;
|
130 |
+
$content = str_replace( '[setting]', '<span data-href="#moove_gdpr_cookie_modal" class="change-settings-button">', $content );
|
131 |
+
$content = str_replace( '[/setting]', '</span>', $content );
|
132 |
+
$content = apply_filters( 'gdpr_info_bar_notice_content', $content );
|
133 |
+
$data = new stdClass();
|
134 |
+
$data->text_content = $content;
|
135 |
+
return $view_controller->load( 'infobar.infobar-content', $data );
|
136 |
+
}
|
137 |
+
|
138 |
+
/**
|
139 |
+
* GDPR Module - Infobar button & extensions
|
140 |
+
*/
|
141 |
+
public function get_infobar_buttons() {
|
142 |
+
$view_controller = new GDPR_Modules_View();
|
143 |
+
$modal_options = $this->gdpr_options;
|
144 |
+
$wpml_lang = $this->wpml_lang;
|
145 |
+
$data = new stdClass();
|
146 |
+
$data->button_label = isset( $modal_options[ 'moove_gdpr_infobar_accept_button_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_infobar_accept_button_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_infobar_accept_button_label' . $wpml_lang ] : __( 'Accept', 'gdpr-cookie-compliance' );
|
147 |
+
return $view_controller->load( 'infobar.infobar-buttons', $data );
|
148 |
+
|
149 |
+
}
|
150 |
+
|
151 |
+
/**
|
152 |
+
* GDPR Module - Company Logo
|
153 |
+
*/
|
154 |
+
public function get_company_logo() {
|
155 |
+
$view_controller = new GDPR_Modules_View();
|
156 |
+
$modal_options = $this->gdpr_options;
|
157 |
+
$wpml_lang = $this->wpml_lang;
|
158 |
+
$data = new stdClass();
|
159 |
+
$data->options = $modal_options;
|
160 |
+
$data->wpml_lang = $wpml_lang;
|
161 |
+
$data->logo_url = isset( $modal_options['moove_gdpr_company_logo'] ) && $modal_options['moove_gdpr_company_logo'] ? $modal_options['moove_gdpr_company_logo'] : plugin_dir_url( __FILE__ ) . 'dist/images/gdpr-logo.png';
|
162 |
+
$data->logo_url = str_replace( plugin_dir_url( __FILE__ ) . 'dist/images/moove-logo.png', plugin_dir_url( __FILE__ ) . 'dist/images/gdpr-logo.png', $data->logo_url );
|
163 |
+
$data->logo_alt = gdpr_get_logo_alt( $data->logo_url );
|
164 |
+
return $view_controller->load( 'modal.company-logo', $data );
|
165 |
+
}
|
166 |
+
|
167 |
+
/**
|
168 |
+
* GDPR Module - Branding Options
|
169 |
+
*/
|
170 |
+
public function get_gdpr_branding() {
|
171 |
+
$view_controller = new GDPR_Modules_View();
|
172 |
+
$moove_actions_cnt = new Moove_GDPR_Actions();
|
173 |
+
$modal_options = $this->gdpr_options;
|
174 |
+
$wpml_lang = $this->wpml_lang;
|
175 |
+
$data = new stdClass();
|
176 |
+
$data->options = $modal_options;
|
177 |
+
$data->wpml_lang = $wpml_lang;
|
178 |
+
$data->text = $moove_actions_cnt->moove_gdpr_footer_branding_content();
|
179 |
+
$data->is_enabled = isset( $modal_options['moove_gdpr_modal_powered_by_disable'] ) && 1 === intval( $modal_options['moove_gdpr_modal_powered_by_disable'] ) ? false : true;
|
180 |
+
return $view_controller->load( 'modal.gdpr-branding', $data );
|
181 |
+
}
|
182 |
+
|
183 |
+
/**
|
184 |
+
* GDPR Module - Privacy Overview Content
|
185 |
+
*/
|
186 |
+
public function get_section_overview() {
|
187 |
+
$view_controller = new GDPR_Modules_View();
|
188 |
+
$modal_options = $this->gdpr_options;
|
189 |
+
$wpml_lang = $this->wpml_lang;
|
190 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
191 |
+
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
192 |
+
$tab_title = isset( $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] : __( 'Privacy Overview', 'gdpr-cookie-compliance' );
|
193 |
+
$tab_content = isset( $modal_options[ 'moove_gdpr_privacy_overview_tab_content' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_privacy_overview_tab_content' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_privacy_overview_tab_content' . $wpml_lang ] : $gdpr_default_content->moove_gdpr_get_privacy_overview_content();
|
194 |
+
$data = new stdClass();
|
195 |
+
$data->options = $modal_options;
|
196 |
+
$data->wpml_lang = $wpml_lang;
|
197 |
+
$data->tab_title = 'v1' === $layout ? $tab_title : false;
|
198 |
+
$data->tab_content = wpautop( $tab_content );
|
199 |
+
$data->visibility = 'v1' === $layout ? 'style="display:none"' : '';
|
200 |
+
|
201 |
+
return $view_controller->load( 'modal.content-sections.overview', $data );
|
202 |
+
|
203 |
+
}
|
204 |
+
|
205 |
+
/**
|
206 |
+
* GPDR Module - Strictly Necessary Cookies
|
207 |
+
*/
|
208 |
+
public function get_section_strictly() {
|
209 |
+
$view_controller = new GDPR_Modules_View();
|
210 |
+
$modal_options = $this->gdpr_options;
|
211 |
+
$wpml_lang = $this->wpml_lang;
|
212 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
213 |
+
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
214 |
+
$tab_title = isset( $modal_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] : __( 'Strictly Necessary Cookies', 'gdpr-cookie-compliance' );
|
215 |
+
$tab_content = isset( $modal_options[ 'moove_gdpr_strict_necessary_cookies_tab_content' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_strict_necessary_cookies_tab_content' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_strict_necessary_cookies_tab_content' . $wpml_lang ] : $gdpr_default_content->moove_gdpr_get_strict_necessary_content();
|
216 |
+
$strictly = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) : 1;
|
217 |
+
$warning_msg = isset( $modal_options[ 'moove_gdpr_strictly_necessary_cookies_warning' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_strictly_necessary_cookies_warning' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_strictly_necessary_cookies_warning' . $wpml_lang ] : $gdpr_default_content->moove_gdpr_get_strict_necessary_warning();
|
218 |
+
$data = new stdClass();
|
219 |
+
$data->options = $modal_options;
|
220 |
+
$data->wpml_lang = $wpml_lang;
|
221 |
+
$data->tab_title = $tab_title;
|
222 |
+
$data->tab_content = wpautop( $tab_content );
|
223 |
+
$data->show = 3 !== $strictly;
|
224 |
+
$data->is_checked = 1 !== $strictly ? 'disabled checked="checked" ' : '';
|
225 |
+
$data->text_enable = isset( $modal_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] : __( 'Enabled', 'gdpr-cookie-compliance' );
|
226 |
+
$data->text_disable = isset( $modal_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] : __( 'Disabled', 'gdpr-cookie-compliance' );
|
227 |
+
$data->warning_message_top = 'v2' === $layout ? wpautop( $warning_msg ) : false;
|
228 |
+
$data->warning_message_bottom = 'v1' === $layout ? wpautop( $warning_msg ) : false;
|
229 |
+
$data->checkbox_state = 1 !== $strictly ? 'gdpr-checkbox-disabled checkbox-selected' : '';
|
230 |
+
$data->visibility = 'v1' === $layout ? 'style="display:none"' : '';
|
231 |
+
return $view_controller->load( 'modal.content-sections.strictly', $data );
|
232 |
+
}
|
233 |
+
|
234 |
+
/**
|
235 |
+
* GDPR Module - Advanced Cookies
|
236 |
+
*/
|
237 |
+
public function get_section_advanced() {
|
238 |
+
$view_controller = new GDPR_Modules_View();
|
239 |
+
$modal_options = $this->gdpr_options;
|
240 |
+
$wpml_lang = $this->wpml_lang;
|
241 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
242 |
+
|
243 |
+
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
244 |
+
$tab_title = isset( $modal_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] : __( 'Additional Cookies', 'gdpr-cookie-compliance' );
|
245 |
+
$tab_content = isset( $modal_options[ 'moove_gdpr_advanced_cookies_tab_content' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_advanced_cookies_tab_content' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_advanced_cookies_tab_content' . $wpml_lang ] : $gdpr_default_content->moove_gdpr_get_advanced_cookies_content();
|
246 |
+
$strictly = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) : 1;
|
247 |
+
$data = new stdClass();
|
248 |
+
$data->options = $modal_options;
|
249 |
+
$data->wpml_lang = $wpml_lang;
|
250 |
+
$data->tab_title = $tab_title;
|
251 |
+
$data->tab_content = wpautop( $tab_content );
|
252 |
+
$data->show = isset( $modal_options['moove_gdpr_advanced_cookies_enable'] ) && 1 === intval( $modal_options['moove_gdpr_advanced_cookies_enable'] ) ? true : false;
|
253 |
+
$data->is_checked = 1 !== $strictly ? '' : 'disabled';
|
254 |
+
$data->fieldset = 1 !== $strictly ? 'fl-strenabled' : 'fl-disabled';
|
255 |
+
$data->text_enable = isset( $modal_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] : __( 'Enabled', 'gdpr-cookie-compliance' );
|
256 |
+
$data->text_disable = isset( $modal_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] : __( 'Disabled', 'gdpr-cookie-compliance' );
|
257 |
+
$data->warning_message = isset( $modal_options[ 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ] : $gdpr_default_content->moove_gdpr_get_secondary_notice();
|
258 |
+
$data->warning_message = wpautop( $data->warning_message );
|
259 |
+
$data->visibility = 'v1' === $layout ? 'style="display:none"' : '';
|
260 |
+
return $view_controller->load( 'modal.content-sections.advanced', $data );
|
261 |
+
}
|
262 |
+
|
263 |
+
/**
|
264 |
+
* GDPR Module - Third Party Cookies
|
265 |
+
*/
|
266 |
+
public function get_section_third_party() {
|
267 |
+
$view_controller = new GDPR_Modules_View();
|
268 |
+
$modal_options = $this->gdpr_options;
|
269 |
+
$wpml_lang = $this->wpml_lang;
|
270 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
271 |
+
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
272 |
+
$tab_title = isset( $modal_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] : __( '3rd Party Cookies', 'gdpr-cookie-compliance' );
|
273 |
+
$tab_content = isset( $modal_options[ 'moove_gdpr_performance_cookies_tab_content' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_performance_cookies_tab_content' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_performance_cookies_tab_content' . $wpml_lang ] : $gdpr_default_content->moove_gdpr_get_third_party_content();
|
274 |
+
$strictly = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) : 1;
|
275 |
+
$data = new stdClass();
|
276 |
+
$data->options = $modal_options;
|
277 |
+
$data->wpml_lang = $wpml_lang;
|
278 |
+
$data->tab_title = $tab_title;
|
279 |
+
$data->tab_content = wpautop( $tab_content );
|
280 |
+
$data->show = isset( $modal_options['moove_gdpr_third_party_cookies_enable'] ) && 1 === intval( $modal_options['moove_gdpr_third_party_cookies_enable'] ) ? true : false;
|
281 |
+
$data->is_checked = 1 !== $strictly ? '' : 'disabled';
|
282 |
+
$data->fieldset = 1 !== $strictly ? 'fl-strenabled' : 'fl-disabled';
|
283 |
+
$data->text_enable = isset( $modal_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] : __( 'Enabled', 'gdpr-cookie-compliance' );
|
284 |
+
$data->text_disable = isset( $modal_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] : __( 'Disabled', 'gdpr-cookie-compliance' );
|
285 |
+
$data->warning_message = isset( $modal_options[ 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ] : $gdpr_default_content->moove_gdpr_get_secondary_notice();
|
286 |
+
$data->warning_message = wpautop( $data->warning_message );
|
287 |
+
$data->visibility = 'v1' === $layout ? 'style="display:none"' : '';
|
288 |
+
return $view_controller->load( 'modal.content-sections.third_party', $data );
|
289 |
+
}
|
290 |
+
|
291 |
+
/**
|
292 |
+
* GDPR Module - Custom CSS for branding
|
293 |
+
*/
|
294 |
+
public function get_branding_styles() {
|
295 |
+
$view_controller = new GDPR_Modules_View();
|
296 |
+
$modal_options = $this->gdpr_options;
|
297 |
+
$wpml_lang = $this->wpml_lang;
|
298 |
+
$font_family = false;
|
299 |
+
if ( isset( $modal_options['moove_gdpr_plugin_font_type'] ) ) :
|
300 |
+
if ( '1' === $modal_options['moove_gdpr_plugin_font_type'] ) :
|
301 |
+
$font_family = "'Nunito', sans-serif";
|
302 |
+
elseif ( '2' === $modal_options['moove_gdpr_plugin_font_type'] ) :
|
303 |
+
$font_family = 'inherit';
|
304 |
+
else :
|
305 |
+
$font_family = isset( $modal_options['moove_gdpr_plugin_font_family'] ) && $modal_options['moove_gdpr_plugin_font_family'] ? $modal_options['moove_gdpr_plugin_font_family'] : "'Nunito', sans-serif";
|
306 |
+
endif;
|
307 |
+
endif;
|
308 |
+
$font_family = $font_family ? $font_family : ( isset( $modal_options['moove_gdpr_plugin_font_family'] ) && $modal_options['moove_gdpr_plugin_font_family'] ? $modal_options['moove_gdpr_plugin_font_family'] : "'Nunito', sans-serif" );
|
309 |
+
$data = new stdClass();
|
310 |
+
$data->primary_colour = isset( $modal_options['moove_gdpr_brand_colour'] ) && $modal_options['moove_gdpr_brand_colour'] ? $modal_options['moove_gdpr_brand_colour'] : '#0C4DA2';
|
311 |
+
$data->secondary_colour = isset( $modal_options['moove_gdpr_brand_secondary_colour'] ) && $modal_options['moove_gdpr_brand_secondary_colour'] ? $modal_options['moove_gdpr_brand_secondary_colour'] : '#000000';
|
312 |
+
$data->button_bg = isset( $modal_options['moove_gdpr_floating_button_background_colour'] ) && $modal_options['moove_gdpr_floating_button_background_colour'] ? $modal_options['moove_gdpr_floating_button_background_colour'] : '#373737';
|
313 |
+
$data->button_hover_bg = isset( $modal_options['moove_gdpr_floating_button_hover_background_colour'] ) && $modal_options['moove_gdpr_floating_button_hover_background_colour'] ? $modal_options['moove_gdpr_floating_button_hover_background_colour'] : '#000000';
|
314 |
+
$data->button_font = isset( $modal_options['moove_gdpr_floating_button_font_colour'] ) && $modal_options['moove_gdpr_floating_button_font_colour'] ? $modal_options['moove_gdpr_floating_button_font_colour'] : '#ffffff';
|
315 |
+
$data->font_family = $font_family;
|
316 |
+
return $view_controller->load( 'branding-styles', $data );
|
317 |
+
|
318 |
+
}
|
319 |
+
|
320 |
+
/**
|
321 |
+
* GDPR Module - Cookie Policy Page
|
322 |
+
*/
|
323 |
+
public function get_section_cookiepolicy() {
|
324 |
+
$view_controller = new GDPR_Modules_View();
|
325 |
+
$modal_options = $this->gdpr_options;
|
326 |
+
$wpml_lang = $this->wpml_lang;
|
327 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
328 |
+
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
329 |
+
$tab_title = isset( $modal_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] : __( '3rd Party Cookies', 'gdpr-cookie-compliance' );
|
330 |
+
$tab_content = isset( $modal_options[ 'moove_gdpr_cookies_policy_tab_content' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_cookies_policy_tab_content' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_cookies_policy_tab_content' . $wpml_lang ] : $gdpr_default_content->moove_gdpr_get_cookie_policy_content();
|
331 |
+
$data = new stdClass();
|
332 |
+
$data->options = $modal_options;
|
333 |
+
$data->wpml_lang = $wpml_lang;
|
334 |
+
$data->tab_title = $tab_title;
|
335 |
+
$data->tab_content = wpautop( $tab_content );
|
336 |
+
$data->show = isset( $modal_options['moove_gdpr_cookie_policy_enable'] ) && 1 === intval( $modal_options['moove_gdpr_cookie_policy_enable'] ) ? true : false;
|
337 |
+
$data->visibility = 'v1' === $layout ? 'style="display:none"' : '';
|
338 |
+
return $view_controller->load( 'modal.content-sections.cookiepolicy', $data );
|
339 |
+
}
|
340 |
+
|
341 |
+
/**
|
342 |
+
* GDPR Module - Footer Button inside the Modal
|
343 |
+
*/
|
344 |
+
public function get_tab_footer_buttons() {
|
345 |
+
$view_controller = new GDPR_Modules_View();
|
346 |
+
$modal_options = $this->gdpr_options;
|
347 |
+
$wpml_lang = $this->wpml_lang;
|
348 |
+
$data = new stdClass();
|
349 |
+
$data->allow_label = isset( $modal_options[ 'moove_gdpr_modal_allow_button_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_modal_allow_button_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_modal_allow_button_label' . $wpml_lang ] : __( 'Enable All', 'gdpr-cookie-compliance' );
|
350 |
+
$data->settings_label = isset( $modal_options[ 'moove_gdpr_modal_save_button_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_modal_save_button_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_modal_save_button_label' . $wpml_lang ] : __( 'Save Settings', 'gdpr-cookie-compliance' );
|
351 |
+
|
352 |
+
return $view_controller->load( 'modal.tab-footer-buttons', $data );
|
353 |
+
}
|
354 |
+
|
355 |
+
/**
|
356 |
+
* GDPR Module - Navigation inside the modal
|
357 |
+
*/
|
358 |
+
public function get_tab_navigation() {
|
359 |
+
$view_controller = new GDPR_Modules_View();
|
360 |
+
$modal_options = $this->gdpr_options;
|
361 |
+
$wpml_lang = $this->wpml_lang;
|
362 |
+
$strictly = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) : 1;
|
363 |
+
$data = new stdClass();
|
364 |
+
$data->overview = new stdClass();
|
365 |
+
$data->strictly = new stdClass();
|
366 |
+
$data->advanced = new stdClass();
|
367 |
+
$data->third_party = new stdClass();
|
368 |
+
$data->cookiepolicy = new stdClass();
|
369 |
+
|
370 |
+
// OVERVIEW.
|
371 |
+
$data->overview->nav_label = isset( $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] : __( 'Privacy Overview', 'gdpr-cookie-compliance' );
|
372 |
+
|
373 |
+
// STRICTLY.
|
374 |
+
$data->strictly->show = 3 !== $strictly;
|
375 |
+
$data->strictly->nav_label = isset( $modal_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] : __( 'Strictly Necessary Cookies', 'gdpr-cookie-compliance' );
|
376 |
+
|
377 |
+
// THIRD PARTY.
|
378 |
+
$data->third_party->show = isset( $modal_options['moove_gdpr_third_party_cookies_enable'] ) && 1 === intval( $modal_options['moove_gdpr_third_party_cookies_enable'] ) ? true : false;
|
379 |
+
$data->third_party->nav_label = isset( $modal_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] : __( '3rd Party Cookies', 'gdpr-cookie-compliance' );
|
380 |
+
|
381 |
+
// ADVANCED.
|
382 |
+
$data->advanced->show = isset( $modal_options['moove_gdpr_advanced_cookies_enable'] ) && 1 === intval( $modal_options['moove_gdpr_advanced_cookies_enable'] ) ? true : false;
|
383 |
+
$data->advanced->nav_label = isset( $modal_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] : __( 'Additional Cookies', 'gdpr-cookie-compliance' );
|
384 |
+
|
385 |
+
// COOKIEPOLICY.
|
386 |
+
$data->cookiepolicy->show = isset( $modal_options['moove_gdpr_cookie_policy_enable'] ) && 1 === intval( $modal_options['moove_gdpr_cookie_policy_enable'] ) ? true : false;
|
387 |
+
$data->cookiepolicy->nav_label = isset( $modal_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] : __( 'Cookie Policy', 'gdpr-cookie-compliance' );
|
388 |
+
|
389 |
+
return $view_controller->load( 'modal.tab-navigation', $data );
|
390 |
+
}
|
391 |
+
|
392 |
+
}
|
moove-view.php → class-gdpr-view.php
RENAMED
@@ -1,6 +1,4 @@
|
|
1 |
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
3 |
-
|
4 |
/**
|
5 |
* GDPR_View File Doc Comment
|
6 |
*
|
@@ -9,6 +7,10 @@ if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
|
9 |
* @author Gaspar Nemes
|
10 |
*/
|
11 |
|
|
|
|
|
|
|
|
|
12 |
/**
|
13 |
* GDPR_View Class Doc Comment
|
14 |
*
|
@@ -23,11 +25,11 @@ class GDPR_View {
|
|
23 |
* Parameters:
|
24 |
*
|
25 |
* @param string $view // the view to load, dot used as directory separator, no file extension given.
|
26 |
-
* @param mixed $
|
27 |
*/
|
28 |
public static function load( $view, $content ) {
|
29 |
$view_file_origin = dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'views';
|
30 |
-
$view_name
|
31 |
if ( file_exists( $view_file_origin . DIRECTORY_SEPARATOR . $view_name ) ) :
|
32 |
ob_start();
|
33 |
include $view_file_origin . DIRECTORY_SEPARATOR . $view_name;
|
1 |
<?php
|
|
|
|
|
2 |
/**
|
3 |
* GDPR_View File Doc Comment
|
4 |
*
|
7 |
* @author Gaspar Nemes
|
8 |
*/
|
9 |
|
10 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
11 |
+
exit;
|
12 |
+
} // Exit if accessed directly
|
13 |
+
|
14 |
/**
|
15 |
* GDPR_View Class Doc Comment
|
16 |
*
|
25 |
* Parameters:
|
26 |
*
|
27 |
* @param string $view // the view to load, dot used as directory separator, no file extension given.
|
28 |
+
* @param mixed $content // The data to display in the view (could be anything, even an object).
|
29 |
*/
|
30 |
public static function load( $view, $content ) {
|
31 |
$view_file_origin = dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'views';
|
32 |
+
$view_name = str_replace( '.', DIRECTORY_SEPARATOR, $view ) . '.php';
|
33 |
if ( file_exists( $view_file_origin . DIRECTORY_SEPARATOR . $view_name ) ) :
|
34 |
ob_start();
|
35 |
include $view_file_origin . DIRECTORY_SEPARATOR . $view_name;
|
moove-actions.php → class-moove-gdpr-actions.php
RENAMED
@@ -1,8 +1,4 @@
|
|
1 |
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) :
|
3 |
-
exit;
|
4 |
-
endif; // Exit if accessed directly.
|
5 |
-
|
6 |
/**
|
7 |
* Moove_GDPR_Actions File Doc Comment
|
8 |
*
|
@@ -11,6 +7,10 @@ endif; // Exit if accessed directly.
|
|
11 |
* @author Gaspar Nemes
|
12 |
*/
|
13 |
|
|
|
|
|
|
|
|
|
14 |
/**
|
15 |
* Moove_GDPR_Actions Class Doc Comment
|
16 |
*
|
@@ -19,46 +19,51 @@ endif; // Exit if accessed directly.
|
|
19 |
* @author Gaspar Nemes
|
20 |
*/
|
21 |
class Moove_GDPR_Actions {
|
|
|
22 |
/**
|
23 |
* Global variable used in localization
|
24 |
*
|
25 |
-
* @var
|
26 |
*/
|
27 |
-
|
28 |
/**
|
29 |
* Construct
|
30 |
*/
|
31 |
-
function __construct() {
|
32 |
$this->moove_register_scripts();
|
33 |
$this->moove_register_ajax_actions();
|
34 |
add_action( 'gdpr_cookie_filter_settings', array( &$this, 'gdpr_remove_cached_scripts' ) );
|
35 |
add_action( 'gdpr_settings_tab_nav_extensions', array( &$this, 'gdpr_settings_tab_nav_extensions' ), 10, 1 );
|
36 |
add_action( 'gdpr_check_extensions', array( &$this, 'gdpr_check_extensions' ), 10, 2 );
|
37 |
add_action( 'gdpr_premium_section_ads', array( &$this, 'gdpr_premium_section_ads' ) );
|
38 |
-
|
39 |
add_action( 'gdpr_tab_cbm_ph', array( &$this, 'gdpr_premium_section_ads' ) );
|
40 |
add_action( 'gdpr_tab_cbm_ps', array( &$this, 'gdpr_premium_section_ads' ) );
|
41 |
add_action( 'gdpr_get_alertbox', array( 'Moove_GDPR_Content', 'gdpr_get_alertbox' ), 10, 3 );
|
42 |
add_action( 'gdpr_licence_input_field', array( 'Moove_GDPR_Content', 'gdpr_licence_input_field' ), 10, 2 );
|
43 |
add_action( 'gdpr_licence_action_button', array( 'Moove_GDPR_Content', 'gdpr_licence_action_button' ), 10, 2 );
|
44 |
add_action( 'gdpr_premium_update_alert', array( 'Moove_GDPR_Content', 'gdpr_premium_update_alert' ) );
|
45 |
-
|
46 |
add_action( 'gdpr_cdn_url', array( &$this, 'gdpr_cdn_base_url' ), 10, 1 );
|
47 |
add_action( 'gdpr_info_bar_button_extensions', array( &$this, 'gdpr_info_add_reject_button_extensions' ) );
|
48 |
add_action( 'gdpr_support_sidebar_class', array( &$this, 'gdpr_support_sidebar_class' ), 10, 1 );
|
49 |
-
|
50 |
$gdpr_default_content = new Moove_GDPR_Content();
|
51 |
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
52 |
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
53 |
if ( $gdpr_key && ! isset( $gdpr_key['deactivation'] ) ) :
|
54 |
do_action( 'gdpr_plugin_loaded' );
|
55 |
endif;
|
|
|
|
|
|
|
|
|
|
|
56 |
}
|
57 |
|
58 |
/**
|
59 |
* Extra class for admin sidebar widgets
|
|
|
|
|
|
|
60 |
*/
|
61 |
-
|
62 |
public function gdpr_support_sidebar_class( $class ) {
|
63 |
if ( class_exists( 'Moove_GDPR_Addon_View' ) ) :
|
64 |
$class = 'm-plugin-box-highlighted';
|
@@ -66,6 +71,20 @@ class Moove_GDPR_Actions {
|
|
66 |
return $class;
|
67 |
}
|
68 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
69 |
/**
|
70 |
* Reject button extension, will be listed next to the Accept button if it's enabled in the CMS
|
71 |
*/
|
@@ -76,14 +95,16 @@ class Moove_GDPR_Actions {
|
|
76 |
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
77 |
if ( isset( $modal_options['moove_gdpr_reject_button_enable'] ) && intval( $modal_options['moove_gdpr_reject_button_enable'] ) === 1 ) :
|
78 |
$button_label = isset( $modal_options[ 'moove_gdpr_infobar_reject_button_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_infobar_reject_button_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_infobar_reject_button_label' . $wpml_lang ] : __( 'Reject', 'gdpr-cookie-compliance-addon' );
|
79 |
-
|
80 |
-
<button class="mgbutton moove-gdpr-infobar-reject-btn"><?php echo $button_label; ?></button>
|
81 |
-
|
82 |
endif;
|
83 |
-
}
|
84 |
|
85 |
/**
|
86 |
* CDN base URL for lity lightbox
|
|
|
|
|
87 |
*/
|
88 |
public function gdpr_cdn_base_url( $plugin_url ) {
|
89 |
$gdpr_default_content = new Moove_GDPR_Content();
|
@@ -105,20 +126,22 @@ class Moove_GDPR_Actions {
|
|
105 |
public function gdpr_premium_section_ads() {
|
106 |
|
107 |
if ( class_exists( 'Moove_GDPR_Addon_View' ) ) :
|
108 |
-
|
109 |
-
$slug
|
110 |
-
$
|
|
|
|
|
|
|
|
|
111 |
|
112 |
-
if ( ! $view_content && $slug &&
|
113 |
?>
|
114 |
<div class="gdpr-locked-section">
|
115 |
<span>
|
116 |
<i class="dashicons dashicons-lock"></i>
|
117 |
<h4>This feature is not supported in this version of the Premium Add-on.</h4>
|
118 |
-
|
119 |
-
<p><
|
120 |
-
|
121 |
-
<p class="gdpr_license_info">Don’t have a valid licence key yet? <br><a href="<?php echo MOOVE_SHOP_URL; ?>/my-account" target="_blank" class="gdpr_admin_link">Login to your account</a> to generate the key or <a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" class="gdpr_admin_link" target="_blank">buy a new licence here</a>.</p>
|
122 |
<br />
|
123 |
|
124 |
<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="plugin-buy-now-btn">Buy Now</a>
|
@@ -140,9 +163,9 @@ class Moove_GDPR_Actions {
|
|
140 |
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
141 |
?>
|
142 |
<?php if ( isset( $gdpr_key['deactivation'] ) || $gdpr_key['activation'] ) : ?>
|
143 |
-
<p><strong><a href="<?php echo admin_url( 'admin.php' ); ?>?page=moove-gdpr&tab=licence" class="gdpr_admin_link">Activate your licence</a> or <a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" class="gdpr_admin_link" target="_blank">buy a new licence here</a></strong></p>
|
144 |
<?php else : ?>
|
145 |
-
<p><strong>Do you have a licence key? <br />Insert your license key to the "<a href="<?php echo admin_url( 'admin.php' ); ?>?page=moove-gdpr&tab=licence" class="gdpr_admin_link">Licence Manager</a>" and activate it.</strong></p>
|
146 |
|
147 |
<?php endif; ?>
|
148 |
<br />
|
@@ -154,20 +177,23 @@ class Moove_GDPR_Actions {
|
|
154 |
<!-- .gdpr-locked-section -->
|
155 |
<?php
|
156 |
endif;
|
157 |
-
|
158 |
|
159 |
/**
|
160 |
* Checking for Premium Add-on installed and activated
|
|
|
|
|
|
|
161 |
*/
|
162 |
public function gdpr_check_extensions( $content, $slug ) {
|
163 |
$return = $content;
|
164 |
if ( class_exists( 'Moove_GDPR_Addon_View' ) ) :
|
165 |
-
$
|
166 |
-
|
167 |
-
$
|
168 |
-
|
169 |
-
|
170 |
-
|
171 |
else :
|
172 |
$return = '';
|
173 |
endif;
|
@@ -210,11 +236,11 @@ class Moove_GDPR_Actions {
|
|
210 |
$force_reload = $force_reload ? 'true' : 'false';
|
211 |
$geo_location_enabled = isset( $modal_options['moove_gdpr_geolocation_eu'] ) && intval( $modal_options['moove_gdpr_geolocation_eu'] ) === 1 ? 'true' : 'false';
|
212 |
|
213 |
-
// By using this filter, you can force the plugin to load the lity lightbox using PHP instead of JavaScript.
|
214 |
-
$load_lity
|
215 |
-
$load_lity
|
216 |
|
217 |
-
$loc_data
|
218 |
'ajaxurl' => admin_url( 'admin-ajax.php' ),
|
219 |
'post_id' => get_the_ID(),
|
220 |
'plugin_dir' => apply_filters( 'gdpr_cdn_url', plugins_url( basename( dirname( __FILE__ ) ) ) ),
|
@@ -224,13 +250,13 @@ class Moove_GDPR_Actions {
|
|
224 |
'third_party' => isset( $modal_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) && intval( $modal_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) ? intval( $modal_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) : 0,
|
225 |
'advanced' => isset( $modal_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) && intval( $modal_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) ? intval( $modal_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) : 0,
|
226 |
),
|
227 |
-
'geo_location'
|
228 |
'force_reload' => $force_reload,
|
229 |
'is_single' => is_single(),
|
230 |
'current_user' => get_current_user_id(),
|
231 |
-
'load_lity'
|
232 |
);
|
233 |
-
$this->gdpr_loc_data
|
234 |
wp_localize_script( $ascript, 'moove_frontend_gdpr_scripts', $this->gdpr_loc_data );
|
235 |
|
236 |
}
|
@@ -256,12 +282,12 @@ class Moove_GDPR_Actions {
|
|
256 |
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
257 |
$css_file = 'gdpr-main.css';
|
258 |
if ( isset( $modal_options['moove_gdpr_plugin_font_type'] ) ) :
|
259 |
-
if ( $modal_options['moove_gdpr_plugin_font_type']
|
260 |
$css_file = 'gdpr-main.css';
|
261 |
-
elseif ( $modal_options['moove_gdpr_plugin_font_type']
|
262 |
$css_file = 'gdpr-main-nf.css';
|
263 |
else :
|
264 |
-
$css_file = isset( $modal_options['moove_gdpr_plugin_font_family'] ) && $modal_options['moove_gdpr_plugin_font_family'] && strpos( strtolower( $modal_options['moove_gdpr_plugin_font_family'] ), 'nunito' )
|
265 |
endif;
|
266 |
endif;
|
267 |
wp_enqueue_style( 'moove_gdpr_frontend', plugins_url( basename( dirname( __FILE__ ) ) ) . '/dist/styles/' . $css_file, '', MOOVE_GDPR_VERSION );
|
@@ -295,6 +321,7 @@ class Moove_GDPR_Actions {
|
|
295 |
|
296 |
add_action( 'wp_ajax_moove_hide_update_notice', array( 'Moove_GDPR_Updater', 'moove_hide_update_notice' ) );
|
297 |
|
|
|
298 |
}
|
299 |
|
300 |
/**
|
@@ -309,14 +336,15 @@ class Moove_GDPR_Actions {
|
|
309 |
ob_start();
|
310 |
?>
|
311 |
|
312 |
-
<a href="https://wordpress.org/plugins/gdpr-cookie-compliance" target="_blank" rel="noopener" class='moove-gdpr-branding'><?php echo $powered_label; ?> GDPR <?php
|
313 |
<?php
|
314 |
return ob_get_clean();
|
315 |
}
|
316 |
|
317 |
/**
|
318 |
-
* GDPR Cookie Compliance - Admin Tabs
|
319 |
-
*
|
|
|
320 |
*/
|
321 |
public function gdpr_settings_tab_nav_extensions( $active_tab ) {
|
322 |
$tab_data = array(
|
@@ -356,15 +384,16 @@ class Moove_GDPR_Actions {
|
|
356 |
foreach ( $tab_data as $tab ) :
|
357 |
ob_start();
|
358 |
?>
|
359 |
-
<a href="?page=moove-gdpr&tab=<?php echo $tab['slug']; ?>" class="gdpr-cc-addon nav-tab gdpr-cc-disabled <?php echo $active_tab
|
360 |
-
<?php echo $tab['name']; ?>
|
361 |
</a>
|
362 |
<?php
|
363 |
$content = ob_get_clean();
|
364 |
-
|
|
|
365 |
endforeach;
|
366 |
}
|
367 |
|
368 |
}
|
369 |
-
|
370 |
|
1 |
<?php
|
|
|
|
|
|
|
|
|
2 |
/**
|
3 |
* Moove_GDPR_Actions File Doc Comment
|
4 |
*
|
7 |
* @author Gaspar Nemes
|
8 |
*/
|
9 |
|
10 |
+
if ( ! defined( 'ABSPATH' ) ) :
|
11 |
+
exit;
|
12 |
+
endif; // Exit if accessed directly.
|
13 |
+
|
14 |
/**
|
15 |
* Moove_GDPR_Actions Class Doc Comment
|
16 |
*
|
19 |
* @author Gaspar Nemes
|
20 |
*/
|
21 |
class Moove_GDPR_Actions {
|
22 |
+
|
23 |
/**
|
24 |
* Global variable used in localization
|
25 |
*
|
26 |
+
* @var $gdpr_loc_data Localization variable
|
27 |
*/
|
28 |
+
public $gdpr_loc_data;
|
29 |
/**
|
30 |
* Construct
|
31 |
*/
|
32 |
+
public function __construct() {
|
33 |
$this->moove_register_scripts();
|
34 |
$this->moove_register_ajax_actions();
|
35 |
add_action( 'gdpr_cookie_filter_settings', array( &$this, 'gdpr_remove_cached_scripts' ) );
|
36 |
add_action( 'gdpr_settings_tab_nav_extensions', array( &$this, 'gdpr_settings_tab_nav_extensions' ), 10, 1 );
|
37 |
add_action( 'gdpr_check_extensions', array( &$this, 'gdpr_check_extensions' ), 10, 2 );
|
38 |
add_action( 'gdpr_premium_section_ads', array( &$this, 'gdpr_premium_section_ads' ) );
|
|
|
39 |
add_action( 'gdpr_tab_cbm_ph', array( &$this, 'gdpr_premium_section_ads' ) );
|
40 |
add_action( 'gdpr_tab_cbm_ps', array( &$this, 'gdpr_premium_section_ads' ) );
|
41 |
add_action( 'gdpr_get_alertbox', array( 'Moove_GDPR_Content', 'gdpr_get_alertbox' ), 10, 3 );
|
42 |
add_action( 'gdpr_licence_input_field', array( 'Moove_GDPR_Content', 'gdpr_licence_input_field' ), 10, 2 );
|
43 |
add_action( 'gdpr_licence_action_button', array( 'Moove_GDPR_Content', 'gdpr_licence_action_button' ), 10, 2 );
|
44 |
add_action( 'gdpr_premium_update_alert', array( 'Moove_GDPR_Content', 'gdpr_premium_update_alert' ) );
|
|
|
45 |
add_action( 'gdpr_cdn_url', array( &$this, 'gdpr_cdn_base_url' ), 10, 1 );
|
46 |
add_action( 'gdpr_info_bar_button_extensions', array( &$this, 'gdpr_info_add_reject_button_extensions' ) );
|
47 |
add_action( 'gdpr_support_sidebar_class', array( &$this, 'gdpr_support_sidebar_class' ), 10, 1 );
|
|
|
48 |
$gdpr_default_content = new Moove_GDPR_Content();
|
49 |
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
50 |
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
51 |
if ( $gdpr_key && ! isset( $gdpr_key['deactivation'] ) ) :
|
52 |
do_action( 'gdpr_plugin_loaded' );
|
53 |
endif;
|
54 |
+
add_action( 'gdpr_cc_keephtml', array( &$this, 'gdpr_cc_keephtml' ), 10, 2 );
|
55 |
+
|
56 |
+
add_action( 'wp_footer', array( 'Moove_GDPR_Controller', 'moove_gdpr_cookie_popup_modal' ), 99 );
|
57 |
+
add_action( 'admin_init', array( 'Moove_GDPR_Controller', 'moove_gdpr_add_editor_styles' ) );
|
58 |
+
add_action( 'wp_footer', array( 'Moove_GDPR_Controller', 'moove_gdpr_cookie_popup_info' ) );
|
59 |
}
|
60 |
|
61 |
/**
|
62 |
* Extra class for admin sidebar widgets
|
63 |
+
*
|
64 |
+
* @param string $class Class name.
|
65 |
+
* @return string $class
|
66 |
*/
|
|
|
67 |
public function gdpr_support_sidebar_class( $class ) {
|
68 |
if ( class_exists( 'Moove_GDPR_Addon_View' ) ) :
|
69 |
$class = 'm-plugin-box-highlighted';
|
71 |
return $class;
|
72 |
}
|
73 |
|
74 |
+
/**
|
75 |
+
* Sanitize filter allowing html tags and styles with attributes
|
76 |
+
*
|
77 |
+
* @param string $content Content.
|
78 |
+
* @param boolean $echo Option echo the value or return.
|
79 |
+
*/
|
80 |
+
public function gdpr_cc_keephtml( $content, $echo = false ) {
|
81 |
+
if ( $echo ) :
|
82 |
+
echo $content;
|
83 |
+
else :
|
84 |
+
return $content;
|
85 |
+
endif;
|
86 |
+
}
|
87 |
+
|
88 |
/**
|
89 |
* Reject button extension, will be listed next to the Accept button if it's enabled in the CMS
|
90 |
*/
|
95 |
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
96 |
if ( isset( $modal_options['moove_gdpr_reject_button_enable'] ) && intval( $modal_options['moove_gdpr_reject_button_enable'] ) === 1 ) :
|
97 |
$button_label = isset( $modal_options[ 'moove_gdpr_infobar_reject_button_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_infobar_reject_button_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_infobar_reject_button_label' . $wpml_lang ] : __( 'Reject', 'gdpr-cookie-compliance-addon' );
|
98 |
+
?>
|
99 |
+
<button class="mgbutton moove-gdpr-infobar-reject-btn"><?php echo esc_attr( $button_label ); ?></button>
|
100 |
+
<?php
|
101 |
endif;
|
102 |
+
}
|
103 |
|
104 |
/**
|
105 |
* CDN base URL for lity lightbox
|
106 |
+
*
|
107 |
+
* @param string $plugin_url Plugin URL.
|
108 |
*/
|
109 |
public function gdpr_cdn_base_url( $plugin_url ) {
|
110 |
$gdpr_default_content = new Moove_GDPR_Content();
|
126 |
public function gdpr_premium_section_ads() {
|
127 |
|
128 |
if ( class_exists( 'Moove_GDPR_Addon_View' ) ) :
|
129 |
+
wp_verify_nonce( 'gdpr_nonce', 'gdpr_cookie_compliance_nonce' );
|
130 |
+
$slug = isset( $_GET['tab'] ) ? sanitize_text_field( wp_unslash( $_GET['tab'] ) ) : false;
|
131 |
+
$licence_manager = new Moove_GDPR_License_Manager();
|
132 |
+
$add_on_slug = $licence_manager->get_add_on_plugin_slug();
|
133 |
+
$view_path = $add_on_slug ? WP_PLUGIN_DIR . '/' . plugin_dir_path( $add_on_slug ) . '/views/moove/admin/settings/' . $slug .'.php' : false;
|
134 |
+
|
135 |
+
$view_content = $slug && $view_path ? file_exists( $view_path ) : false;
|
136 |
|
137 |
+
if ( ! $view_content && $slug && 'help' !== $slug ) :
|
138 |
?>
|
139 |
<div class="gdpr-locked-section">
|
140 |
<span>
|
141 |
<i class="dashicons dashicons-lock"></i>
|
142 |
<h4>This feature is not supported in this version of the Premium Add-on.</h4>
|
143 |
+
<p><strong><a href="<?php echo esc_url( admin_url( 'admin.php' ) ); ?>?page=moove-gdpr&tab=licence" class="gdpr_admin_link">Activate your licence</a> to download the latest version of the Premium Add-on.</strong></p>
|
144 |
+
<p class="gdpr_license_info">Don’t have a valid licence key yet? <br><a href="<?php echo esc_url( MOOVE_SHOP_URL ); ?>/my-account" target="_blank" class="gdpr_admin_link">Login to your account</a> to generate the key or <a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" class="gdpr_admin_link" target="_blank">buy a new licence here</a>.</p>
|
|
|
|
|
145 |
<br />
|
146 |
|
147 |
<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="plugin-buy-now-btn">Buy Now</a>
|
163 |
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
164 |
?>
|
165 |
<?php if ( isset( $gdpr_key['deactivation'] ) || $gdpr_key['activation'] ) : ?>
|
166 |
+
<p><strong><a href="<?php echo esc_url( admin_url( 'admin.php' ) ); ?>?page=moove-gdpr&tab=licence" class="gdpr_admin_link">Activate your licence</a> or <a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" class="gdpr_admin_link" target="_blank">buy a new licence here</a></strong></p>
|
167 |
<?php else : ?>
|
168 |
+
<p><strong>Do you have a licence key? <br />Insert your license key to the "<a href="<?php echo esc_url( admin_url( 'admin.php' ) ); ?>?page=moove-gdpr&tab=licence" class="gdpr_admin_link">Licence Manager</a>" and activate it.</strong></p>
|
169 |
|
170 |
<?php endif; ?>
|
171 |
<br />
|
177 |
<!-- .gdpr-locked-section -->
|
178 |
<?php
|
179 |
endif;
|
180 |
+
}
|
181 |
|
182 |
/**
|
183 |
* Checking for Premium Add-on installed and activated
|
184 |
+
*
|
185 |
+
* @param string $content Content.
|
186 |
+
* @param string $slug Slug.
|
187 |
*/
|
188 |
public function gdpr_check_extensions( $content, $slug ) {
|
189 |
$return = $content;
|
190 |
if ( class_exists( 'Moove_GDPR_Addon_View' ) ) :
|
191 |
+
$licence_manager = new Moove_GDPR_License_Manager();
|
192 |
+
$add_on_slug = $licence_manager->get_add_on_plugin_slug();
|
193 |
+
$view_path = $add_on_slug ? WP_PLUGIN_DIR . '/' . plugin_dir_path( $add_on_slug ) . '/views/moove/admin/settings/' . $slug .'.php' : false;
|
194 |
+
$view_content = $slug && $view_path ? file_exists( $view_path ) : false;
|
195 |
+
if ( ! $view_content ) :
|
196 |
+
$return = $return;
|
197 |
else :
|
198 |
$return = '';
|
199 |
endif;
|
236 |
$force_reload = $force_reload ? 'true' : 'false';
|
237 |
$geo_location_enabled = isset( $modal_options['moove_gdpr_geolocation_eu'] ) && intval( $modal_options['moove_gdpr_geolocation_eu'] ) === 1 ? 'true' : 'false';
|
238 |
|
239 |
+
// By using this filter, you can force the plugin to load the lity lightbox using PHP instead of JavaScript.
|
240 |
+
$load_lity = apply_filters( 'gdpr_enqueue_lity_nojs', true );
|
241 |
+
$load_lity = $load_lity ? 'true' : 'false';
|
242 |
|
243 |
+
$loc_data = array(
|
244 |
'ajaxurl' => admin_url( 'admin-ajax.php' ),
|
245 |
'post_id' => get_the_ID(),
|
246 |
'plugin_dir' => apply_filters( 'gdpr_cdn_url', plugins_url( basename( dirname( __FILE__ ) ) ) ),
|
250 |
'third_party' => isset( $modal_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) && intval( $modal_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) ? intval( $modal_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) : 0,
|
251 |
'advanced' => isset( $modal_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) && intval( $modal_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) ? intval( $modal_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) : 0,
|
252 |
),
|
253 |
+
'geo_location' => $geo_location_enabled,
|
254 |
'force_reload' => $force_reload,
|
255 |
'is_single' => is_single(),
|
256 |
'current_user' => get_current_user_id(),
|
257 |
+
'load_lity' => $load_lity,
|
258 |
);
|
259 |
+
$this->gdpr_loc_data = apply_filters( 'gdpr_extend_loc_data', $loc_data );
|
260 |
wp_localize_script( $ascript, 'moove_frontend_gdpr_scripts', $this->gdpr_loc_data );
|
261 |
|
262 |
}
|
282 |
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
283 |
$css_file = 'gdpr-main.css';
|
284 |
if ( isset( $modal_options['moove_gdpr_plugin_font_type'] ) ) :
|
285 |
+
if ( '1' === $modal_options['moove_gdpr_plugin_font_type'] ) :
|
286 |
$css_file = 'gdpr-main.css';
|
287 |
+
elseif ( '2' === $modal_options['moove_gdpr_plugin_font_type'] ) :
|
288 |
$css_file = 'gdpr-main-nf.css';
|
289 |
else :
|
290 |
+
$css_file = isset( $modal_options['moove_gdpr_plugin_font_family'] ) && $modal_options['moove_gdpr_plugin_font_family'] && false === strpos( strtolower( $modal_options['moove_gdpr_plugin_font_family'] ), 'nunito' ) ? 'gdpr-main-nf.css' : 'gdpr-main.css';
|
291 |
endif;
|
292 |
endif;
|
293 |
wp_enqueue_style( 'moove_gdpr_frontend', plugins_url( basename( dirname( __FILE__ ) ) ) . '/dist/styles/' . $css_file, '', MOOVE_GDPR_VERSION );
|
321 |
|
322 |
add_action( 'wp_ajax_moove_hide_update_notice', array( 'Moove_GDPR_Updater', 'moove_hide_update_notice' ) );
|
323 |
|
324 |
+
add_action( 'wp_ajax_gdpr_cookie_compliance_reset_settings', array( 'Moove_GDPR_Controller', 'gdpr_cookie_compliance_reset_settings' ) );
|
325 |
}
|
326 |
|
327 |
/**
|
336 |
ob_start();
|
337 |
?>
|
338 |
|
339 |
+
<a href="https://wordpress.org/plugins/gdpr-cookie-compliance" target="_blank" rel="noopener" class='moove-gdpr-branding'><?php echo esc_attr( $powered_label ); ?> GDPR <?php esc_attr_e( 'plugin', 'gdpr-cookie-compliance' ); ?></a>
|
340 |
<?php
|
341 |
return ob_get_clean();
|
342 |
}
|
343 |
|
344 |
/**
|
345 |
+
* GDPR Cookie Compliance - Admin Tabs - Routing & views
|
346 |
+
*
|
347 |
+
* @param string $active_tab Active tab.
|
348 |
*/
|
349 |
public function gdpr_settings_tab_nav_extensions( $active_tab ) {
|
350 |
$tab_data = array(
|
384 |
foreach ( $tab_data as $tab ) :
|
385 |
ob_start();
|
386 |
?>
|
387 |
+
<a href="?page=moove-gdpr&tab=<?php echo esc_attr( $tab['slug'] ); ?>" class="gdpr-cc-addon nav-tab gdpr-cc-disabled <?php echo $active_tab === $tab['slug'] ? 'nav-tab-active' : ''; ?>">
|
388 |
+
<?php echo esc_attr( $tab['name'] ); ?>
|
389 |
</a>
|
390 |
<?php
|
391 |
$content = ob_get_clean();
|
392 |
+
$content = apply_filters( 'gdpr_check_extensions', $content, $tab['slug'] );
|
393 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
394 |
endforeach;
|
395 |
}
|
396 |
|
397 |
}
|
398 |
+
new Moove_GDPR_Actions();
|
399 |
|
class-moove-gdpr-content.php
ADDED
@@ -0,0 +1,498 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Moove_GDPR_Content File Doc Comment
|
4 |
+
*
|
5 |
+
* @category Moove_GDPR_Content
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
11 |
+
exit;
|
12 |
+
} // Exit if accessed directly
|
13 |
+
|
14 |
+
|
15 |
+
/**
|
16 |
+
* Moove_GDPR_Content Class Doc Comment
|
17 |
+
*
|
18 |
+
* @category Class
|
19 |
+
* @package Moove_Controller
|
20 |
+
* @author Gaspar Nemes
|
21 |
+
*/
|
22 |
+
class Moove_GDPR_Content {
|
23 |
+
|
24 |
+
/**
|
25 |
+
* Construct
|
26 |
+
*/
|
27 |
+
public function __construct() {
|
28 |
+
|
29 |
+
}
|
30 |
+
|
31 |
+
/**
|
32 |
+
* Privacy Overview Tab Content
|
33 |
+
*
|
34 |
+
* @return string Filtered Content
|
35 |
+
*/
|
36 |
+
public function moove_gdpr_get_privacy_overview_content() {
|
37 |
+
$_content = '<p>' . __( 'This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.', 'gdpr-cookie-compliance' ) . '</p>';
|
38 |
+
return $_content;
|
39 |
+
}
|
40 |
+
|
41 |
+
/**
|
42 |
+
* JavaScript localize extension
|
43 |
+
*/
|
44 |
+
public static function moove_gdpr_get_localize_scripts() {
|
45 |
+
$loc_data = array();
|
46 |
+
$gdpr_loc_data = apply_filters( 'gdpr_extend_loc_data', $loc_data );
|
47 |
+
return $gdpr_loc_data;
|
48 |
+
}
|
49 |
+
|
50 |
+
/**
|
51 |
+
* Strict Necessary Tab Content
|
52 |
+
*
|
53 |
+
* @return string Filtered Content
|
54 |
+
*/
|
55 |
+
public function moove_gdpr_get_strict_necessary_content() {
|
56 |
+
$_content = '<p>' . __( 'Strictly Necessary Cookie should be enabled at all times so that we can save your preferences for cookie settings.', 'gdpr-cookie-compliance' ) . '</p>';
|
57 |
+
return $_content;
|
58 |
+
}
|
59 |
+
|
60 |
+
/**
|
61 |
+
* Strict Necessary Warning Message
|
62 |
+
*
|
63 |
+
* @return string Filtered Content
|
64 |
+
*/
|
65 |
+
public function moove_gdpr_get_strict_necessary_warning() {
|
66 |
+
$_content = '';
|
67 |
+
$options_name = $this->moove_gdpr_get_option_name();
|
68 |
+
$gdpr_options = get_option( $options_name );
|
69 |
+
$wpml_lang_options = $this->moove_gdpr_get_wpml_lang();
|
70 |
+
|
71 |
+
if ( ! isset( $gdpr_options[ 'moove_gdpr_strictly_necessary_cookies_warning' . $wpml_lang_options ] ) ) :
|
72 |
+
$_content = __( 'If you disable this cookie, we will not be able to save your preferences. This means that every time you visit this website you will need to enable or disable cookies again.', 'gdpr-cookie-compliance' );
|
73 |
+
endif;
|
74 |
+
return $_content;
|
75 |
+
}
|
76 |
+
|
77 |
+
/**
|
78 |
+
* Advanced Cookies Tab Content
|
79 |
+
*
|
80 |
+
* @return string Filtered Content
|
81 |
+
*/
|
82 |
+
public function moove_gdpr_get_advanced_cookies_content() {
|
83 |
+
$_content = '<p>' . __( 'This website uses the following additional cookies:</p><p>(List the cookies that you are using on the website here.)', 'gdpr-cookie-compliance' ) . '</p>';
|
84 |
+
return $_content;
|
85 |
+
}
|
86 |
+
|
87 |
+
/**
|
88 |
+
* Third Party Cookies Tab Content
|
89 |
+
*
|
90 |
+
* @return string Filtered Content
|
91 |
+
*/
|
92 |
+
public function moove_gdpr_get_third_party_content() {
|
93 |
+
$_content = '<p>' . __( 'This website uses Google Analytics to collect anonymous information such as the number of visitors to the site, and the most popular pages.', 'gdpr-cookie-compliance' );
|
94 |
+
$_content .= '<p>' . __( 'Keeping this cookie enabled helps us to improve our website.', 'gdpr-cookie-compliance' ) . '</p>';
|
95 |
+
return $_content;
|
96 |
+
}
|
97 |
+
|
98 |
+
/**
|
99 |
+
* Cookie Policy Tab Content
|
100 |
+
*
|
101 |
+
* @return string Filtered Content
|
102 |
+
*/
|
103 |
+
public function moove_gdpr_get_cookie_policy_content() {
|
104 |
+
$privacy_policy_page = get_option( 'wp_page_for_privacy_policy' );
|
105 |
+
$privacy_policy_link = $privacy_policy_page ? esc_url( get_permalink( $privacy_policy_page ) ) : false;
|
106 |
+
$privacy_policy_link = $privacy_policy_link ? $privacy_policy_link : '#';
|
107 |
+
|
108 |
+
$_content = '<p>' . sprintf( __( 'More information about our [privacy_link]Cookie Policy[/privacy_link]', 'gdpr-cookie-compliance' ), $privacy_policy_link ) . '</p>';
|
109 |
+
$_content = str_replace( '[privacy_link]', '<a href="' . $privacy_policy_link . '" target="_blank">', $_content );
|
110 |
+
$_content = str_replace( '[/privacy_link]', '</a>', $_content );
|
111 |
+
|
112 |
+
return $_content;
|
113 |
+
}
|
114 |
+
|
115 |
+
/**
|
116 |
+
* Cookie Policy Tab Content
|
117 |
+
*
|
118 |
+
* @return string Filtered Content
|
119 |
+
*/
|
120 |
+
public function moove_gdpr_ifb_content() {
|
121 |
+
$_content = '<h2>' . __( 'Sorry,<br /> the content is blocked!', 'gdpr-cookie-compliance' );
|
122 |
+
$_content .= '<p>' . __( 'To unlock, please enable the cookies!', 'gdpr-cookie-compliance' );
|
123 |
+
$_content .= '<br><br>';
|
124 |
+
$_content .= __( '[accept]Accept[/accept] [setting]Adjust your settings[/setting]', 'gdpr-cookie-compliance' );
|
125 |
+
return $_content;
|
126 |
+
}
|
127 |
+
|
128 |
+
|
129 |
+
|
130 |
+
/**
|
131 |
+
* Get option name
|
132 |
+
*/
|
133 |
+
public function moove_gdpr_get_option_name() {
|
134 |
+
return 'moove_gdpr_plugin_settings';
|
135 |
+
}
|
136 |
+
|
137 |
+
/**
|
138 |
+
* Get option name
|
139 |
+
*/
|
140 |
+
public function moove_gdpr_get_key_name() {
|
141 |
+
return 'moove_gdpr_plugin_key';
|
142 |
+
}
|
143 |
+
|
144 |
+
/**
|
145 |
+
* Get strict secondary notice
|
146 |
+
*/
|
147 |
+
public function moove_gdpr_get_secondary_notice() {
|
148 |
+
$_content = '';
|
149 |
+
$options_name = $this->moove_gdpr_get_option_name();
|
150 |
+
$gdpr_options = get_option( $options_name );
|
151 |
+
$wpml_lang_options = $this->moove_gdpr_get_wpml_lang();
|
152 |
+
if ( ! isset( $gdpr_options[ 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang_options ] ) ) :
|
153 |
+
$_content = __( 'Please enable Strictly Necessary Cookies first so that we can save your preferences!', 'gdpr-cookie-compliance' );
|
154 |
+
endif;
|
155 |
+
return $_content;
|
156 |
+
}
|
157 |
+
|
158 |
+
/**
|
159 |
+
* Get WMPL language code
|
160 |
+
*/
|
161 |
+
public function moove_gdpr_get_wpml_lang() {
|
162 |
+
if ( defined( 'ICL_LANGUAGE_CODE' ) ) {
|
163 |
+
$language_code = ICL_LANGUAGE_CODE;
|
164 |
+
if ( ICL_LANGUAGE_CODE === 'all' ) :
|
165 |
+
if ( function_exists( 'pll_default_language' ) ) :
|
166 |
+
$language_code = pll_default_language();
|
167 |
+
elseif ( class_exists( 'SitePress' ) ) :
|
168 |
+
global $sitepress;
|
169 |
+
$language_code = $sitepress->get_default_language();
|
170 |
+
endif;
|
171 |
+
endif;
|
172 |
+
return '_' . $language_code;
|
173 |
+
} elseif ( isset( $GLOBALS['q_config']['language'] ) ) {
|
174 |
+
return $GLOBALS['q_config']['language'];
|
175 |
+
} elseif ( function_exists( 'wpm_get_user_language' ) ) {
|
176 |
+
return wpm_get_user_language();
|
177 |
+
}
|
178 |
+
return '';
|
179 |
+
}
|
180 |
+
|
181 |
+
/**
|
182 |
+
* Licence token
|
183 |
+
*/
|
184 |
+
public function get_license_token() {
|
185 |
+
$license_token = function_exists( 'network_site_url' ) ? network_site_url( '/' ) : home_url( '/' );
|
186 |
+
return $license_token;
|
187 |
+
}
|
188 |
+
|
189 |
+
/**
|
190 |
+
* PHP Cookie Checker, available from version 1.3.0
|
191 |
+
*/
|
192 |
+
public function gdpr_get_php_cookies() {
|
193 |
+
$cookies_accepted = array(
|
194 |
+
'strict' => false,
|
195 |
+
'thirdparty' => false,
|
196 |
+
'advanced' => false,
|
197 |
+
);
|
198 |
+
if ( isset( $_COOKIE['moove_gdpr_popup'] ) ) :
|
199 |
+
$cookies = sanitize_text_field( wp_unslash( $_COOKIE['moove_gdpr_popup'] ) );
|
200 |
+
$cookies_decoded = json_decode( wp_unslash( $cookies ), true );
|
201 |
+
if ( $cookies_decoded && is_array( $cookies_decoded ) && ! empty( $cookies_decoded ) ) :
|
202 |
+
$cookies_accepted = array(
|
203 |
+
'strict' => isset( $cookies_decoded['strict'] ) && intval( $cookies_decoded['strict'] ) === 1 ? true : false,
|
204 |
+
'thirdparty' => isset( $cookies_decoded['thirdparty'] ) && intval( $cookies_decoded['thirdparty'] ) === 1 ? true : false,
|
205 |
+
'advanced' => isset( $cookies_decoded['advanced'] ) && intval( $cookies_decoded['advanced'] ) === 1 ? true : false,
|
206 |
+
);
|
207 |
+
endif;
|
208 |
+
else :
|
209 |
+
$options_name = $this->moove_gdpr_get_option_name();
|
210 |
+
$gdpr_options = get_option( $options_name );
|
211 |
+
$wpml_lang_options = $this->moove_gdpr_get_wpml_lang();
|
212 |
+
|
213 |
+
$strictly_functionality = isset( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? intval( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) : 1;
|
214 |
+
$thirdparty_default = isset( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) && intval( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) ? intval( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) : 0;
|
215 |
+
$advanced_default = isset( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) && intval( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) ? intval( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) : 0;
|
216 |
+
|
217 |
+
if ( 1 === $strictly_functionality ) :
|
218 |
+
if ( 1 === $thirdparty_default || 1 === $advanced_default ) :
|
219 |
+
$strict_default = 1;
|
220 |
+
else :
|
221 |
+
$strict_default = 0;
|
222 |
+
endif;
|
223 |
+
else :
|
224 |
+
$strict_default = 1;
|
225 |
+
endif;
|
226 |
+
|
227 |
+
$cookies_accepted = array(
|
228 |
+
'strict' => $strict_default,
|
229 |
+
'thirdparty' => $thirdparty_default,
|
230 |
+
'advanced' => $advanced_default,
|
231 |
+
);
|
232 |
+
|
233 |
+
endif;
|
234 |
+
return $cookies_accepted;
|
235 |
+
}
|
236 |
+
|
237 |
+
/**
|
238 |
+
* GDPR Licence action button
|
239 |
+
*
|
240 |
+
* @param array $response Response.
|
241 |
+
* @param string $gdpr_key GDPR Key.
|
242 |
+
*/
|
243 |
+
public static function gdpr_licence_action_button( $response, $gdpr_key ) {
|
244 |
+
$type = isset( $response['type'] ) ? $response['type'] : false;
|
245 |
+
if ( 'expired' === $type || 'activated' === $type || 'max_activation_reached' === $type ) :
|
246 |
+
?>
|
247 |
+
<button type="submit" name="gdpr_activate_license" class="button button-primary button-inverse">
|
248 |
+
<?php esc_html_e( 'Activate', 'gdpr-cookie-compliance' ); ?>
|
249 |
+
</button>
|
250 |
+
<?php
|
251 |
+
elseif ( 'invalid' === $type ) :
|
252 |
+
?>
|
253 |
+
<button type="submit" name="gdpr_activate_license" class="button button-primary button-inverse">
|
254 |
+
<?php esc_html_e( 'Activate', 'gdpr-cookie-compliance' ); ?>
|
255 |
+
</button>
|
256 |
+
<?php
|
257 |
+
else :
|
258 |
+
?>
|
259 |
+
<button type="submit" name="gdpr_activate_license" class="button button-primary button-inverse">
|
260 |
+
<?php esc_html_e( 'Activate', 'gdpr-cookie-compliance' ); ?>
|
261 |
+
</button>
|
262 |
+
<br /><br />
|
263 |
+
<hr />
|
264 |
+
<h4 style="margin-bottom: 0;"><?php esc_html_e( 'Buy licence', 'gdpr-cookie-compliance' ); ?></h4>
|
265 |
+
<p>
|
266 |
+
<?php
|
267 |
+
$store_link = __( 'You can buy licences from our [store_link]online store[/store_link].', 'gdpr-cookie-compliance' );
|
268 |
+
$store_link = str_replace( '[store_link]', '<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="gdpr_admin_link">', $store_link );
|
269 |
+
$store_link = str_replace( '[/store_link]', '</a>', $store_link );
|
270 |
+
apply_filters( 'gdpr_cc_keephtml', $store_link, true );
|
271 |
+
?>
|
272 |
+
</p>
|
273 |
+
<p>
|
274 |
+
<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="button button-primary">Buy Now</a>
|
275 |
+
</p>
|
276 |
+
<br />
|
277 |
+
<hr />
|
278 |
+
<?php
|
279 |
+
endif;
|
280 |
+
}
|
281 |
+
|
282 |
+
/**
|
283 |
+
* Licence input key
|
284 |
+
*
|
285 |
+
* @param array $response Response.
|
286 |
+
* @param string $gdpr_key GDPR Key.
|
287 |
+
*/
|
288 |
+
public static function gdpr_licence_input_field( $response, $gdpr_key ) {
|
289 |
+
$type = isset( $response['type'] ) ? $response['type'] : false;
|
290 |
+
if ( 'expired' === $type ) :
|
291 |
+
// LICENSE EXPIRED.
|
292 |
+
?>
|
293 |
+
<tr>
|
294 |
+
<th scope="row" style="padding: 0 0 10px 0;">
|
295 |
+
<hr />
|
296 |
+
<h4 style="margin-bottom: 0;"><?php esc_html_e( 'Renew your licence', 'gdpr-cookie-compliance' ); ?></h4>
|
297 |
+
<p><?php esc_html_e( 'Your licence has expired. You will not receive the latest updates and features unless you renew your licence.', 'gdpr-cookie-compliance' ); ?></p>
|
298 |
+
<a href="<?php echo esc_attr( MOOVE_SHOP_URL ); ?>?renew=<?php echo esc_attr( $response['key'] ); ?>" class="button button-primary">Renew Licence</a>
|
299 |
+
<br /><br />
|
300 |
+
<hr />
|
301 |
+
|
302 |
+
<h4 style="margin-bottom: 0;"><?php esc_html_e( 'Enter new licence key', 'gdpr-cookie-compliance' ); ?></h4>
|
303 |
+
</th>
|
304 |
+
</tr>
|
305 |
+
<tr>
|
306 |
+
<td style="padding: 0;">
|
307 |
+
<input name="moove_gdpr_license_key" required min="35" type="text" id="moove_gdpr_license_key" value="" class="regular-text">
|
308 |
+
</td>
|
309 |
+
</tr>
|
310 |
+
<?php
|
311 |
+
elseif ( 'activated' === $type || 'max_activation_reached' === $type ) :
|
312 |
+
// LICENSE ACTIVATED.
|
313 |
+
?>
|
314 |
+
<tr>
|
315 |
+
<th scope="row" style="padding: 0 0 10px 0;">
|
316 |
+
<hr />
|
317 |
+
<h4 style="margin-bottom: 0;"><?php esc_html_e( 'Buy more licences', 'gdpr-cookie-compliance' ); ?></h4>
|
318 |
+
<p>
|
319 |
+
<?php
|
320 |
+
$store_link = __( 'You can buy more licences from our [store_link]online store[/store_link].', 'gdpr-cookie-compliance' );
|
321 |
+
$store_link = str_replace( '[store_link]', '<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="gdpr_admin_link">', $store_link );
|
322 |
+
$store_link = str_replace( '[/store_link]', '</a>', $store_link );
|
323 |
+
apply_filters( 'gdpr_cc_keephtml', $store_link, true );
|
324 |
+
?>
|
325 |
+
</p>
|
326 |
+
<p>
|
327 |
+
<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="button button-primary">
|
328 |
+
Buy Now
|
329 |
+
</a>
|
330 |
+
</p>
|
331 |
+
<br />
|
332 |
+
<hr />
|
333 |
+
<h4 style="margin-bottom: 0;"><?php esc_html_e( 'Enter new licence key', 'gdpr-cookie-compliance' ); ?></h4>
|
334 |
+
</th>
|
335 |
+
</tr>
|
336 |
+
<tr>
|
337 |
+
<td style="padding: 0;">
|
338 |
+
<input name="moove_gdpr_license_key" required min="35" type="text" id="moove_gdpr_license_key" value="" class="regular-text">
|
339 |
+
</td>
|
340 |
+
</tr>
|
341 |
+
<?php
|
342 |
+
elseif ( 'invalid' === $type ) :
|
343 |
+
?>
|
344 |
+
<tr>
|
345 |
+
<th scope="row" style="padding: 0 0 10px 0;">
|
346 |
+
<hr />
|
347 |
+
<h4 style="margin-bottom: 0;"><?php esc_html_e( 'Buy licence', 'gdpr-cookie-compliance' ); ?></h4>
|
348 |
+
<p>
|
349 |
+
<?php
|
350 |
+
$store_link = __( 'You can buy licences from our [store_link]online store[/store_link].', 'gdpr-cookie-compliance' );
|
351 |
+
$store_link = str_replace( '[store_link]', '<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="gdpr_admin_link">', $store_link );
|
352 |
+
$store_link = str_replace( '[/store_link]', '</a>', $store_link );
|
353 |
+
apply_filters( 'gdpr_cc_keephtml', $store_link, true );
|
354 |
+
?>
|
355 |
+
</p>
|
356 |
+
<p>
|
357 |
+
<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="button button-primary">Buy Now</a>
|
358 |
+
</p>
|
359 |
+
<br />
|
360 |
+
<hr />
|
361 |
+
</th>
|
362 |
+
</tr>
|
363 |
+
<tr>
|
364 |
+
<th scope="row" style="padding: 0 0 10px 0;">
|
365 |
+
<label><?php esc_html_e( 'Enter your licence key:', 'gdpr-cookie-compliance' ); ?></label>
|
366 |
+
</th>
|
367 |
+
</tr>
|
368 |
+
<tr>
|
369 |
+
<td style="padding: 0;">
|
370 |
+
<input name="moove_gdpr_license_key" required min="35" type="text" id="moove_gdpr_license_key" value="" class="regular-text">
|
371 |
+
</td>
|
372 |
+
</tr>
|
373 |
+
<?php
|
374 |
+
else :
|
375 |
+
?>
|
376 |
+
<tr>
|
377 |
+
<th scope="row" style="padding: 0 0 10px 0;">
|
378 |
+
<label><?php esc_html_e( 'Enter licence key:', 'gdpr-cookie-compliance' ); ?></label>
|
379 |
+
</th>
|
380 |
+
</tr>
|
381 |
+
<tr>
|
382 |
+
<td style="padding: 0;">
|
383 |
+
<input name="moove_gdpr_license_key" required min="35" type="text" id="moove_gdpr_license_key" value="" class="regular-text">
|
384 |
+
</td>
|
385 |
+
</tr>
|
386 |
+
<?php
|
387 |
+
endif;
|
388 |
+
}
|
389 |
+
|
390 |
+
/**
|
391 |
+
* GDPR Alert Box
|
392 |
+
*
|
393 |
+
* @param string $type Type.
|
394 |
+
* @param array $response Response.
|
395 |
+
* @param string $gdpr_key GDPR Key.
|
396 |
+
*/
|
397 |
+
public static function gdpr_get_alertbox( $type, $response, $gdpr_key ) {
|
398 |
+
if ( 'error' === $type ) :
|
399 |
+
$messages = isset( $response['message'] ) && is_array( $response['message'] ) ? implode( '</p><p>', $response['message'] ) : '';
|
400 |
+
if ( $response['type'] === 'inactive' ) :
|
401 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
402 |
+
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
403 |
+
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
404 |
+
if ( function_exists( 'update_site_option' ) ) :
|
405 |
+
update_site_option(
|
406 |
+
$option_key,
|
407 |
+
array(
|
408 |
+
'key' => $response['key'],
|
409 |
+
'deactivation' => strtotime( 'now' ),
|
410 |
+
)
|
411 |
+
);
|
412 |
+
else :
|
413 |
+
update_option(
|
414 |
+
$option_key,
|
415 |
+
array(
|
416 |
+
'key' => $response['key'],
|
417 |
+
'deactivation' => strtotime( 'now' ),
|
418 |
+
)
|
419 |
+
);
|
420 |
+
endif;
|
421 |
+
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
422 |
+
endif;
|
423 |
+
?>
|
424 |
+
<div class="gdpr-admin-alert gdpr-admin-alert-error">
|
425 |
+
<div class="gdpr-alert-content">
|
426 |
+
<p>License key: <strong><?php echo esc_attr( isset( $response['key'] ) ? $response['key'] : $gdpr_key['key'] ); ?></strong></p>
|
427 |
+
<p><?php apply_filters( 'gdpr_cc_keephtml', $messages, true ); ?></p>
|
428 |
+
</div>
|
429 |
+
<span class="dashicons dashicons-dismiss"></span>
|
430 |
+
</div>
|
431 |
+
<!-- .gdpr-admin-alert gdpr-admin-alert-success -->
|
432 |
+
<?php
|
433 |
+
else :
|
434 |
+
$messages = isset( $response['message'] ) && is_array( $response['message'] ) ? implode( '</p><p>', $response['message'] ) : '';
|
435 |
+
?>
|
436 |
+
<div class="gdpr-admin-alert gdpr-admin-alert-success">
|
437 |
+
<div class="gdpr-alert-content">
|
438 |
+
<p>License key: <strong><?php echo esc_attr( isset( $response['key'] ) ? $response['key'] : $gdpr_key['key'] ); ?></strong></p>
|
439 |
+
<p><?php apply_filters( 'gdpr_cc_keephtml', $messages, true ); ?></p>
|
440 |
+
</div>
|
441 |
+
<span class="dashicons dashicons-yes-alt"></span>
|
442 |
+
</div>
|
443 |
+
<!-- .gdpr-admin-alert gdpr-admin-alert-success -->
|
444 |
+
<?php
|
445 |
+
endif;
|
446 |
+
do_action( 'gdpr_plugin_updater_notice' );
|
447 |
+
}
|
448 |
+
|
449 |
+
/**
|
450 |
+
* GDPR Update Alert
|
451 |
+
*
|
452 |
+
* @return void
|
453 |
+
*/
|
454 |
+
public static function gdpr_premium_update_alert() {
|
455 |
+
|
456 |
+
$plugins = get_site_transient( 'update_plugins' );
|
457 |
+
$lm = new Moove_GDPR_License_Manager();
|
458 |
+
$plugin_slug = $lm->get_add_on_plugin_slug();
|
459 |
+
|
460 |
+
if ( isset( $plugins->response[ $plugin_slug ] ) && is_plugin_active( $plugin_slug ) ) :
|
461 |
+
$version = $plugins->response[ $plugin_slug ]->new_version;
|
462 |
+
|
463 |
+
$current_user = wp_get_current_user();
|
464 |
+
$user_id = isset( $current_user->ID ) ? $current_user->ID : 0;
|
465 |
+
$dismiss = get_option( 'gdpr_hide_update_notice_' . $user_id );
|
466 |
+
|
467 |
+
if ( isset( $plugins->response[ $plugin_slug ]->package ) && ! $plugins->response[ $plugin_slug ]->package ) :
|
468 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
469 |
+
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
470 |
+
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
471 |
+
$license_key = isset( $gdpr_key['key'] ) ? sanitize_text_field( $gdpr_key['key'] ) : false;
|
472 |
+
$renew_link = MOOVE_SHOP_URL . '?renew=' . $license_key;
|
473 |
+
$license_manager = admin_url( 'admin.php' ) . '?page=moove-gdpr&tab=licence';
|
474 |
+
$purchase_link = 'https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/';
|
475 |
+
$notice_text = '';
|
476 |
+
if ( $license_key && isset( $gdpr_key['activation'] ) ) :
|
477 |
+
// Expired.
|
478 |
+
$notice_text = 'Update is not available until you <a href="' . $renew_link . '" target="_blank">renew your licence</a>. You can also update your licence key in the <a href="' . $license_manager . '">Licence Manager</a>.';
|
479 |
+
elseif ( $license_key && isset( $gdpr_key['deactivation'] ) ) :
|
480 |
+
// Deactivated.
|
481 |
+
$notice_text = 'Update is not available until you <a href="' . $purchase_link . '" target="_blank">purchase a licence</a>. You can also update your licence key in the <a href="' . $license_manager . '">Licence Manager</a>.';
|
482 |
+
elseif ( ! $license_key ) :
|
483 |
+
// No license key installed.
|
484 |
+
$notice_text = 'Update is not available until you <a href="' . $purchase_link . '" target="_blank">purchase a licence</a>. You can also update your licence key in the <a href="' . $license_manager . '">Licence Manager</a>.';
|
485 |
+
endif;
|
486 |
+
?>
|
487 |
+
<div class="gdpr-cookie-alert gdpr-cookie-update-alert" style="display: inline-block;">
|
488 |
+
<h4>
|
489 |
+
<?php esc_html_e( 'There is a new version of GDPR Cookie Compliance - Premium Add-On.', 'gdpr-cookie-compliance' ); ?></h4>
|
490 |
+
<p><?php apply_filters( 'gdpr_cc_keephtml', $notice_text, true ); ?></p>
|
491 |
+
</div>
|
492 |
+
<!-- .gdpr-cookie-alert -->
|
493 |
+
<?php
|
494 |
+
endif;
|
495 |
+
endif;
|
496 |
+
}
|
497 |
+
}
|
498 |
+
new Moove_GDPR_Content();
|
moove-options.php → class-moove-gdpr-options.php
RENAMED
@@ -1,6 +1,4 @@
|
|
1 |
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
3 |
-
|
4 |
/**
|
5 |
* Moove_GDPR_Options File Doc Comment
|
6 |
*
|
@@ -9,6 +7,10 @@ if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
|
9 |
* @author Gaspar Nemes
|
10 |
*/
|
11 |
|
|
|
|
|
|
|
|
|
12 |
/**
|
13 |
* Moove_GDPR_Options Class Doc Comment
|
14 |
*
|
@@ -23,10 +25,11 @@ class Moove_GDPR_Options {
|
|
23 |
* @var array
|
24 |
*/
|
25 |
private $options;
|
|
|
26 |
/**
|
27 |
* Construct
|
28 |
*/
|
29 |
-
function __construct() {
|
30 |
add_action( 'admin_menu', array( &$this, 'moove_gdpr_admin_menu' ) );
|
31 |
}
|
32 |
|
@@ -39,10 +42,10 @@ class Moove_GDPR_Options {
|
|
39 |
$gdpr_settings_page = add_menu_page(
|
40 |
'GDPR Cookie', // Page_title.
|
41 |
'GDPR Cookie Compliance', // Menu_title.
|
42 |
-
'manage_options', // Capability.
|
43 |
'moove-gdpr', // Menu_slug.
|
44 |
array( &$this, 'moove_gdpr_settings_page' ), // Function.
|
45 |
-
'dashicons-shield',
|
46 |
90 // Position.
|
47 |
);
|
48 |
add_action( 'load-' . $gdpr_settings_page, array( 'Moove_GDPR_Actions', 'moove_gdpr_admin_scripts' ) );
|
@@ -53,10 +56,11 @@ class Moove_GDPR_Options {
|
|
53 |
* @return void
|
54 |
*/
|
55 |
public function moove_gdpr_settings_page() {
|
56 |
-
$data
|
57 |
$view_cnt = new GDPR_View();
|
58 |
-
|
|
|
59 |
}
|
60 |
|
61 |
}
|
62 |
-
|
1 |
<?php
|
|
|
|
|
2 |
/**
|
3 |
* Moove_GDPR_Options File Doc Comment
|
4 |
*
|
7 |
* @author Gaspar Nemes
|
8 |
*/
|
9 |
|
10 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
11 |
+
exit;
|
12 |
+
} // Exit if accessed directly
|
13 |
+
|
14 |
/**
|
15 |
* Moove_GDPR_Options Class Doc Comment
|
16 |
*
|
25 |
* @var array
|
26 |
*/
|
27 |
private $options;
|
28 |
+
|
29 |
/**
|
30 |
* Construct
|
31 |
*/
|
32 |
+
public function __construct() {
|
33 |
add_action( 'admin_menu', array( &$this, 'moove_gdpr_admin_menu' ) );
|
34 |
}
|
35 |
|
42 |
$gdpr_settings_page = add_menu_page(
|
43 |
'GDPR Cookie', // Page_title.
|
44 |
'GDPR Cookie Compliance', // Menu_title.
|
45 |
+
apply_filters( 'gdpr_options_page_cap', 'manage_options' ), // Capability.
|
46 |
'moove-gdpr', // Menu_slug.
|
47 |
array( &$this, 'moove_gdpr_settings_page' ), // Function.
|
48 |
+
'dashicons-shield', // Icon.
|
49 |
90 // Position.
|
50 |
);
|
51 |
add_action( 'load-' . $gdpr_settings_page, array( 'Moove_GDPR_Actions', 'moove_gdpr_admin_scripts' ) );
|
56 |
* @return void
|
57 |
*/
|
58 |
public function moove_gdpr_settings_page() {
|
59 |
+
$data = array();
|
60 |
$view_cnt = new GDPR_View();
|
61 |
+
$content = $view_cnt->load( 'moove.admin.settings.settings-page', $data );
|
62 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
63 |
}
|
64 |
|
65 |
}
|
66 |
+
new Moove_GDPR_Options();
|
controllers/class-moove-gdpr-controller.php
ADDED
@@ -0,0 +1,471 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Moove_Controller File Doc Comment
|
4 |
+
*
|
5 |
+
* @category Moove_Controller
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
11 |
+
exit;
|
12 |
+
} // Exit if accessed directly
|
13 |
+
|
14 |
+
/**
|
15 |
+
* Moove_Controller Class Doc Comment
|
16 |
+
*
|
17 |
+
* @category Class
|
18 |
+
* @package Moove_Controller
|
19 |
+
* @author Gaspar Nemes
|
20 |
+
*/
|
21 |
+
class Moove_GDPR_Controller {
|
22 |
+
/**
|
23 |
+
* Construct function
|
24 |
+
*/
|
25 |
+
public function __construct() {
|
26 |
+
|
27 |
+
}
|
28 |
+
|
29 |
+
/**
|
30 |
+
* Custom Editor CSS added to GDPR plugin WYSIWYG editors
|
31 |
+
*
|
32 |
+
* @return void
|
33 |
+
*/
|
34 |
+
public static function moove_gdpr_add_editor_styles() {
|
35 |
+
add_editor_style( moove_gdpr_get_plugin_directory_url() . 'dist/styles/custom-editor-style.css' );
|
36 |
+
}
|
37 |
+
|
38 |
+
/**
|
39 |
+
* JavaScript localization script
|
40 |
+
*/
|
41 |
+
public static function moove_gdpr_localize_scripts() {
|
42 |
+
$content_cnt = new Moove_GDPR_Content();
|
43 |
+
echo json_encode( $content_cnt->moove_gdpr_get_localize_scripts() );
|
44 |
+
die();
|
45 |
+
}
|
46 |
+
|
47 |
+
/**
|
48 |
+
* Reading plugin statistics from WordPress.org
|
49 |
+
* - star rating
|
50 |
+
* - downloads & active installations
|
51 |
+
*
|
52 |
+
* @param string $plugin_slug Plugin slug.
|
53 |
+
*/
|
54 |
+
public function get_gdpr_plugin_details( $plugin_slug = '' ) {
|
55 |
+
$plugin_return = false;
|
56 |
+
$wp_repo_plugins = '';
|
57 |
+
$wp_response = '';
|
58 |
+
$wp_version = get_bloginfo( 'version' );
|
59 |
+
$transient = get_transient( 'plugin_info_' . $plugin_slug );
|
60 |
+
if ( $transient ) :
|
61 |
+
$plugin_return = $transient;
|
62 |
+
else :
|
63 |
+
if ( $plugin_slug && $wp_version > 3.8 ) :
|
64 |
+
$args = array(
|
65 |
+
'author' => 'MooveAgency',
|
66 |
+
'fields' => array(
|
67 |
+
'downloaded' => true,
|
68 |
+
'active_installs' => true,
|
69 |
+
'ratings' => true,
|
70 |
+
),
|
71 |
+
);
|
72 |
+
$wp_response = wp_remote_post(
|
73 |
+
'http://api.wordpress.org/plugins/info/1.0/',
|
74 |
+
array(
|
75 |
+
'body' => array(
|
76 |
+
'action' => 'query_plugins',
|
77 |
+
'request' => serialize( (object) $args ),
|
78 |
+
),
|
79 |
+
)
|
80 |
+
);
|
81 |
+
if ( ! is_wp_error( $wp_response ) ) :
|
82 |
+
$wp_repo_response = unserialize( wp_remote_retrieve_body( $wp_response ) );
|
83 |
+
$wp_repo_plugins = $wp_repo_response->plugins;
|
84 |
+
endif;
|
85 |
+
if ( $wp_repo_plugins ) :
|
86 |
+
foreach ( $wp_repo_plugins as $plugin_details ) :
|
87 |
+
if ( $plugin_slug === $plugin_details->slug ) :
|
88 |
+
$plugin_return = $plugin_details;
|
89 |
+
set_transient( 'plugin_info_' . $plugin_slug, $plugin_return, 12 * HOUR_IN_SECONDS );
|
90 |
+
endif;
|
91 |
+
endforeach;
|
92 |
+
endif;
|
93 |
+
endif;
|
94 |
+
|
95 |
+
endif;
|
96 |
+
return $plugin_return;
|
97 |
+
}
|
98 |
+
|
99 |
+
/**
|
100 |
+
* CSS minification for inlined CSS styles
|
101 |
+
*
|
102 |
+
* @param string $input Inlined styles.
|
103 |
+
* @return string Minified styles.
|
104 |
+
*/
|
105 |
+
public function moove_gdpr_minify_css( $input ) {
|
106 |
+
if ( trim( $input ) === '' ) {
|
107 |
+
return $input;
|
108 |
+
}
|
109 |
+
return preg_replace(
|
110 |
+
array(
|
111 |
+
// Remove comment(s).
|
112 |
+
'#("(?:[^"\\\]++|\\\.)*+"|\'(?:[^\'\\\\]++|\\\.)*+\')|\/\*(?!\!)(?>.*?\*\/)|^\s*|\s*$#s',
|
113 |
+
// Remove unused white-space(s).
|
114 |
+
'#("(?:[^"\\\]++|\\\.)*+"|\'(?:[^\'\\\\]++|\\\.)*+\'|\/\*(?>.*?\*\/))|\s*+;\s*+(})\s*+|\s*+([*$~^|]?+=|[{};,>~+]|\s*+-(?![0-9\.])|!important\b)\s*+|([[(:])\s++|\s++([])])|\s++(:)\s*+(?!(?>[^{}"\']++|"(?:[^"\\\]++|\\\.)*+"|\'(?:[^\'\\\\]++|\\\.)*+\')*+{)|^\s++|\s++\z|(\s)\s+#si',
|
115 |
+
// Replace `0(cm|em|ex|in|mm|pc|pt|px|vh|vw|%)` with `0`.
|
116 |
+
'#(?<=[\s:])(0)(cm|em|ex|in|mm|pc|pt|px|vh|vw|%)#si',
|
117 |
+
// Replace `:0 0 0 0` with `:0`.
|
118 |
+
'#:(0\s+0|0\s+0\s+0\s+0)(?=[;\}]|\!important)#i',
|
119 |
+
// Replace `background-position:0` with `background-position:0 0`.
|
120 |
+
'#(background-position):0(?=[;\}])#si',
|
121 |
+
// Replace `0.6` with `.6`, but only when preceded by `:`, `,`, `-` or a white-space.
|
122 |
+
'#(?<=[\s:,\-])0+\.(\d+)#s',
|
123 |
+
// Minify string value.
|
124 |
+
'#(\/\*(?>.*?\*\/))|(?<!content\:)([\'"])([a-z_][a-z0-9\-_]*?)\2(?=[\s\{\}\];,])#si',
|
125 |
+
'#(\/\*(?>.*?\*\/))|(\burl\()([\'"])([^\s]+?)\3(\))#si',
|
126 |
+
// Minify HEX color code.
|
127 |
+
'#(?<=[\s:,\-]\#)([a-f0-6]+)\1([a-f0-6]+)\2([a-f0-6]+)\3#i',
|
128 |
+
// Replace `(border|outline):none` with `(border|outline):0`.
|
129 |
+
'#(?<=[\{;])(border|outline):none(?=[;\}\!])#',
|
130 |
+
// Remove empty selector(s).
|
131 |
+
'#(\/\*(?>.*?\*\/))|(^|[\{\}])(?:[^\s\{\}]+)\{\}#s',
|
132 |
+
),
|
133 |
+
array(
|
134 |
+
'$1',
|
135 |
+
'$1$2$3$4$5$6$7',
|
136 |
+
'$1',
|
137 |
+
':0',
|
138 |
+
'$1:0 0',
|
139 |
+
'.$1',
|
140 |
+
'$1$3',
|
141 |
+
'$1$2$4$5',
|
142 |
+
'$1$2$3',
|
143 |
+
'$1:0',
|
144 |
+
'$1$2',
|
145 |
+
),
|
146 |
+
$input
|
147 |
+
);
|
148 |
+
}
|
149 |
+
|
150 |
+
/**
|
151 |
+
* Inline styles based on the colours selected in the options page
|
152 |
+
*
|
153 |
+
* @param string $primary_colour Primary Color.
|
154 |
+
* @param string $secondary_colour Secondary Color.
|
155 |
+
* @param string $button_bg Button Background Color.
|
156 |
+
* @param string $button_hover_bg Button Hover Background Color.
|
157 |
+
* @param string $button_font Button Font Color.
|
158 |
+
* @param string $font_family Font Family.
|
159 |
+
*/
|
160 |
+
public function get_minified_styles( $primary_colour, $secondary_colour, $button_bg, $button_hover_bg, $button_font, $font_family ) {
|
161 |
+
ob_start();
|
162 |
+
?>
|
163 |
+
#moove_gdpr_cookie_modal,
|
164 |
+
#moove_gdpr_cookie_info_bar,
|
165 |
+
.gdpr_cookie_settings_shortcode_content {
|
166 |
+
font-family: <?php echo esc_attr( $font_family ); ?>;
|
167 |
+
}
|
168 |
+
#moove_gdpr_save_popup_settings_button {
|
169 |
+
background-color: <?php echo esc_attr( $button_bg ); ?>;
|
170 |
+
color: <?php echo esc_attr( $button_font ); ?>;
|
171 |
+
}
|
172 |
+
#moove_gdpr_save_popup_settings_button:hover {
|
173 |
+
background-color: <?php echo esc_attr( $button_hover_bg ); ?>;
|
174 |
+
}
|
175 |
+
|
176 |
+
#moove_gdpr_cookie_info_bar .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content a.mgbutton,
|
177 |
+
#moove_gdpr_cookie_info_bar .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content button.mgbutton {
|
178 |
+
background-color: <?php echo esc_attr( $primary_colour ); ?>;
|
179 |
+
}
|
180 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-footer-content .moove-gdpr-button-holder a.mgbutton,
|
181 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-footer-content .moove-gdpr-button-holder button.mgbutton,
|
182 |
+
.gdpr_cookie_settings_shortcode_content .gdpr-shr-button.button-green {
|
183 |
+
background-color: <?php echo esc_attr( $primary_colour ); ?>;
|
184 |
+
border-color: <?php echo esc_attr( $primary_colour ); ?>;
|
185 |
+
}
|
186 |
+
|
187 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-footer-content .moove-gdpr-button-holder a.mgbutton:hover,
|
188 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-footer-content .moove-gdpr-button-holder button.mgbutton:hover,
|
189 |
+
.gdpr_cookie_settings_shortcode_content .gdpr-shr-button.button-green:hover {
|
190 |
+
background-color: #fff;
|
191 |
+
color: <?php echo esc_attr( $primary_colour ); ?>;
|
192 |
+
}
|
193 |
+
|
194 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-close i,
|
195 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-close span.gdpr-icon {
|
196 |
+
background-color: <?php echo esc_attr( $primary_colour ); ?>;
|
197 |
+
border: 1px solid <?php echo esc_attr( $primary_colour ); ?>;
|
198 |
+
}
|
199 |
+
|
200 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-close i:hover,
|
201 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-close span.gdpr-icon:hover {
|
202 |
+
color: <?php echo esc_attr( $primary_colour ); ?>;
|
203 |
+
}
|
204 |
+
|
205 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected a span.gdpr-icon,
|
206 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected button span.gdpr-icon {
|
207 |
+
color: inherit;
|
208 |
+
}
|
209 |
+
|
210 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li:hover a,
|
211 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li:hover button {
|
212 |
+
color: <?php echo esc_attr( $secondary_colour ); ?>;
|
213 |
+
}
|
214 |
+
|
215 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li a span.gdpr-icon,
|
216 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li button span.gdpr-icon {
|
217 |
+
color: inherit;
|
218 |
+
}
|
219 |
+
|
220 |
+
#moove_gdpr_cookie_modal .gdpr-acc-link {
|
221 |
+
line-height: 0;
|
222 |
+
font-size: 0;
|
223 |
+
color: transparent;
|
224 |
+
position: absolute;
|
225 |
+
}
|
226 |
+
|
227 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-close:hover i,
|
228 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li a,
|
229 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li button,
|
230 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li button i,
|
231 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li a i,
|
232 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-tab-main .moove-gdpr-tab-main-content a:hover,
|
233 |
+
#moove_gdpr_cookie_info_bar.moove-gdpr-dark-scheme .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content a.mgbutton:hover,
|
234 |
+
#moove_gdpr_cookie_info_bar.moove-gdpr-dark-scheme .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content button.mgbutton:hover,
|
235 |
+
#moove_gdpr_cookie_info_bar.moove-gdpr-dark-scheme .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content a:hover,
|
236 |
+
#moove_gdpr_cookie_info_bar.moove-gdpr-dark-scheme .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content button:hover,
|
237 |
+
#moove_gdpr_cookie_info_bar.moove-gdpr-dark-scheme .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content span.change-settings-button:hover {
|
238 |
+
color: <?php echo esc_attr( $primary_colour ); ?>;
|
239 |
+
}
|
240 |
+
|
241 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected a,
|
242 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected button {
|
243 |
+
color: <?php echo esc_attr( $secondary_colour ); ?>;
|
244 |
+
}
|
245 |
+
|
246 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected a i,
|
247 |
+
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected button i {
|
248 |
+
color: <?php echo esc_attr( $secondary_colour ); ?>;
|
249 |
+
}
|
250 |
+
|
251 |
+
#moove_gdpr_cookie_modal.lity-hide {
|
252 |
+
display: none;
|
253 |
+
}
|
254 |
+
|
255 |
+
<?php
|
256 |
+
$input = apply_filters( 'moove_gdpr_inline_styles', ob_get_clean(), $primary_colour, $secondary_colour, $button_bg, $button_hover_bg, $button_font );
|
257 |
+
$gdpr_controller = new Moove_GDPR_Controller();
|
258 |
+
return $gdpr_controller->moove_gdpr_minify_css( $input );
|
259 |
+
}
|
260 |
+
|
261 |
+
/**
|
262 |
+
* GDPR Modal Main content
|
263 |
+
*
|
264 |
+
* @return void
|
265 |
+
*/
|
266 |
+
public static function moove_gdpr_cookie_popup_modal() {
|
267 |
+
|
268 |
+
// CUSTOM CSS STYLED.
|
269 |
+
$content = gdpr_get_module( 'branding-styles' );
|
270 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
271 |
+
|
272 |
+
// FLOATING BUTTON.
|
273 |
+
$content = gdpr_get_module( 'floating-button' );
|
274 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
275 |
+
|
276 |
+
// MODAL CONTENT.
|
277 |
+
$content = gdpr_get_module( 'modal-base' );
|
278 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
279 |
+
}
|
280 |
+
|
281 |
+
/**
|
282 |
+
* GDPR Cookie info bar with settings icon
|
283 |
+
*
|
284 |
+
* @return void
|
285 |
+
*/
|
286 |
+
public static function moove_gdpr_cookie_popup_info() {
|
287 |
+
$content = gdpr_get_module( 'infobar-base' );
|
288 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
289 |
+
}
|
290 |
+
|
291 |
+
/**
|
292 |
+
* AJAX function to display the allowed scripts from the plugin settings page
|
293 |
+
*
|
294 |
+
* @return void
|
295 |
+
*/
|
296 |
+
public static function moove_gdpr_get_scripts() {
|
297 |
+
wp_verify_nonce( 'gdpr_nonce', 'gdpr_cookie_compliance_nonce' );
|
298 |
+
$strict = isset( $_POST['strict'] ) && intval( $_POST['strict'] ) && 1 === intval( $_POST['strict'] ) ? true : false;
|
299 |
+
$thirdparty = isset( $_POST['thirdparty'] ) && intval( $_POST['thirdparty'] ) && 1 === intval( $_POST['thirdparty'] ) ? true : false;
|
300 |
+
$advanced = isset( $_POST['advanced'] ) && intval( $_POST['advanced'] ) && 1 === intval( $_POST['advanced'] ) ? true : false;
|
301 |
+
|
302 |
+
$transient_key = 'gdpr_cookie_cache';
|
303 |
+
$transient = apply_filters( 'gdpr_cookie_script_cache', get_transient( $transient_key ) );
|
304 |
+
|
305 |
+
if ( ! empty( $transient ) ) :
|
306 |
+
$transient_from_cache = json_decode( $transient, true );
|
307 |
+
else :
|
308 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
309 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
310 |
+
$modal_options = get_option( $option_name );
|
311 |
+
|
312 |
+
$cache_array = array(
|
313 |
+
'thirdparty' => array(
|
314 |
+
'header' => '',
|
315 |
+
'body' => '',
|
316 |
+
'footer' => '',
|
317 |
+
),
|
318 |
+
'advanced' => array(
|
319 |
+
'header' => '',
|
320 |
+
'body' => '',
|
321 |
+
'footer' => '',
|
322 |
+
),
|
323 |
+
);
|
324 |
+
|
325 |
+
// THIRD PARTY - SCRIPT CACHE.
|
326 |
+
ob_start();
|
327 |
+
$third_party_scripts = isset( $modal_options['moove_gdpr_third_party_header_scripts'] ) && $modal_options['moove_gdpr_third_party_header_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_third_party_header_scripts'] ) : '';
|
328 |
+
$third_party_scripts = apply_filters( 'moove_gdpr_third_party_header_assets', $third_party_scripts );
|
329 |
+
apply_filters( 'gdpr_cc_keephtml', $third_party_scripts, true );
|
330 |
+
$cache_array['thirdparty']['header'] .= ob_get_clean();
|
331 |
+
|
332 |
+
ob_start();
|
333 |
+
$third_party_scripts = isset( $modal_options['moove_gdpr_third_party_body_scripts'] ) && $modal_options['moove_gdpr_third_party_body_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_third_party_body_scripts'] ) : '';
|
334 |
+
$third_party_scripts = apply_filters( 'moove_gdpr_third_party_body_assets', $third_party_scripts );
|
335 |
+
apply_filters( 'gdpr_cc_keephtml', $third_party_scripts, true );
|
336 |
+
$cache_array['thirdparty']['body'] .= ob_get_clean();
|
337 |
+
|
338 |
+
ob_start();
|
339 |
+
$third_party_scripts = isset( $modal_options['moove_gdpr_third_party_footer_scripts'] ) && $modal_options['moove_gdpr_third_party_footer_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_third_party_footer_scripts'] ) : '';
|
340 |
+
$third_party_scripts = apply_filters( 'moove_gdpr_third_party_footer_assets', $third_party_scripts );
|
341 |
+
apply_filters( 'gdpr_cc_keephtml', $third_party_scripts, true );
|
342 |
+
$cache_array['thirdparty']['footer'] .= ob_get_clean();
|
343 |
+
|
344 |
+
// ADVANCED - SCRIPT CACHE.
|
345 |
+
ob_start();
|
346 |
+
$advanced_scripts = isset( $modal_options['moove_gdpr_advanced_cookies_header_scripts'] ) && $modal_options['moove_gdpr_advanced_cookies_header_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_advanced_cookies_header_scripts'] ) : '';
|
347 |
+
$advanced_scripts = apply_filters( 'moove_gdpr_advanced_cookies_header_assets', $advanced_scripts );
|
348 |
+
apply_filters( 'gdpr_cc_keephtml', $advanced_scripts, true );
|
349 |
+
$cache_array['advanced']['header'] .= ob_get_clean();
|
350 |
+
|
351 |
+
ob_start();
|
352 |
+
$advanced_scripts = isset( $modal_options['moove_gdpr_advanced_cookies_body_scripts'] ) && $modal_options['moove_gdpr_advanced_cookies_body_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_advanced_cookies_body_scripts'] ) : '';
|
353 |
+
$advanced_scripts = apply_filters( 'moove_gdpr_advanced_cookies_body_assets', $advanced_scripts );
|
354 |
+
apply_filters( 'gdpr_cc_keephtml', $advanced_scripts, true );
|
355 |
+
$cache_array['advanced']['body'] .= ob_get_clean();
|
356 |
+
|
357 |
+
ob_start();
|
358 |
+
$advanced_scripts = isset( $modal_options['moove_gdpr_advanced_cookies_footer_scripts'] ) && $modal_options['moove_gdpr_advanced_cookies_footer_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_advanced_cookies_footer_scripts'] ) : '';
|
359 |
+
$advanced_scripts = apply_filters( 'moove_gdpr_advanced_cookies_footer_assets', $advanced_scripts );
|
360 |
+
apply_filters( 'gdpr_cc_keephtml', $advanced_scripts, true );
|
361 |
+
$cache_array['advanced']['footer'] .= ob_get_clean();
|
362 |
+
|
363 |
+
$cache_json = json_encode( $cache_array, true );
|
364 |
+
|
365 |
+
set_transient( $transient_key, $cache_json, 86400 );
|
366 |
+
$transient_from_cache = $cache_array;
|
367 |
+
endif;
|
368 |
+
|
369 |
+
$scripts_array = array(
|
370 |
+
'cache' => ! empty( $transient ),
|
371 |
+
'header' => '',
|
372 |
+
'body' => '',
|
373 |
+
'footer' => '',
|
374 |
+
);
|
375 |
+
|
376 |
+
if ( true === $strict ) :
|
377 |
+
$transient_from_cache = apply_filters( 'gdpr_lss_extension', $transient_from_cache );
|
378 |
+
if ( $thirdparty ) :
|
379 |
+
if ( isset( $transient_from_cache['thirdparty'] ) ) :
|
380 |
+
$scripts_array['header'] .= $transient_from_cache['thirdparty']['header'];
|
381 |
+
$scripts_array['body'] .= $transient_from_cache['thirdparty']['body'];
|
382 |
+
$scripts_array['footer'] .= $transient_from_cache['thirdparty']['footer'];
|
383 |
+
endif;
|
384 |
+
endif;
|
385 |
+
|
386 |
+
if ( $advanced ) :
|
387 |
+
if ( isset( $transient_from_cache['advanced'] ) ) :
|
388 |
+
$scripts_array['header'] .= $transient_from_cache['advanced']['header'];
|
389 |
+
$scripts_array['body'] .= $transient_from_cache['advanced']['body'];
|
390 |
+
$scripts_array['footer'] .= $transient_from_cache['advanced']['footer'];
|
391 |
+
endif;
|
392 |
+
endif;
|
393 |
+
else :
|
394 |
+
if ( isset( $_SERVER['HTTP_COOKIE'] ) ) {
|
395 |
+
$cookies = explode( ';', sanitize_text_field( wp_unslash( $_SERVER['HTTP_COOKIE'] ) ) );
|
396 |
+
foreach ( $cookies as $cookie ) {
|
397 |
+
$parts = explode( '=', $cookie );
|
398 |
+
$name = trim( $parts[0] );
|
399 |
+
setcookie( $name, '', time() - 1000 );
|
400 |
+
setcookie( $name, '', time() - 1000, '/' );
|
401 |
+
}
|
402 |
+
}
|
403 |
+
endif;
|
404 |
+
echo json_encode( $scripts_array );
|
405 |
+
die();
|
406 |
+
}
|
407 |
+
|
408 |
+
/**
|
409 |
+
* Removing all the cookies including www and non-www domains
|
410 |
+
*/
|
411 |
+
public static function moove_gdpr_remove_php_cookies() {
|
412 |
+
$urlparts = wp_parse_url( site_url( '/' ) );
|
413 |
+
$domain = preg_replace( '/www\./i', '', $urlparts['host'] );
|
414 |
+
if ( isset( $_COOKIE ) && is_array( $_COOKIE ) && $domain ) :
|
415 |
+
foreach ( $_COOKIE as $key => $value ) {
|
416 |
+
|
417 |
+
if ( 'language' === $key || 'currency' === $key ) {
|
418 |
+
setcookie( $key, null, -1, '/', 'www.' . $domain );
|
419 |
+
} elseif ( '_ga' === $key || '_gid' === $key || '_gat' === $key ) {
|
420 |
+
setcookie( $key, null, -1, '/', '.' . $domain );
|
421 |
+
} else {
|
422 |
+
foreach ( $_COOKIE as $key => $value ) {
|
423 |
+
unset( $_COOKIE[ $key ] );
|
424 |
+
if ( 'language' === $key || 'currency' === $key ) {
|
425 |
+
setcookie( $key, null, -1, '/', 'www.' . $domain );
|
426 |
+
} elseif ( '_ga' === $key || '_gid' === $key || '_gat' === $key ) {
|
427 |
+
setcookie( $key, null, -1, '/', '.' . $domain );
|
428 |
+
} else {
|
429 |
+
setcookie( $key, null, -1, '/' );
|
430 |
+
}
|
431 |
+
}
|
432 |
+
}
|
433 |
+
}
|
434 |
+
endif;
|
435 |
+
}
|
436 |
+
|
437 |
+
/**
|
438 |
+
* Language notice hide
|
439 |
+
*/
|
440 |
+
public static function moove_hide_language_notice() {
|
441 |
+
wp_verify_nonce( 'gdpr_nonce', 'gdpr_cookie_compliance_nonce' );
|
442 |
+
$user_id = isset( $_POST['user_id'] ) ? intval( $_POST['user_id'] ) : false;
|
443 |
+
if ( $user_id ) :
|
444 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
445 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
446 |
+
$modal_options = get_option( $option_name );
|
447 |
+
$modal_options[ 'gdpr_hide_language_notice_' . $user_id ] = 1;
|
448 |
+
update_option( $option_name, $modal_options );
|
449 |
+
endif;
|
450 |
+
}
|
451 |
+
|
452 |
+
/**
|
453 |
+
* Function to reset plugin to default state
|
454 |
+
*/
|
455 |
+
public static function gdpr_cookie_compliance_reset_settings() {
|
456 |
+
$gdpr_content = new Moove_GDPR_Content();
|
457 |
+
$option_name = $gdpr_content->moove_gdpr_get_option_name();
|
458 |
+
$option_key = $gdpr_content->moove_gdpr_get_key_name();
|
459 |
+
update_option( $option_name, array() );
|
460 |
+
if ( function_exists( 'update_site_option' ) ) :
|
461 |
+
delete_site_option( $option_key );
|
462 |
+
else :
|
463 |
+
delete_option( $option_key );
|
464 |
+
endif;
|
465 |
+
|
466 |
+
echo json_encode( array( 'success' => true ) );
|
467 |
+
die();
|
468 |
+
}
|
469 |
+
|
470 |
+
}
|
471 |
+
new Moove_GDPR_Controller();
|
controllers/class-moove-gdpr-license-manager.php
ADDED
@@ -0,0 +1,228 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Moove_License_Manager File Doc Comment
|
4 |
+
*
|
5 |
+
* @category Moove_License_Manager
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
11 |
+
exit;
|
12 |
+
} // Exit if accessed directly
|
13 |
+
|
14 |
+
/**
|
15 |
+
* Moove_License_Manager Class Doc Comment
|
16 |
+
*
|
17 |
+
* @category Class
|
18 |
+
* @package Moove_License_Manager
|
19 |
+
* @author Gaspar Nemes
|
20 |
+
*/
|
21 |
+
class Moove_GDPR_License_Manager {
|
22 |
+
/**
|
23 |
+
* Construct function
|
24 |
+
*/
|
25 |
+
public function __construct() {
|
26 |
+
|
27 |
+
}
|
28 |
+
|
29 |
+
/**
|
30 |
+
* Licence validation
|
31 |
+
*
|
32 |
+
* @param string $license_key Licence key.
|
33 |
+
* @param string $type Type.
|
34 |
+
* @param string $action Action.
|
35 |
+
*/
|
36 |
+
public function validate_license( $license_key = false, $type, $action ) {
|
37 |
+
$content = new Moove_GDPR_Content();
|
38 |
+
$license_token = $content->get_license_token();
|
39 |
+
$curl = curl_init();
|
40 |
+
$request_url = MOOVE_SHOP_URL . "/wp-json/license-manager/v1/validate_licence/?license_key=$license_key&license_token=$license_token&license_type=$type&license_action=$action";
|
41 |
+
|
42 |
+
curl_setopt_array(
|
43 |
+
$curl,
|
44 |
+
array(
|
45 |
+
CURLOPT_URL => $request_url,
|
46 |
+
CURLOPT_RETURNTRANSFER => true,
|
47 |
+
CURLOPT_ENCODING => '',
|
48 |
+
CURLOPT_MAXREDIRS => 10,
|
49 |
+
CURLOPT_TIMEOUT => 30,
|
50 |
+
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
|
51 |
+
CURLOPT_CUSTOMREQUEST => 'GET',
|
52 |
+
CURLOPT_HTTPHEADER => array(
|
53 |
+
'Accept: application/json',
|
54 |
+
'Content-Type: application/json',
|
55 |
+
'Content-length: 0',
|
56 |
+
),
|
57 |
+
)
|
58 |
+
);
|
59 |
+
|
60 |
+
$response = curl_exec( $curl );
|
61 |
+
|
62 |
+
$err = curl_error( $curl );
|
63 |
+
|
64 |
+
curl_close( $curl );
|
65 |
+
|
66 |
+
if ( $err || ! json_decode( $response, true ) ) {
|
67 |
+
$error = $err ? $err : $response;
|
68 |
+
return array(
|
69 |
+
'valid' => false,
|
70 |
+
'message' => array(
|
71 |
+
'Our Activation Server appears to be temporarily unavailable, please try again later or <a href="mailto:plugins@mooveagency.com" class="' . $type . '_admin_link">contact support</a>.',
|
72 |
+
),
|
73 |
+
);
|
74 |
+
} else {
|
75 |
+
return json_decode( $response, true );
|
76 |
+
}
|
77 |
+
}
|
78 |
+
|
79 |
+
/**
|
80 |
+
* Plugin add-on slug
|
81 |
+
*/
|
82 |
+
public function get_add_on_plugin_slug() {
|
83 |
+
$slug = false;
|
84 |
+
if ( function_exists( 'moove_gdpr_addon_get_plugin_dir' ) ) :
|
85 |
+
$slug = str_replace( WP_PLUGIN_URL . '/', '', moove_gdpr_addon_get_plugin_dir() ) . '/moove-gdpr-addon.php';
|
86 |
+
else :
|
87 |
+
if ( ! function_exists( 'get_plugins' ) ) :
|
88 |
+
require_once ABSPATH . 'wp-admin/includes/plugin.php';
|
89 |
+
endif;
|
90 |
+
$all_plugins = get_plugins();
|
91 |
+
if ( is_array( $all_plugins ) ) :
|
92 |
+
foreach ( $all_plugins as $plugin_slug => $plugin_details ) :
|
93 |
+
if ( isset( $plugin_details['TextDomain'] ) && 'gdpr-cookie-compliance-addon' === $plugin_details['TextDomain'] && is_plugin_active( $plugin_slug ) ) :
|
94 |
+
$slug = $plugin_slug;
|
95 |
+
endif;
|
96 |
+
endforeach;
|
97 |
+
endif;
|
98 |
+
$slug = $slug ? $slug : 'gdpr-cookie-compliance-addon/moove-gdpr-addon.php';
|
99 |
+
endif;
|
100 |
+
return $slug;
|
101 |
+
}
|
102 |
+
|
103 |
+
/**
|
104 |
+
* Add-on download actions
|
105 |
+
*
|
106 |
+
* @param string $license_key Licence key.
|
107 |
+
* @param string $action Action.
|
108 |
+
*/
|
109 |
+
public function get_premium_add_on( $license_key = false, $action = 'check' ) {
|
110 |
+
$validate_license = $this->validate_license( $license_key, 'gdpr', $action );
|
111 |
+
if ( $validate_license && isset( $validate_license['valid'] ) && true === $validate_license['valid'] ) :
|
112 |
+
$plugin_token = isset( $validate_license['data'] ) && isset( $validate_license['data']['download_token'] ) && $validate_license['data']['download_token'] ? $validate_license['data']['download_token'] : false;
|
113 |
+
$is_valid_license = true;
|
114 |
+
if ( $plugin_token && 'activate' === $action ) :
|
115 |
+
$plugin_slug = $this->get_add_on_plugin_slug();
|
116 |
+
add_filter( 'upgrader_source_selection', array( &$this, 'upgrader_source_selection' ), 10, 4 );
|
117 |
+
if ( $plugin_slug ) :
|
118 |
+
if ( $this->is_plugin_installed( $plugin_slug ) ) {
|
119 |
+
$this->upgrade_plugin( $plugin_slug );
|
120 |
+
$installed = true;
|
121 |
+
} else {
|
122 |
+
$installed = $this->install_plugin( $plugin_token );
|
123 |
+
}
|
124 |
+
if ( ! is_wp_error( $installed ) && $installed ) {
|
125 |
+
$activate = activate_plugin( $plugin_slug );
|
126 |
+
}
|
127 |
+
endif;
|
128 |
+
remove_filter( 'upgrader_source_selection', array( &$this, 'upgrader_source_selection' ), 10, 4 );
|
129 |
+
endif;
|
130 |
+
endif;
|
131 |
+
return $validate_license;
|
132 |
+
}
|
133 |
+
|
134 |
+
/**
|
135 |
+
* Rename the plugin folder
|
136 |
+
*
|
137 |
+
* @param string $source Source.
|
138 |
+
* @param string $remote_source Remote Source.
|
139 |
+
* @param object $upgrader Upgrader.
|
140 |
+
* @param string $hook_extra Extra hooks.
|
141 |
+
*/
|
142 |
+
public function upgrader_source_selection( $source, $remote_source, $upgrader, $hook_extra = null ) {
|
143 |
+
global $wp_filesystem;
|
144 |
+
$plugin = isset( $hook_extra['plugin'] ) ? $hook_extra['plugin'] : false;
|
145 |
+
$plugin_slug = $this->get_add_on_plugin_slug();
|
146 |
+
$temp_slug = basename( trailingslashit( $source ) );
|
147 |
+
$plugin_slug = explode( '/', $plugin_slug );
|
148 |
+
$plugin_slug = isset( $plugin_slug[0] ) && $plugin_slug[0] ? $plugin_slug[0] : 'gdpr-cookie-compliance-addon';
|
149 |
+
if ( $temp_slug !== $plugin_slug ) :
|
150 |
+
$new_source = trailingslashit( $remote_source );
|
151 |
+
$new_source = str_replace( $temp_slug, $plugin_slug, $new_source );
|
152 |
+
$wp_filesystem->move( $source, $new_source );
|
153 |
+
return trailingslashit( $new_source );
|
154 |
+
endif;
|
155 |
+
return $source;
|
156 |
+
}
|
157 |
+
|
158 |
+
/**
|
159 |
+
* Plugin deactivate
|
160 |
+
*
|
161 |
+
* @param string $license_key Licence key.
|
162 |
+
*/
|
163 |
+
public function premium_deactivate( $license_key = false ) {
|
164 |
+
$validate_license = $this->validate_license( $license_key, 'gdpr', 'deactivate' );
|
165 |
+
if ( $validate_license && isset( $validate_license['valid'] ) && true === $validate_license['valid'] ) :
|
166 |
+
$plugin_slug = $this->get_add_on_plugin_slug();
|
167 |
+
if ( $plugin_slug ) :
|
168 |
+
if ( $this->is_plugin_installed( $plugin_slug ) ) :
|
169 |
+
deactivate_plugins( plugin_basename( $plugin_slug ) );
|
170 |
+
$deactivated = true;
|
171 |
+
endif;
|
172 |
+
endif;
|
173 |
+
endif;
|
174 |
+
return $validate_license;
|
175 |
+
}
|
176 |
+
|
177 |
+
/**
|
178 |
+
* Plugin installed
|
179 |
+
*
|
180 |
+
* @param string $slug Slug.
|
181 |
+
*/
|
182 |
+
public function is_plugin_installed( $slug = false ) {
|
183 |
+
if ( function_exists( 'moove_gdpr_addon_get_plugin_dir' ) ) :
|
184 |
+
return true;
|
185 |
+
endif;
|
186 |
+
if ( $slug ) :
|
187 |
+
if ( ! function_exists( 'get_plugins' ) ) {
|
188 |
+
require_once ABSPATH . 'wp-admin/includes/plugin.php';
|
189 |
+
}
|
190 |
+
$all_plugins = get_plugins();
|
191 |
+
if ( ! empty( $all_plugins[ $slug ] ) ) :
|
192 |
+
return true;
|
193 |
+
else :
|
194 |
+
return false;
|
195 |
+
endif;
|
196 |
+
endif;
|
197 |
+
return false;
|
198 |
+
}
|
199 |
+
|
200 |
+
/**
|
201 |
+
* Plugin install
|
202 |
+
*
|
203 |
+
* @param string $plugin_token Plugin token.
|
204 |
+
*/
|
205 |
+
public function install_plugin( $plugin_token ) {
|
206 |
+
include_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php';
|
207 |
+
wp_cache_flush();
|
208 |
+
$upgrader = new Plugin_Upgrader();
|
209 |
+
$installed = $upgrader->install( $plugin_token );
|
210 |
+
return $installed;
|
211 |
+
}
|
212 |
+
|
213 |
+
/**
|
214 |
+
* Upgrade plugin
|
215 |
+
*
|
216 |
+
* @param string $plugin_slug Plugin slug.
|
217 |
+
*/
|
218 |
+
public function upgrade_plugin( $plugin_slug ) {
|
219 |
+
include_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php';
|
220 |
+
wp_cache_flush();
|
221 |
+
$upgrader = new Plugin_Upgrader();
|
222 |
+
$upgraded = $upgrader->upgrade( $plugin_slug );
|
223 |
+
return $upgraded;
|
224 |
+
}
|
225 |
+
|
226 |
+
|
227 |
+
}
|
228 |
+
new Moove_GDPR_License_Manager();
|
controllers/class-moove-gdpr-updater.php
ADDED
@@ -0,0 +1,287 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Moove_GDPR_Updater File Doc Comment
|
4 |
+
*
|
5 |
+
* @category Moove_GDPR_Updater
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
11 |
+
exit;
|
12 |
+
} // Exit if accessed directly
|
13 |
+
|
14 |
+
if ( ! class_exists( 'Moove_GDPR_Updater' ) ) {
|
15 |
+
/**
|
16 |
+
* Moove_GDPR_Updater Class Doc Comment
|
17 |
+
*
|
18 |
+
* @category Class
|
19 |
+
* @package Moove_GDPR_Updater
|
20 |
+
* @author Gaspar Nemes
|
21 |
+
*/
|
22 |
+
class Moove_GDPR_Updater {
|
23 |
+
/**
|
24 |
+
* Update data
|
25 |
+
*
|
26 |
+
* @var array $update_data Update array
|
27 |
+
*/
|
28 |
+
public $update_data = array();
|
29 |
+
|
30 |
+
/**
|
31 |
+
* Active plugins
|
32 |
+
*
|
33 |
+
* @var array $active_plugins Active plugins.
|
34 |
+
*/
|
35 |
+
public $active_plugins = array();
|
36 |
+
|
37 |
+
/**
|
38 |
+
* Construct
|
39 |
+
*/
|
40 |
+
public function __construct() {
|
41 |
+
add_action( 'gdpr_plugin_updater_notice', array( &$this, 'gdpr_plugin_updater_notice' ) );
|
42 |
+
global $pagenow;
|
43 |
+
$allowed_pages = array( 'update-core.php', 'plugins.php' );
|
44 |
+
$plugin_slug = false;
|
45 |
+
$lm = new Moove_GDPR_License_Manager();
|
46 |
+
$plugin_slug = $lm->get_add_on_plugin_slug();
|
47 |
+
wp_verify_nonce( 'gdpr_nonce', 'gdpr_cookie_compliance_nonce' );
|
48 |
+
if ( in_array( $pagenow, $allowed_pages ) ) :
|
49 |
+
$this->gdpr_plugin_updater_notice();
|
50 |
+
$this->gdpr_check_for_updates();
|
51 |
+
elseif ( ( 'admin.php' === $pagenow && isset( $_GET['page'] ) && 'moove-gdpr' === sanitize_text_field( wp_unslash( $_GET['page'] ) ) ) ) :
|
52 |
+
$this->gdpr_check_for_updates();
|
53 |
+
endif;
|
54 |
+
add_filter( 'plugins_api', array( &$this, 'plugins_api' ), 10, 3 );
|
55 |
+
add_filter( 'pre_set_site_transient_update_plugins', array( &$this, 'set_update_data' ) );
|
56 |
+
add_filter( 'upgrader_source_selection', array( &$this, 'upgrader_source_selection' ), 10, 4 );
|
57 |
+
if ( $plugin_slug ) :
|
58 |
+
add_action( "in_plugin_update_message-{$plugin_slug}", array( &$this, 'gdpr_update_message_content' ), 10, 2 );
|
59 |
+
endif;
|
60 |
+
}
|
61 |
+
|
62 |
+
/**
|
63 |
+
* Update message
|
64 |
+
*
|
65 |
+
* @param array $plugin_data Plugin data.
|
66 |
+
* @param object $response Response.
|
67 |
+
*/
|
68 |
+
public function gdpr_update_message_content( $plugin_data, $response ) {
|
69 |
+
if ( isset( $plugin_data['package'] ) && ! $plugin_data['package'] ) :
|
70 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
71 |
+
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
72 |
+
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
73 |
+
$license_key = isset( $gdpr_key['key'] ) ? sanitize_text_field( $gdpr_key['key'] ) : false;
|
74 |
+
$renew_link = MOOVE_SHOP_URL . '?renew=' . $license_key;
|
75 |
+
$license_manager = admin_url( 'admin.php' ) . '?page=moove-gdpr&tab=licence';
|
76 |
+
$purchase_link = 'https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/';
|
77 |
+
if ( $license_key && isset( $gdpr_key['activation'] ) ) :
|
78 |
+
// Expired.
|
79 |
+
echo ' Update is not available until you <a href="' . esc_url( $renew_link ) . '" target="_blank">renew your licence</a>. You can also update your licence key in the <a href="' . esc_url( $license_manager ) . '" target="_blank">Licence Manager</a>.';
|
80 |
+
elseif ( $license_key && isset( $gdpr_key['deactivation'] ) ) :
|
81 |
+
// Deactivated.
|
82 |
+
echo ' Update is not available until you <a href="' . esc_url( $purchase_link ) . '" target="_blank">purchase a licence</a>. You can also update your licence key in the <a href="' . esc_url( $license_manager ) . '" target="_blank">Licence Manager</a>.';
|
83 |
+
elseif ( ! $license_key ) :
|
84 |
+
// No license key installed.
|
85 |
+
echo ' Update is not available until you <a href="' . esc_url( $purchase_link ) . '" target="_blank">purchase a licence</a>. You can also update your licence key in the <a href="' . esc_url( $license_manager ) . '" target="_blank">Licence Manager</a>.';
|
86 |
+
endif;
|
87 |
+
endif;
|
88 |
+
return array();
|
89 |
+
}
|
90 |
+
|
91 |
+
/**
|
92 |
+
* Updater notice
|
93 |
+
*/
|
94 |
+
public function gdpr_plugin_updater_notice() {
|
95 |
+
update_option( 'gpdr_last_checked', strtotime( 'yesterday' ) );
|
96 |
+
delete_site_transient( 'update_plugins' );
|
97 |
+
}
|
98 |
+
|
99 |
+
/**
|
100 |
+
* Update checker
|
101 |
+
*/
|
102 |
+
public function gdpr_check_for_updates() {
|
103 |
+
$this->update_data = get_option( 'gdpr_update_data' );
|
104 |
+
$active = get_option( 'active_plugins' );
|
105 |
+
$last_checked = get_option( 'gpdr_last_checked' );
|
106 |
+
$now = strtotime( 'now' );
|
107 |
+
$check_interval = 6 * HOUR_IN_SECONDS;
|
108 |
+
|
109 |
+
foreach ( $active as $slug ) :
|
110 |
+
$this->active_plugins[ $slug ] = true;
|
111 |
+
endforeach;
|
112 |
+
|
113 |
+
// transient expiration.
|
114 |
+
if ( ( $now - $last_checked ) > $check_interval ) :
|
115 |
+
$this->update_data = $this->get_addon_updates();
|
116 |
+
update_option( 'gdpr_update_data', $this->update_data );
|
117 |
+
update_option( 'gpdr_last_checked', $now );
|
118 |
+
$plugins = get_site_transient( 'update_plugins' );
|
119 |
+
$lm = new Moove_GDPR_License_Manager();
|
120 |
+
$plugin_slug = $lm->get_add_on_plugin_slug();
|
121 |
+
|
122 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
123 |
+
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
124 |
+
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
125 |
+
$license_key = sanitize_text_field( $gdpr_key['key'] );
|
126 |
+
if ( $plugin_slug ) :
|
127 |
+
if ( $license_key && ! isset( $gdpr_key['deactivation'] ) ) :
|
128 |
+
if ( isset( $plugins->response[ $plugin_slug ] ) ) :
|
129 |
+
$plugins->response[ $plugin_slug ]->new_version = $this->update_data[ $plugin_slug ]['new_version'];
|
130 |
+
$plugins->response[ $plugin_slug ]->package = $this->update_data[ $plugin_slug ]['package'];
|
131 |
+
set_site_transient( 'update_plugins', $plugins );
|
132 |
+
endif;
|
133 |
+
else :
|
134 |
+
if ( isset( $plugins->response[ $plugin_slug ] ) ) :
|
135 |
+
$plugins->response[ $plugin_slug ]->new_version = $this->update_data[ $plugin_slug ]['new_version'];
|
136 |
+
$plugins->response[ $plugin_slug ]->package = '';
|
137 |
+
set_site_transient( 'update_plugins', $plugins );
|
138 |
+
endif;
|
139 |
+
endif;
|
140 |
+
endif;
|
141 |
+
endif;
|
142 |
+
}
|
143 |
+
|
144 |
+
|
145 |
+
/**
|
146 |
+
* Fetch the latest GitHub tags and build the plugin data array
|
147 |
+
*/
|
148 |
+
public function get_addon_updates() {
|
149 |
+
$plugin_data = array();
|
150 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
151 |
+
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
152 |
+
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
153 |
+
$license_key = sanitize_text_field( $gdpr_key['key'] );
|
154 |
+
if ( $license_key ) :
|
155 |
+
|
156 |
+
$plugins = function_exists( 'get_plugins' ) ? get_plugins() : array();
|
157 |
+
foreach ( $plugins as $slug => $info ) :
|
158 |
+
if ( isset( $info['TextDomain'] ) && 'gdpr-cookie-compliance-addon' === $info['TextDomain'] ) :
|
159 |
+
$license_manager = new Moove_GDPR_License_Manager();
|
160 |
+
$is_valid_license = $license_manager->get_premium_add_on( $license_key, 'update' );
|
161 |
+
$temp = array(
|
162 |
+
'plugin' => $slug,
|
163 |
+
'slug' => trim( dirname( $slug ), '/' ),
|
164 |
+
'name' => $info['Name'],
|
165 |
+
'description' => $info['Description'],
|
166 |
+
'new_version' => false,
|
167 |
+
'package' => false,
|
168 |
+
);
|
169 |
+
if ( $is_valid_license && isset( $is_valid_license['valid'] ) ) :
|
170 |
+
|
171 |
+
$plugin_token = isset( $is_valid_license['data'] ) && isset( $is_valid_license['data']['download_token'] ) && $is_valid_license['data']['download_token'] ? $is_valid_license['data']['download_token'] : false;
|
172 |
+
$plugin_version = isset( $is_valid_license['data'] ) && isset( $is_valid_license['data']['version'] ) && $is_valid_license['data']['version'] ? $is_valid_license['data']['version'] : 0;
|
173 |
+
|
174 |
+
$temp['new_version'] = $plugin_version;
|
175 |
+
$temp['package'] = ! isset( $gdpr_key['deactivation'] ) ? $plugin_token : '';
|
176 |
+
|
177 |
+
endif;
|
178 |
+
$plugin_data[ $slug ] = $temp;
|
179 |
+
endif;
|
180 |
+
endforeach;
|
181 |
+
endif;
|
182 |
+
return $plugin_data;
|
183 |
+
}
|
184 |
+
|
185 |
+
|
186 |
+
/**
|
187 |
+
* Get plugin info for the "View Details" popup
|
188 |
+
*
|
189 |
+
* @param bool $default Default.
|
190 |
+
* @param string $action Action.
|
191 |
+
* @param array $args Args.
|
192 |
+
*/
|
193 |
+
public function plugins_api( $default = false, $action, $args ) {
|
194 |
+
if ( 'plugin_information' === $action ) {
|
195 |
+
$plugin_data = array();
|
196 |
+
$this->update_data = get_option( 'uat_update_data' );
|
197 |
+
if ( is_array( $this->update_data ) && ! empty( $this->update_data ) ) :
|
198 |
+
foreach ( $this->update_data as $slug => $data ) :
|
199 |
+
if ( $data['slug'] === $args->slug ) :
|
200 |
+
if ( class_exists( 'Moove_GDPR_Controller' ) ) :
|
201 |
+
$gdpr_controller = new Moove_GDPR_Controller();
|
202 |
+
$plugin_details = $gdpr_controller->get_gdpr_plugin_details( 'gdpr-cookie-compliance' );
|
203 |
+
unset( $plugin_details->sections['screenshot'] );
|
204 |
+
unset( $plugin_details->sections['changelog'] );
|
205 |
+
unset( $plugin_details->sections['installation'] );
|
206 |
+
$plugin_details->name = $data['name'];
|
207 |
+
$plugin_details->slug = $data['plugin'];
|
208 |
+
$plugin_details->version = $data['new_version'];
|
209 |
+
$plugin_details->last_updated = '';
|
210 |
+
$plugin_details->banners = array(
|
211 |
+
'high' => 'https://ps.w.org/gdpr-cookie-compliance/assets/banner-772x250.png',
|
212 |
+
);
|
213 |
+
return (object) $plugin_details;
|
214 |
+
endif;
|
215 |
+
endif;
|
216 |
+
endforeach;
|
217 |
+
endif;
|
218 |
+
}
|
219 |
+
return $default;
|
220 |
+
}
|
221 |
+
|
222 |
+
/**
|
223 |
+
* Set update data
|
224 |
+
*
|
225 |
+
* @param string $transient Transient key.
|
226 |
+
*/
|
227 |
+
public function set_update_data( $transient ) {
|
228 |
+
if ( empty( $transient->checked ) ) {
|
229 |
+
return $transient;
|
230 |
+
}
|
231 |
+
foreach ( $this->update_data as $plugin => $info ) {
|
232 |
+
if ( isset( $this->active_plugins[ $plugin ] ) ) {
|
233 |
+
$plugin_data = get_plugin_data( WP_PLUGIN_DIR . '/' . $plugin );
|
234 |
+
$version = $plugin_data['Version'];
|
235 |
+
|
236 |
+
if ( version_compare( $version, $info['new_version'], '<' ) ) {
|
237 |
+
$transient->response[ $plugin ] = (object) $info;
|
238 |
+
}
|
239 |
+
}
|
240 |
+
}
|
241 |
+
return $transient;
|
242 |
+
}
|
243 |
+
|
244 |
+
/**
|
245 |
+
* Rename the plugin folder
|
246 |
+
*
|
247 |
+
* @param string $source Source.
|
248 |
+
* @param string $remote_source Remote source.
|
249 |
+
* @param object $upgrader Upgrader.
|
250 |
+
* @param bool $hook_extra Hook extra.
|
251 |
+
*/
|
252 |
+
public function upgrader_source_selection( $source, $remote_source, $upgrader, $hook_extra = null ) {
|
253 |
+
global $wp_filesystem;
|
254 |
+
$plugin = isset( $hook_extra['plugin'] ) ? $hook_extra['plugin'] : false;
|
255 |
+
if ( isset( $this->update_data[ $plugin ] ) && $plugin ) :
|
256 |
+
$lm = new Moove_GDPR_License_Manager();
|
257 |
+
$plugin_slug = $lm->get_add_on_plugin_slug();
|
258 |
+
$temp_slug = basename( trailingslashit( $source ) );
|
259 |
+
$plugin_slug = explode( '/', $plugin_slug );
|
260 |
+
$plugin_slug = isset( $plugin_slug[0] ) && $plugin_slug[0] ? $plugin_slug[0] : 'gdpr-cookie-compliance-addon';
|
261 |
+
|
262 |
+
if ( $temp_slug !== $plugin_slug ) :
|
263 |
+
$new_source = trailingslashit( $remote_source );
|
264 |
+
$new_source = str_replace( $temp_slug, $plugin_slug, $new_source );
|
265 |
+
$wp_filesystem->move( $source, $new_source );
|
266 |
+
return trailingslashit( $new_source );
|
267 |
+
endif;
|
268 |
+
endif;
|
269 |
+
return $source;
|
270 |
+
}
|
271 |
+
|
272 |
+
/**
|
273 |
+
* Hide update notice
|
274 |
+
*/
|
275 |
+
public function moove_hide_update_notice() {
|
276 |
+
wp_verify_nonce( 'gdpr_nonce', 'gdpr_cookie_compliance_nonce' );
|
277 |
+
$version = isset( $_POST['version'] ) ? sanitize_text_field( wp_unslash( $_POST['version'] ) ) : false;
|
278 |
+
if ( $version ) :
|
279 |
+
$current_user = wp_get_current_user();
|
280 |
+
$user_id = isset( $current_user->ID ) ? $current_user->ID : false;
|
281 |
+
update_option( 'gdpr_hide_update_notice_' . $user_id, $version );
|
282 |
+
endif;
|
283 |
+
}
|
284 |
+
|
285 |
+
}
|
286 |
+
new Moove_GDPR_Updater();
|
287 |
+
}
|
controllers/moove-controller.php
DELETED
@@ -1,424 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
3 |
-
/**
|
4 |
-
* Moove_Controller File Doc Comment
|
5 |
-
*
|
6 |
-
* @category Moove_Controller
|
7 |
-
* @package gdpr-cookie-compliance
|
8 |
-
* @author Gaspar Nemes
|
9 |
-
*/
|
10 |
-
|
11 |
-
/**
|
12 |
-
* Moove_Controller Class Doc Comment
|
13 |
-
*
|
14 |
-
* @category Class
|
15 |
-
* @package Moove_Controller
|
16 |
-
* @author Gaspar Nemes
|
17 |
-
*/
|
18 |
-
class Moove_GDPR_Controller {
|
19 |
-
/**
|
20 |
-
* Construct function
|
21 |
-
*/
|
22 |
-
public function __construct() {
|
23 |
-
// add_action( 'wp_footer', array( &$this, 'moove_gdpr_cookie_popup' ) );
|
24 |
-
add_action( 'wp_footer', array( &$this, 'moove_gdpr_cookie_popup_modal' ), 99 );
|
25 |
-
add_action( 'admin_init', array( &$this, 'moove_gdpr_add_editor_styles' ) );
|
26 |
-
add_action( 'wp_footer', array( &$this, 'moove_gdpr_cookie_popup_info' ) );
|
27 |
-
}
|
28 |
-
|
29 |
-
/**
|
30 |
-
* Custom Editor CSS added to GDPR plugin WYSIWYG editors
|
31 |
-
* @return void
|
32 |
-
*/
|
33 |
-
public function moove_gdpr_add_editor_styles() {
|
34 |
-
add_editor_style( moove_gdpr_get_plugin_directory_url() . 'dist/styles/custom-editor-style.css' );
|
35 |
-
}
|
36 |
-
|
37 |
-
public static function moove_gdpr_localize_scripts() {
|
38 |
-
$content_cnt = new Moove_GDPR_Content();
|
39 |
-
echo json_encode( $content_cnt->moove_gdpr_get_localize_scripts() );
|
40 |
-
die();
|
41 |
-
}
|
42 |
-
|
43 |
-
/**
|
44 |
-
* Reading plugin statistics from WordPress.org
|
45 |
-
* - star rating
|
46 |
-
* - downloads & active installations
|
47 |
-
*/
|
48 |
-
function get_gdpr_plugin_details( $plugin_slug = '' ) {
|
49 |
-
$plugin_return = false;
|
50 |
-
$wp_repo_plugins = '';
|
51 |
-
$wp_response = '';
|
52 |
-
$wp_version = get_bloginfo('version');
|
53 |
-
$transient = get_transient( 'plugin_info_'. $plugin_slug );
|
54 |
-
if ( $transient ) :
|
55 |
-
$plugin_return = $transient;
|
56 |
-
else :
|
57 |
-
if ( $plugin_slug && $wp_version > 3.8 ) :
|
58 |
-
$args = array(
|
59 |
-
'author' => 'MooveAgency',
|
60 |
-
'fields' => array(
|
61 |
-
'downloaded' => true,
|
62 |
-
'active_installs' => true,
|
63 |
-
'ratings' => true
|
64 |
-
)
|
65 |
-
);
|
66 |
-
$wp_response = wp_remote_post(
|
67 |
-
'http://api.wordpress.org/plugins/info/1.0/',
|
68 |
-
array(
|
69 |
-
'body' => array(
|
70 |
-
'action' => 'query_plugins',
|
71 |
-
'request' => serialize( (object) $args )
|
72 |
-
)
|
73 |
-
)
|
74 |
-
);
|
75 |
-
if ( ! is_wp_error( $wp_response ) ) :
|
76 |
-
$wp_repo_response = unserialize( wp_remote_retrieve_body( $wp_response ) );
|
77 |
-
$wp_repo_plugins = $wp_repo_response->plugins;
|
78 |
-
endif;
|
79 |
-
if ( $wp_repo_plugins ) :
|
80 |
-
foreach ( $wp_repo_plugins as $plugin_details ) :
|
81 |
-
if ( $plugin_slug == $plugin_details->slug ) :
|
82 |
-
$plugin_return = $plugin_details;
|
83 |
-
set_transient( 'plugin_info_'. $plugin_slug, $plugin_return, 12 * HOUR_IN_SECONDS );
|
84 |
-
endif;
|
85 |
-
endforeach;
|
86 |
-
endif;
|
87 |
-
endif;
|
88 |
-
|
89 |
-
endif;
|
90 |
-
return $plugin_return;
|
91 |
-
}
|
92 |
-
|
93 |
-
/**
|
94 |
-
* CSS minification for inlined CSS styles
|
95 |
-
* @param string $input Inlined styles
|
96 |
-
* @return string Minified styles
|
97 |
-
*/
|
98 |
-
public function moove_gdpr_minify_css($input) {
|
99 |
-
if(trim($input) === "") return $input;
|
100 |
-
return preg_replace(
|
101 |
-
array(
|
102 |
-
// Remove comment(s)
|
103 |
-
'#("(?:[^"\\\]++|\\\.)*+"|\'(?:[^\'\\\\]++|\\\.)*+\')|\/\*(?!\!)(?>.*?\*\/)|^\s*|\s*$#s',
|
104 |
-
// Remove unused white-space(s)
|
105 |
-
'#("(?:[^"\\\]++|\\\.)*+"|\'(?:[^\'\\\\]++|\\\.)*+\'|\/\*(?>.*?\*\/))|\s*+;\s*+(})\s*+|\s*+([*$~^|]?+=|[{};,>~+]|\s*+-(?![0-9\.])|!important\b)\s*+|([[(:])\s++|\s++([])])|\s++(:)\s*+(?!(?>[^{}"\']++|"(?:[^"\\\]++|\\\.)*+"|\'(?:[^\'\\\\]++|\\\.)*+\')*+{)|^\s++|\s++\z|(\s)\s+#si',
|
106 |
-
// Replace `0(cm|em|ex|in|mm|pc|pt|px|vh|vw|%)` with `0`
|
107 |
-
'#(?<=[\s:])(0)(cm|em|ex|in|mm|pc|pt|px|vh|vw|%)#si',
|
108 |
-
// Replace `:0 0 0 0` with `:0`
|
109 |
-
'#:(0\s+0|0\s+0\s+0\s+0)(?=[;\}]|\!important)#i',
|
110 |
-
// Replace `background-position:0` with `background-position:0 0`
|
111 |
-
'#(background-position):0(?=[;\}])#si',
|
112 |
-
// Replace `0.6` with `.6`, but only when preceded by `:`, `,`, `-` or a white-space
|
113 |
-
'#(?<=[\s:,\-])0+\.(\d+)#s',
|
114 |
-
// Minify string value
|
115 |
-
'#(\/\*(?>.*?\*\/))|(?<!content\:)([\'"])([a-z_][a-z0-9\-_]*?)\2(?=[\s\{\}\];,])#si',
|
116 |
-
'#(\/\*(?>.*?\*\/))|(\burl\()([\'"])([^\s]+?)\3(\))#si',
|
117 |
-
// Minify HEX color code
|
118 |
-
'#(?<=[\s:,\-]\#)([a-f0-6]+)\1([a-f0-6]+)\2([a-f0-6]+)\3#i',
|
119 |
-
// Replace `(border|outline):none` with `(border|outline):0`
|
120 |
-
'#(?<=[\{;])(border|outline):none(?=[;\}\!])#',
|
121 |
-
// Remove empty selector(s)
|
122 |
-
'#(\/\*(?>.*?\*\/))|(^|[\{\}])(?:[^\s\{\}]+)\{\}#s'
|
123 |
-
),
|
124 |
-
array(
|
125 |
-
'$1',
|
126 |
-
'$1$2$3$4$5$6$7',
|
127 |
-
'$1',
|
128 |
-
':0',
|
129 |
-
'$1:0 0',
|
130 |
-
'.$1',
|
131 |
-
'$1$3',
|
132 |
-
'$1$2$4$5',
|
133 |
-
'$1$2$3',
|
134 |
-
'$1:0',
|
135 |
-
'$1$2'
|
136 |
-
),
|
137 |
-
$input);
|
138 |
-
}
|
139 |
-
|
140 |
-
/**
|
141 |
-
* Inline styles based on the colours selected in the options page
|
142 |
-
*/
|
143 |
-
public function get_minified_styles( $primary_colour, $secondary_colour, $button_bg, $button_hover_bg, $button_font, $font_family ) {
|
144 |
-
ob_start();
|
145 |
-
?>
|
146 |
-
#moove_gdpr_cookie_modal,
|
147 |
-
#moove_gdpr_cookie_info_bar,
|
148 |
-
.gdpr_cookie_settings_shortcode_content {
|
149 |
-
font-family: <?php echo $font_family; ?>;
|
150 |
-
}
|
151 |
-
#moove_gdpr_save_popup_settings_button {
|
152 |
-
background-color: <?php echo $button_bg; ?>;
|
153 |
-
color: <?php echo $button_font; ?>;
|
154 |
-
}
|
155 |
-
#moove_gdpr_save_popup_settings_button:hover {
|
156 |
-
background-color: <?php echo $button_hover_bg; ?>;
|
157 |
-
}
|
158 |
-
|
159 |
-
#moove_gdpr_cookie_info_bar .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content a.mgbutton,
|
160 |
-
#moove_gdpr_cookie_info_bar .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content button.mgbutton {
|
161 |
-
background-color: <?php echo $primary_colour; ?>;
|
162 |
-
}
|
163 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-footer-content .moove-gdpr-button-holder a.mgbutton,
|
164 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-footer-content .moove-gdpr-button-holder button.mgbutton,
|
165 |
-
.gdpr_cookie_settings_shortcode_content .gdpr-shr-button.button-green {
|
166 |
-
background-color: <?php echo $primary_colour; ?>;
|
167 |
-
border-color: <?php echo $primary_colour; ?>;
|
168 |
-
}
|
169 |
-
|
170 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-footer-content .moove-gdpr-button-holder a.mgbutton:hover,
|
171 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-footer-content .moove-gdpr-button-holder button.mgbutton:hover,
|
172 |
-
.gdpr_cookie_settings_shortcode_content .gdpr-shr-button.button-green:hover {
|
173 |
-
background-color: #fff;
|
174 |
-
color: <?php echo $primary_colour; ?>;
|
175 |
-
}
|
176 |
-
|
177 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-close i,
|
178 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-close span.gdpr-icon {
|
179 |
-
background-color: <?php echo $primary_colour; ?>;
|
180 |
-
border: 1px solid <?php echo $primary_colour; ?>;
|
181 |
-
}
|
182 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-close i:hover,
|
183 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-close span.gdpr-icon:hover {
|
184 |
-
color: <?php echo $primary_colour; ?>;
|
185 |
-
}
|
186 |
-
|
187 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected a span.gdpr-icon,
|
188 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected button span.gdpr-icon {
|
189 |
-
color: inherit;
|
190 |
-
}
|
191 |
-
|
192 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li:hover a,
|
193 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li:hover button {
|
194 |
-
color: <?php echo $secondary_colour; ?>;
|
195 |
-
}
|
196 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li a span.gdpr-icon,
|
197 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li button span.gdpr-icon {
|
198 |
-
color: inherit;
|
199 |
-
}
|
200 |
-
|
201 |
-
#moove_gdpr_cookie_modal .gdpr-acc-link {
|
202 |
-
line-height: 0;
|
203 |
-
font-size: 0;
|
204 |
-
color: transparent;
|
205 |
-
position: absolute;
|
206 |
-
}
|
207 |
-
|
208 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-close:hover i,
|
209 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li a,
|
210 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li button,
|
211 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li button i,
|
212 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li a i,
|
213 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-tab-main .moove-gdpr-tab-main-content a:hover,
|
214 |
-
#moove_gdpr_cookie_info_bar.moove-gdpr-dark-scheme .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content a.mgbutton:hover,
|
215 |
-
#moove_gdpr_cookie_info_bar.moove-gdpr-dark-scheme .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content button.mgbutton:hover,
|
216 |
-
#moove_gdpr_cookie_info_bar.moove-gdpr-dark-scheme .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content a:hover,
|
217 |
-
#moove_gdpr_cookie_info_bar.moove-gdpr-dark-scheme .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content button:hover,
|
218 |
-
#moove_gdpr_cookie_info_bar.moove-gdpr-dark-scheme .moove-gdpr-info-bar-container .moove-gdpr-info-bar-content span.change-settings-button:hover {
|
219 |
-
color: <?php echo $primary_colour; ?>;
|
220 |
-
}
|
221 |
-
|
222 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected a,
|
223 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected button {
|
224 |
-
color: <?php echo $secondary_colour; ?>;
|
225 |
-
}
|
226 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected a i,
|
227 |
-
#moove_gdpr_cookie_modal .moove-gdpr-modal-content .moove-gdpr-modal-left-content #moove-gdpr-menu li.menu-item-selected button i {
|
228 |
-
color: <?php echo $secondary_colour; ?>;
|
229 |
-
}
|
230 |
-
#moove_gdpr_cookie_modal.lity-hide {
|
231 |
-
display: none;
|
232 |
-
}
|
233 |
-
|
234 |
-
<?php
|
235 |
-
$input = apply_filters( 'moove_gdpr_inline_styles', ob_get_clean(), $primary_colour, $secondary_colour, $button_bg, $button_hover_bg, $button_font );
|
236 |
-
$gdpr_controller = new Moove_GDPR_Controller();
|
237 |
-
return $gdpr_controller->moove_gdpr_minify_css( $input );
|
238 |
-
}
|
239 |
-
|
240 |
-
/**
|
241 |
-
* GDPR Modal Main content
|
242 |
-
* @return void
|
243 |
-
*/
|
244 |
-
public function moove_gdpr_cookie_popup_modal() {
|
245 |
-
|
246 |
-
// CUSTOM CSS STYLED
|
247 |
-
echo gdpr_get_module( 'branding-styles' );
|
248 |
-
|
249 |
-
// FLOATING BUTTON
|
250 |
-
echo gdpr_get_module( 'floating-button' );
|
251 |
-
|
252 |
-
//MODAL CONTENT
|
253 |
-
echo gdpr_get_module( 'modal-base' );
|
254 |
-
}
|
255 |
-
|
256 |
-
/**
|
257 |
-
* GDPR Cookie info bar with settings icon
|
258 |
-
* @return void
|
259 |
-
*/
|
260 |
-
public function moove_gdpr_cookie_popup_info() {
|
261 |
-
echo gdpr_get_module( 'infobar-base' );
|
262 |
-
}
|
263 |
-
|
264 |
-
/**
|
265 |
-
* AJAX function to display the allowed scripts from the plugin settings page
|
266 |
-
* @return void
|
267 |
-
*/
|
268 |
-
public static function moove_gdpr_get_scripts() {
|
269 |
-
$strict = intval( $_POST['strict'] ) && intval( $_POST['strict'] ) === 1 ? true : false;
|
270 |
-
$thirdparty = intval( $_POST['thirdparty'] ) && intval( $_POST['thirdparty'] ) === 1 ? true : false;
|
271 |
-
$advanced = intval( $_POST['advanced'] ) && intval( $_POST['advanced'] ) === 1 ? true : false;
|
272 |
-
|
273 |
-
$transient_key = 'gdpr_cookie_cache';
|
274 |
-
$transient = apply_filters('gdpr_cookie_script_cache', get_transient( $transient_key ) );
|
275 |
-
|
276 |
-
if ( ! empty( $transient ) ) :
|
277 |
-
$transient_from_cache = json_decode( $transient, true );
|
278 |
-
else :
|
279 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
280 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
281 |
-
$modal_options = get_option( $option_name );
|
282 |
-
|
283 |
-
$cache_array = array(
|
284 |
-
'thirdparty' => array(
|
285 |
-
'header' => '',
|
286 |
-
'body' => '',
|
287 |
-
'footer' => ''
|
288 |
-
),
|
289 |
-
'advanced' => array(
|
290 |
-
'header' => '',
|
291 |
-
'body' => '',
|
292 |
-
'footer' => ''
|
293 |
-
)
|
294 |
-
);
|
295 |
-
|
296 |
-
// THIRD PARTY - SCRIPT CACHE
|
297 |
-
ob_start();
|
298 |
-
$third_party_scripts = isset( $modal_options['moove_gdpr_third_party_header_scripts'] ) && $modal_options['moove_gdpr_third_party_header_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_third_party_header_scripts'] ) : '';
|
299 |
-
$third_party_scripts = apply_filters( 'moove_gdpr_third_party_header_assets', $third_party_scripts );
|
300 |
-
echo $third_party_scripts;
|
301 |
-
$cache_array['thirdparty']['header'] .= ob_get_clean();
|
302 |
-
|
303 |
-
ob_start();
|
304 |
-
$third_party_scripts = isset( $modal_options['moove_gdpr_third_party_body_scripts'] ) && $modal_options['moove_gdpr_third_party_body_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_third_party_body_scripts'] ) : '';
|
305 |
-
$third_party_scripts = apply_filters( 'moove_gdpr_third_party_body_assets', $third_party_scripts );
|
306 |
-
echo $third_party_scripts;
|
307 |
-
$cache_array['thirdparty']['body'] .= ob_get_clean();
|
308 |
-
|
309 |
-
ob_start();
|
310 |
-
$third_party_scripts = isset( $modal_options['moove_gdpr_third_party_footer_scripts'] ) && $modal_options['moove_gdpr_third_party_footer_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_third_party_footer_scripts'] ) : '';
|
311 |
-
$third_party_scripts = apply_filters( 'moove_gdpr_third_party_footer_assets', $third_party_scripts );
|
312 |
-
echo $third_party_scripts;
|
313 |
-
$cache_array['thirdparty']['footer'] .= ob_get_clean();
|
314 |
-
|
315 |
-
|
316 |
-
// ADVANCED - SCRIPT CACHE
|
317 |
-
ob_start();
|
318 |
-
$advanced_scripts = isset( $modal_options['moove_gdpr_advanced_cookies_header_scripts'] ) && $modal_options['moove_gdpr_advanced_cookies_header_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_advanced_cookies_header_scripts'] ) : '';
|
319 |
-
$advanced_scripts = apply_filters( 'moove_gdpr_advanced_cookies_header_assets', $advanced_scripts );
|
320 |
-
echo $advanced_scripts;
|
321 |
-
$cache_array['advanced']['header'] .= ob_get_clean();
|
322 |
-
|
323 |
-
ob_start();
|
324 |
-
$advanced_scripts = isset( $modal_options['moove_gdpr_advanced_cookies_body_scripts'] ) && $modal_options['moove_gdpr_advanced_cookies_body_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_advanced_cookies_body_scripts'] ) : '';
|
325 |
-
$advanced_scripts = apply_filters( 'moove_gdpr_advanced_cookies_body_assets', $advanced_scripts );
|
326 |
-
echo $advanced_scripts;
|
327 |
-
$cache_array['advanced']['body'] .= ob_get_clean();
|
328 |
-
|
329 |
-
|
330 |
-
ob_start();
|
331 |
-
$advanced_scripts = isset( $modal_options['moove_gdpr_advanced_cookies_footer_scripts'] ) && $modal_options['moove_gdpr_advanced_cookies_footer_scripts'] ? maybe_unserialize( $modal_options['moove_gdpr_advanced_cookies_footer_scripts'] ) : '';
|
332 |
-
$advanced_scripts = apply_filters( 'moove_gdpr_advanced_cookies_footer_assets', $advanced_scripts );
|
333 |
-
echo $advanced_scripts;
|
334 |
-
$cache_array['advanced']['footer'] .= ob_get_clean();
|
335 |
-
|
336 |
-
$cache_json = json_encode( $cache_array, true );
|
337 |
-
|
338 |
-
set_transient( $transient_key, $cache_json, 86400 );
|
339 |
-
$transient_from_cache = $cache_array;
|
340 |
-
endif;
|
341 |
-
|
342 |
-
$scripts_array = array(
|
343 |
-
'cache' => ! empty( $transient ),
|
344 |
-
'header' => '',
|
345 |
-
'body' => '',
|
346 |
-
'footer' => ''
|
347 |
-
);
|
348 |
-
|
349 |
-
if ( $strict === true ) :
|
350 |
-
$transient_from_cache = apply_filters('gdpr_lss_extension', $transient_from_cache);
|
351 |
-
if ( $thirdparty ) :
|
352 |
-
|
353 |
-
if ( isset( $transient_from_cache['thirdparty'] ) ) :
|
354 |
-
$scripts_array['header'] .= $transient_from_cache['thirdparty']['header'];
|
355 |
-
$scripts_array['body'] .= $transient_from_cache['thirdparty']['body'];
|
356 |
-
$scripts_array['footer'] .= $transient_from_cache['thirdparty']['footer'];
|
357 |
-
endif;
|
358 |
-
endif;
|
359 |
-
|
360 |
-
|
361 |
-
if ( $advanced ) :
|
362 |
-
if ( isset( $transient_from_cache['advanced'] ) ) :
|
363 |
-
$scripts_array['header'] .= $transient_from_cache['advanced']['header'];
|
364 |
-
$scripts_array['body'] .= $transient_from_cache['advanced']['body'];
|
365 |
-
$scripts_array['footer'] .= $transient_from_cache['advanced']['footer'];
|
366 |
-
endif;
|
367 |
-
endif;
|
368 |
-
else :
|
369 |
-
if (isset($_SERVER['HTTP_COOKIE'])) {
|
370 |
-
$cookies = explode(';', $_SERVER['HTTP_COOKIE']);
|
371 |
-
foreach($cookies as $cookie) {
|
372 |
-
$parts = explode('=', $cookie);
|
373 |
-
$name = trim($parts[0]);
|
374 |
-
setcookie($name, '', time()-1000);
|
375 |
-
setcookie($name, '', time()-1000, '/');
|
376 |
-
}
|
377 |
-
}
|
378 |
-
endif;
|
379 |
-
echo json_encode( $scripts_array );
|
380 |
-
die();
|
381 |
-
}
|
382 |
-
|
383 |
-
/**
|
384 |
-
* Removing all the cookies including www and non-www domains
|
385 |
-
*/
|
386 |
-
public static function moove_gdpr_remove_php_cookies() {
|
387 |
-
$urlparts = parse_url( site_url('/') );
|
388 |
-
$domain = preg_replace('/www\./i', '', $urlparts['host']);
|
389 |
-
if ( isset( $_COOKIE ) && is_array( $_COOKIE ) && $domain ) :
|
390 |
-
foreach ( $_COOKIE as $key => $value ) {
|
391 |
-
|
392 |
-
if ( $key == 'language' || $key=='currency' ) {
|
393 |
-
setcookie( $key, null, -1, '/', 'www.' . $domain );
|
394 |
-
} elseif ( $key=='_ga' || $key=='_gid' || $key=='_gat' ) {
|
395 |
-
setcookie( $key, null, -1, '/', '.' . $domain );
|
396 |
-
} else {
|
397 |
-
foreach ( $_COOKIE as $key => $value ) {
|
398 |
-
unset( $_COOKIE[$key] );
|
399 |
-
if ( $key=='language' || $key=='currency' ) {
|
400 |
-
setcookie( $key, null, -1, '/', 'www.' . $domain );
|
401 |
-
} elseif ( $key=='_ga' || $key=='_gid' || $key=='_gat' ) {
|
402 |
-
setcookie($key, null, -1, '/', '.' . $domain );
|
403 |
-
} else {
|
404 |
-
setcookie($key, null, -1, '/');
|
405 |
-
}
|
406 |
-
}
|
407 |
-
}
|
408 |
-
}
|
409 |
-
endif;
|
410 |
-
}
|
411 |
-
|
412 |
-
public static function moove_hide_language_notice() {
|
413 |
-
$user_id = isset( $_POST['user_id'] ) ? intval( $_POST['user_id'] ) : false;
|
414 |
-
if ( $user_id ) :
|
415 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
416 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
417 |
-
$modal_options = get_option( $option_name );
|
418 |
-
$modal_options['gdpr_hide_language_notice_' . $user_id ] = 1;
|
419 |
-
update_option( $option_name, $modal_options );
|
420 |
-
endif;
|
421 |
-
}
|
422 |
-
|
423 |
-
}
|
424 |
-
new Moove_GDPR_Controller();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
controllers/moove-license-manager.php
DELETED
@@ -1,189 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
3 |
-
/**
|
4 |
-
* Moove_License_Manager File Doc Comment
|
5 |
-
*
|
6 |
-
* @category Moove_License_Manager
|
7 |
-
* @package gdpr-cookie-compliance
|
8 |
-
* @author Gaspar Nemes
|
9 |
-
*/
|
10 |
-
|
11 |
-
/**
|
12 |
-
* Moove_License_Manager Class Doc Comment
|
13 |
-
*
|
14 |
-
* @category Class
|
15 |
-
* @package Moove_License_Manager
|
16 |
-
* @author Gaspar Nemes
|
17 |
-
*/
|
18 |
-
class Moove_GDPR_License_Manager {
|
19 |
-
/**
|
20 |
-
* Construct function
|
21 |
-
*/
|
22 |
-
public function __construct() {
|
23 |
-
|
24 |
-
}
|
25 |
-
|
26 |
-
public function validate_license( $license_key = false, $type, $action ) {
|
27 |
-
$content = new Moove_GDPR_Content();
|
28 |
-
$license_token = $content->get_license_token();
|
29 |
-
$curl = curl_init();
|
30 |
-
|
31 |
-
curl_setopt_array( $curl, array(
|
32 |
-
CURLOPT_URL => MOOVE_SHOP_URL."/wp-json/license-manager/v1/validate_licence/?license_key=$license_key&license_token=$license_token&license_type=$type&license_action=$action",
|
33 |
-
CURLOPT_RETURNTRANSFER => true,
|
34 |
-
CURLOPT_ENCODING => "",
|
35 |
-
CURLOPT_MAXREDIRS => 10,
|
36 |
-
CURLOPT_TIMEOUT => 30,
|
37 |
-
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
|
38 |
-
CURLOPT_CUSTOMREQUEST => "GET",
|
39 |
-
CURLOPT_HTTPHEADER => array(
|
40 |
-
"Accept: application/json",
|
41 |
-
"Content-Type: application/json",
|
42 |
-
"Content-length: 0",
|
43 |
-
),
|
44 |
-
));
|
45 |
-
|
46 |
-
$response = curl_exec( $curl );
|
47 |
-
|
48 |
-
|
49 |
-
$err = curl_error( $curl );
|
50 |
-
|
51 |
-
curl_close( $curl );
|
52 |
-
|
53 |
-
if ( $err || ! json_decode( $response, true ) ) {
|
54 |
-
$error = $err ? $err : $response;
|
55 |
-
return array(
|
56 |
-
'valid' => false,
|
57 |
-
'message' => array(
|
58 |
-
'Our Activation Server appears to be temporarily unavailable, please try again later or <a href="mailto:plugins@mooveagency.com" class="'.$type.'_admin_link">contact support</a>.',
|
59 |
-
)
|
60 |
-
);
|
61 |
-
} else {
|
62 |
-
return json_decode( $response, true );
|
63 |
-
}
|
64 |
-
}
|
65 |
-
|
66 |
-
public function get_add_on_plugin_slug() {
|
67 |
-
$slug = false;
|
68 |
-
if ( function_exists( 'moove_gdpr_addon_get_plugin_dir' ) ) :
|
69 |
-
$slug = str_replace( WP_PLUGIN_URL . '/', '', moove_gdpr_addon_get_plugin_dir() ) . '/moove-gdpr-addon.php';
|
70 |
-
else :
|
71 |
-
if ( ! function_exists( 'get_plugins' ) ) :
|
72 |
-
require_once ABSPATH . 'wp-admin/includes/plugin.php';
|
73 |
-
endif;
|
74 |
-
$all_plugins = get_plugins();
|
75 |
-
foreach ( $all_plugins as $plugin_slug => $plugin_details ) :
|
76 |
-
if ( $plugin_details['TextDomain'] === 'gdpr-cookie-compliance-addon' && is_plugin_active( $plugin_slug ) ) :
|
77 |
-
$slug = $plugin_slug;
|
78 |
-
endif;
|
79 |
-
endforeach;
|
80 |
-
$slug = $slug ? $slug : 'gdpr-cookie-compliance-addon/moove-gdpr-addon.php';
|
81 |
-
endif;
|
82 |
-
return $slug;
|
83 |
-
}
|
84 |
-
|
85 |
-
public function get_premium_add_on( $license_key = false, $action = 'check' ) {
|
86 |
-
$validate_license = $this->validate_license( $license_key, 'gdpr', $action );
|
87 |
-
if ( $validate_license && isset( $validate_license['valid'] ) && $validate_license['valid'] === true ) :
|
88 |
-
$plugin_token = isset( $validate_license['data'] ) && isset( $validate_license['data']['download_token'] ) && $validate_license['data']['download_token'] ? $validate_license['data']['download_token'] : false;
|
89 |
-
$is_valid_license = true;
|
90 |
-
if ( $plugin_token && $action === 'activate' ) :
|
91 |
-
$plugin_slug = $this->get_add_on_plugin_slug();
|
92 |
-
add_filter( 'upgrader_source_selection', array( &$this, 'upgrader_source_selection' ), 10, 4 );
|
93 |
-
if ( $plugin_slug ) :
|
94 |
-
if ( $this->is_plugin_installed( $plugin_slug ) ) {
|
95 |
-
$this->upgrade_plugin( $plugin_slug );
|
96 |
-
$installed = true;
|
97 |
-
} else {
|
98 |
-
$installed = $this->install_plugin( $plugin_token );
|
99 |
-
}
|
100 |
-
if ( ! is_wp_error( $installed ) && $installed ) {
|
101 |
-
$activate = activate_plugin( $plugin_slug );
|
102 |
-
} else {
|
103 |
-
// Could not install the new plugin;
|
104 |
-
}
|
105 |
-
endif;
|
106 |
-
remove_filter( 'upgrader_source_selection', array( &$this, 'upgrader_source_selection' ), 10, 4 );
|
107 |
-
endif;
|
108 |
-
endif;
|
109 |
-
return $validate_license;
|
110 |
-
}
|
111 |
-
|
112 |
-
/**
|
113 |
-
* Rename the plugin folder
|
114 |
-
*/
|
115 |
-
function upgrader_source_selection( $source, $remote_source, $upgrader, $hook_extra = null ) {
|
116 |
-
global $wp_filesystem;
|
117 |
-
$plugin = isset( $hook_extra['plugin'] ) ? $hook_extra['plugin'] : false;
|
118 |
-
|
119 |
-
$plugin_slug = $this->get_add_on_plugin_slug();
|
120 |
-
$temp_slug = basename( trailingslashit( $source ) );
|
121 |
-
$plugin_slug = explode('/', $plugin_slug);
|
122 |
-
$plugin_slug = isset( $plugin_slug[0] ) && $plugin_slug[0] ? $plugin_slug[0] : 'gdpr-cookie-compliance-addon';
|
123 |
-
|
124 |
-
if ( $temp_slug !== $plugin_slug ) :
|
125 |
-
$new_source = trailingslashit( $remote_source );
|
126 |
-
$new_source = str_replace( $temp_slug , $plugin_slug, $new_source );
|
127 |
-
$wp_filesystem->move( $source, $new_source );
|
128 |
-
return trailingslashit( $new_source );
|
129 |
-
endif;
|
130 |
-
return $source;
|
131 |
-
}
|
132 |
-
|
133 |
-
public function premium_deactivate( $license_key = false ) {
|
134 |
-
$validate_license = $this->validate_license( $license_key, 'gdpr', 'deactivate' );
|
135 |
-
if ( $validate_license && isset( $validate_license['valid'] ) && $validate_license['valid'] === true ) :
|
136 |
-
$plugin_slug = $this->get_add_on_plugin_slug();
|
137 |
-
if ( $plugin_slug ) :
|
138 |
-
if ( $this->is_plugin_installed( $plugin_slug ) ) :
|
139 |
-
deactivate_plugins( plugin_basename( $plugin_slug ) );
|
140 |
-
$deactivated = true;
|
141 |
-
endif;
|
142 |
-
endif;
|
143 |
-
endif;
|
144 |
-
return $validate_license;
|
145 |
-
}
|
146 |
-
|
147 |
-
public function is_plugin_installed( $slug = false ) {
|
148 |
-
if ( function_exists( 'moove_gdpr_addon_get_plugin_dir' ) ) :
|
149 |
-
return true;
|
150 |
-
endif;
|
151 |
-
|
152 |
-
if ( $slug ) :
|
153 |
-
|
154 |
-
if ( ! function_exists( 'get_plugins' ) ) {
|
155 |
-
require_once ABSPATH . 'wp-admin/includes/plugin.php';
|
156 |
-
}
|
157 |
-
$all_plugins = get_plugins();
|
158 |
-
|
159 |
-
if ( ! empty( $all_plugins[ $slug ] ) ) :
|
160 |
-
return true;
|
161 |
-
else :
|
162 |
-
return false;
|
163 |
-
endif;
|
164 |
-
endif;
|
165 |
-
return false;
|
166 |
-
}
|
167 |
-
|
168 |
-
public function install_plugin( $plugin_token ) {
|
169 |
-
include_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php';
|
170 |
-
wp_cache_flush();
|
171 |
-
$upgrader = new Plugin_Upgrader();
|
172 |
-
$installed = $upgrader->install( $plugin_token );
|
173 |
-
|
174 |
-
return $installed;
|
175 |
-
}
|
176 |
-
|
177 |
-
public function upgrade_plugin( $plugin_slug ) {
|
178 |
-
include_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php';
|
179 |
-
wp_cache_flush();
|
180 |
-
|
181 |
-
$upgrader = new Plugin_Upgrader();
|
182 |
-
$upgraded = $upgrader->upgrade( $plugin_slug );
|
183 |
-
|
184 |
-
return $upgraded;
|
185 |
-
}
|
186 |
-
|
187 |
-
|
188 |
-
}
|
189 |
-
new Moove_GDPR_License_Manager();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
controllers/moove-plugin-updater.php
DELETED
@@ -1,227 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
3 |
-
|
4 |
-
if ( ! class_exists( 'Moove_GDPR_Updater' ) ) {
|
5 |
-
class Moove_GDPR_Updater {
|
6 |
-
public $update_data = array();
|
7 |
-
public $active_plugins = array();
|
8 |
-
|
9 |
-
function __construct() {
|
10 |
-
add_action( 'gdpr_plugin_updater_notice', array( &$this, 'gdpr_plugin_updater_notice' ) );
|
11 |
-
global $pagenow;
|
12 |
-
$allowed_pages = array( 'update-core.php', 'plugins.php' );
|
13 |
-
$plugin_slug = false;
|
14 |
-
$lm = new Moove_GDPR_License_Manager();
|
15 |
-
$plugin_slug = $lm->get_add_on_plugin_slug();
|
16 |
-
if ( in_array( $pagenow, $allowed_pages ) ) :
|
17 |
-
$this->gdpr_plugin_updater_notice();
|
18 |
-
$this->gdpr_check_for_updates();
|
19 |
-
elseif ( ( $pagenow === 'admin.php' && isset( $_GET['page'] ) && $_GET['page'] === 'moove-gdpr' ) ) :
|
20 |
-
$this->gdpr_check_for_updates();
|
21 |
-
endif;
|
22 |
-
// add_action( 'admin_init', array( &$this, 'gdpr_check_for_updates' ) );
|
23 |
-
add_filter( 'plugins_api', array( &$this, 'plugins_api' ), 10, 3 );
|
24 |
-
add_filter( 'pre_set_site_transient_update_plugins', array( &$this, 'set_update_data' ) );
|
25 |
-
add_filter( 'upgrader_source_selection', array( &$this, 'upgrader_source_selection' ), 10, 4 );
|
26 |
-
if ( $plugin_slug ) :
|
27 |
-
add_action( "in_plugin_update_message-{$plugin_slug}", array( &$this, 'gdpr_update_message_content' ), 10, 2 );
|
28 |
-
endif;
|
29 |
-
}
|
30 |
-
|
31 |
-
function gdpr_update_message_content( $plugin_data, $response ) {
|
32 |
-
if ( isset( $plugin_data['package'] ) && ! $plugin_data['package'] ) :
|
33 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
34 |
-
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
35 |
-
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
36 |
-
$license_key = isset( $gdpr_key['key'] ) ? sanitize_text_field( $gdpr_key['key'] ) : false;
|
37 |
-
$renew_link = MOOVE_SHOP_URL . '?renew='.$license_key;
|
38 |
-
$license_manager = admin_url('admin.php') . '?page=moove-gdpr&tab=licence';
|
39 |
-
$purchase_link = 'https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/';
|
40 |
-
if ( $license_key && isset( $gdpr_key['activation'] ) ) :
|
41 |
-
// Expired
|
42 |
-
echo ' Update is not available until you <a href="'.$renew_link.'" target="_blank">renew your licence</a>. You can also update your licence key in the <a href="'.$license_manager.'" target="_blank">Licence Manager</a>.';
|
43 |
-
elseif ( $license_key && isset( $gdpr_key['deactivation'] ) ) :
|
44 |
-
// Deactivated
|
45 |
-
echo ' Update is not available until you <a href="'.$purchase_link.'" target="_blank">purchase a licence</a>. You can also update your licence key in the <a href="'.$license_manager.'" target="_blank">Licence Manager</a>.';
|
46 |
-
elseif ( ! $license_key ) :
|
47 |
-
// No license key installed
|
48 |
-
echo ' Update is not available until you <a href="'.$purchase_link.'" target="_blank">purchase a licence</a>. You can also update your licence key in the <a href="'.$license_manager.'" target="_blank">Licence Manager</a>.';
|
49 |
-
endif;
|
50 |
-
endif;
|
51 |
-
return array();
|
52 |
-
}
|
53 |
-
|
54 |
-
function gdpr_plugin_updater_notice() {
|
55 |
-
update_option( 'gpdr_last_checked', strtotime( 'yesterday' ) );
|
56 |
-
delete_site_transient('update_plugins');
|
57 |
-
}
|
58 |
-
|
59 |
-
function gdpr_check_for_updates() {
|
60 |
-
$this->update_data = get_option( 'gdpr_update_data' );
|
61 |
-
$active = get_option( 'active_plugins' );
|
62 |
-
$last_checked = get_option( 'gpdr_last_checked' );
|
63 |
-
$now = strtotime( 'now' );
|
64 |
-
$check_interval = 6 * HOUR_IN_SECONDS;
|
65 |
-
|
66 |
-
foreach ( $active as $slug ) :
|
67 |
-
$this->active_plugins[ $slug ] = true;
|
68 |
-
endforeach;
|
69 |
-
|
70 |
-
|
71 |
-
// transient expiration
|
72 |
-
if ( ( $now - $last_checked ) > $check_interval ) :
|
73 |
-
$this->update_data = $this->get_addon_updates();
|
74 |
-
update_option( 'gdpr_update_data', $this->update_data );
|
75 |
-
update_option( 'gpdr_last_checked', $now );
|
76 |
-
$plugins = get_site_transient( 'update_plugins' );
|
77 |
-
$lm = new Moove_GDPR_License_Manager();
|
78 |
-
$plugin_slug = $lm->get_add_on_plugin_slug();
|
79 |
-
|
80 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
81 |
-
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
82 |
-
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
83 |
-
$license_key = sanitize_text_field( $gdpr_key['key'] );
|
84 |
-
if ( $plugin_slug ) :
|
85 |
-
if ( $license_key && ! isset( $gdpr_key['deactivation'] ) ) :
|
86 |
-
if ( isset( $plugins->response[$plugin_slug] ) ) :
|
87 |
-
$plugins->response[$plugin_slug]->new_version = $this->update_data[$plugin_slug]['new_version'];
|
88 |
-
$plugins->response[$plugin_slug]->package = $this->update_data[$plugin_slug]['package'];
|
89 |
-
set_site_transient( 'update_plugins', $plugins );
|
90 |
-
endif;
|
91 |
-
else :
|
92 |
-
if ( isset( $plugins->response[$plugin_slug] ) ) :
|
93 |
-
$plugins->response[$plugin_slug]->new_version = $this->update_data[$plugin_slug]['new_version'];
|
94 |
-
$plugins->response[$plugin_slug]->package = '';
|
95 |
-
set_site_transient( 'update_plugins', $plugins );
|
96 |
-
endif;
|
97 |
-
endif;
|
98 |
-
endif;
|
99 |
-
endif;
|
100 |
-
}
|
101 |
-
|
102 |
-
|
103 |
-
/**
|
104 |
-
* Fetch the latest GitHub tags and build the plugin data array
|
105 |
-
*/
|
106 |
-
function get_addon_updates() {
|
107 |
-
$plugin_data = array();
|
108 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
109 |
-
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
110 |
-
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
111 |
-
$license_key = sanitize_text_field( $gdpr_key['key'] );
|
112 |
-
if ( $license_key ) :
|
113 |
-
|
114 |
-
$plugins = function_exists( 'get_plugins' ) ? get_plugins( ) : array();
|
115 |
-
foreach ( $plugins as $slug => $info ) :
|
116 |
-
if ( isset( $info['TextDomain'] ) && $info['TextDomain'] === 'gdpr-cookie-compliance-addon' ) :
|
117 |
-
$license_manager = new Moove_GDPR_License_Manager();
|
118 |
-
$is_valid_license = $license_manager->get_premium_add_on( $license_key, 'update' );
|
119 |
-
$temp = array(
|
120 |
-
'plugin' => $slug,
|
121 |
-
'slug' => trim( dirname( $slug ), '/' ),
|
122 |
-
'name' => $info['Name'],
|
123 |
-
'description' => $info['Description'],
|
124 |
-
'new_version' => false,
|
125 |
-
'package' => false,
|
126 |
-
);
|
127 |
-
if ( $is_valid_license && isset( $is_valid_license['valid'] ) ) :
|
128 |
-
|
129 |
-
$plugin_token = isset( $is_valid_license['data'] ) && isset( $is_valid_license['data']['download_token'] ) && $is_valid_license['data']['download_token'] ? $is_valid_license['data']['download_token'] : false;
|
130 |
-
$plugin_version = isset( $is_valid_license['data'] ) && isset( $is_valid_license['data']['version'] ) && $is_valid_license['data']['version'] ? $is_valid_license['data']['version'] : 0;
|
131 |
-
|
132 |
-
$temp['new_version'] = $plugin_version;
|
133 |
-
$temp['package'] = ! isset( $gdpr_key['deactivation'] ) ? $plugin_token : '';
|
134 |
-
|
135 |
-
endif;
|
136 |
-
$plugin_data[ $slug ] = $temp;
|
137 |
-
endif;
|
138 |
-
endforeach;
|
139 |
-
endif;
|
140 |
-
return $plugin_data;
|
141 |
-
}
|
142 |
-
|
143 |
-
|
144 |
-
/**
|
145 |
-
* Get plugin info for the "View Details" popup
|
146 |
-
*/
|
147 |
-
function plugins_api( $default = false, $action, $args ) {
|
148 |
-
if ( 'plugin_information' == $action ) {
|
149 |
-
$plugin_data = array();
|
150 |
-
$this->update_data = get_option( 'uat_update_data' );
|
151 |
-
if ( is_array( $this->update_data ) && ! empty( $this->update_data ) ) :
|
152 |
-
foreach ( $this->update_data as $slug => $data ) :
|
153 |
-
if ( $data['slug'] === $args->slug ) :
|
154 |
-
if ( class_exists( 'Moove_GDPR_Controller' ) ) :
|
155 |
-
$gdpr_controller = new Moove_GDPR_Controller();
|
156 |
-
$plugin_details = $gdpr_controller->get_gdpr_plugin_details( 'gdpr-cookie-compliance' );
|
157 |
-
unset( $plugin_details->sections['screenshot'] );
|
158 |
-
unset( $plugin_details->sections['changelog'] );
|
159 |
-
unset( $plugin_details->sections['installation'] );
|
160 |
-
$plugin_details->name = $data['name'];
|
161 |
-
$plugin_details->slug = $data['plugin'];
|
162 |
-
$plugin_details->version = $data['new_version'];
|
163 |
-
$plugin_details->last_updated = '';
|
164 |
-
$plugin_details->banners = array(
|
165 |
-
'high' => 'https://ps.w.org/gdpr-cookie-compliance/assets/banner-772x250.png'
|
166 |
-
);
|
167 |
-
return (object) $plugin_details;
|
168 |
-
endif;
|
169 |
-
endif;
|
170 |
-
endforeach;
|
171 |
-
endif;
|
172 |
-
}
|
173 |
-
return $default;
|
174 |
-
}
|
175 |
-
|
176 |
-
function set_update_data( $transient ) {
|
177 |
-
if ( empty( $transient->checked ) ) {
|
178 |
-
return $transient;
|
179 |
-
}
|
180 |
-
foreach ( $this->update_data as $plugin => $info ) {
|
181 |
-
if ( isset( $this->active_plugins[ $plugin ] ) ) {
|
182 |
-
$plugin_data = get_plugin_data( WP_PLUGIN_DIR . '/' . $plugin );
|
183 |
-
$version = $plugin_data['Version'];
|
184 |
-
|
185 |
-
if ( version_compare( $version, $info['new_version'], '<' ) ) {
|
186 |
-
$transient->response[ $plugin ] = (object) $info;
|
187 |
-
}
|
188 |
-
}
|
189 |
-
}
|
190 |
-
return $transient;
|
191 |
-
}
|
192 |
-
|
193 |
-
/**
|
194 |
-
* Rename the plugin folder
|
195 |
-
*/
|
196 |
-
function upgrader_source_selection( $source, $remote_source, $upgrader, $hook_extra = null ) {
|
197 |
-
global $wp_filesystem;
|
198 |
-
$plugin = isset( $hook_extra['plugin'] ) ? $hook_extra['plugin'] : false;
|
199 |
-
if ( isset( $this->update_data[ $plugin ] ) && $plugin ) :
|
200 |
-
$lm = new Moove_GDPR_License_Manager();
|
201 |
-
$plugin_slug = $lm->get_add_on_plugin_slug();
|
202 |
-
$temp_slug = basename( trailingslashit( $source ) );
|
203 |
-
$plugin_slug = explode('/', $plugin_slug);
|
204 |
-
$plugin_slug = isset( $plugin_slug[0] ) && $plugin_slug[0] ? $plugin_slug[0] : 'gdpr-cookie-compliance-addon';
|
205 |
-
|
206 |
-
if ( $temp_slug !== $plugin_slug ) :
|
207 |
-
$new_source = trailingslashit( $remote_source );
|
208 |
-
$new_source = str_replace( $temp_slug , $plugin_slug, $new_source );
|
209 |
-
$wp_filesystem->move( $source, $new_source );
|
210 |
-
return trailingslashit( $new_source );
|
211 |
-
endif;
|
212 |
-
endif;
|
213 |
-
return $source;
|
214 |
-
}
|
215 |
-
|
216 |
-
public function moove_hide_update_notice() {
|
217 |
-
$version = isset( $_POST['version'] ) ? sanitize_text_field( $_POST['version'] ) : false;
|
218 |
-
if ( $version ) :
|
219 |
-
$current_user = wp_get_current_user();
|
220 |
-
$user_id = isset( $current_user->ID ) ? $current_user->ID : false;
|
221 |
-
update_option( 'gdpr_hide_update_notice_' . $user_id, $version );
|
222 |
-
endif;
|
223 |
-
}
|
224 |
-
|
225 |
-
}
|
226 |
-
new Moove_GDPR_Updater();
|
227 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
dist/scripts/admin.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.postscribe=e():t.postscribe=e()}(this,function(){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return t[r].call(o.exports,o,o.exports,e),o.loaded=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){"use strict";var r=n(1),o=function(t){return t&&t.__esModule?t:{default:t}}(r);t.exports=o.default},function(t,e,n){"use strict";function r(){}function o(){var t=h.shift();if(t){var e=l.last(t);e.afterDequeue(),t.stream=i.apply(void 0,t),e.afterStreamStart()}}function i(t,e,n){function i(t){t=n.beforeWrite(t),m.write(t),n.afterWrite(t)}m=new u.default(t,n),m.id=f++,m.name=n.name||m.id,a.streams[m.name]=m;var c=t.ownerDocument,p={close:c.close,open:c.open,write:c.write,writeln:c.writeln};s(c,{close:r,open:r,write:function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];return i(e.join(""))},writeln:function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];return i(e.join("")+"\n")}});var l=m.win.onerror||r;return m.win.onerror=function(t,e,r){n.error({msg:t+" - "+e+": "+r}),l.apply(m.win,[t,e,r])},m.write(e,function(){s(c,p),m.win.onerror=l,n.done(),m=null,o()}),m}function a(t,e,n){if(l.isFunction(n))n={done:n};else if("clear"===n)return h=[],m=null,void(f=0);n=l.defaults(n,d),t=/^#/.test(t)?window.document.getElementById(t.substr(1)):t.jquery?t[0]:t;var i=[t,e,n];return t.postscribe={cancel:function(){i.stream?i.stream.abort():i[1]=r}},n.beforeEnqueue(i),h.push(i),m||o(),t.postscribe}e.__esModule=!0;var s=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};e.default=a;var c=n(2),u=function(t){return t&&t.__esModule?t:{default:t}}(c),p=n(4),l=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}(p),d={afterAsync:r,afterDequeue:r,afterStreamStart:r,afterWrite:r,autoFix:!0,beforeEnqueue:r,beforeWriteToken:function(t){return t},beforeWrite:function(t){return t},done:r,error:function(t){throw new Error(t.msg)},releaseAsync:!1},f=0,h=[],m=null;s(a,{streams:{},queue:h,WriteStream:u.default})},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){var n=l+e,r=t.getAttribute(n);return p.existy(r)?String(r):r}function i(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=l+e;p.existy(n)&&""!==n?t.setAttribute(r,n):t.removeAttribute(r)}e.__esModule=!0;var a=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},s=n(3),c=function(t){return t&&t.__esModule?t:{default:t}}(s),u=n(4),p=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}(u),l="data-ps-",d="ps-style",f="ps-script",h=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};r(this,t),this.root=e,this.options=n,this.doc=e.ownerDocument,this.win=this.doc.defaultView||this.doc.parentWindow,this.parser=new c.default("",{autoFix:n.autoFix}),this.actuals=[e],this.proxyHistory="",this.proxyRoot=this.doc.createElement(e.nodeName),this.scriptStack=[],this.writeQueue=[],i(this.proxyRoot,"proxyof",0)}return t.prototype.write=function(){var t;for((t=this.writeQueue).push.apply(t,arguments);!this.deferredRemote&&this.writeQueue.length;){var e=this.writeQueue.shift();p.isFunction(e)?this._callFunction(e):this._writeImpl(e)}},t.prototype._callFunction=function(t){var e={type:"function",value:t.name||t.toString()};this._onScriptStart(e),t.call(this.win,this.doc),this._onScriptDone(e)},t.prototype._writeImpl=function(t){this.parser.append(t);for(var e=void 0,n=void 0,r=void 0,o=[];(e=this.parser.readToken())&&!(n=p.isScript(e))&&!(r=p.isStyle(e));)(e=this.options.beforeWriteToken(e))&&o.push(e);o.length>0&&this._writeStaticTokens(o),n&&this._handleScriptToken(e),r&&this._handleStyleToken(e)},t.prototype._writeStaticTokens=function(t){var e=this._buildChunk(t);return e.actual?(e.html=this.proxyHistory+e.actual,this.proxyHistory+=e.proxy,this.proxyRoot.innerHTML=e.html,this._walkChunk(),e):null},t.prototype._buildChunk=function(t){for(var e=this.actuals.length,n=[],r=[],o=[],i=t.length,a=0;a<i;a++){var s=t[a],c=s.toString();if(n.push(c),s.attrs){if(!/^noscript$/i.test(s.tagName)){var u=e++;r.push(c.replace(/(\/?>)/," "+l+"id="+u+" $1")),s.attrs.id!==f&&s.attrs.id!==d&&o.push("atomicTag"===s.type?"":"<"+s.tagName+" "+l+"proxyof="+u+(s.unary?" />":">"))}}else r.push(c),o.push("endTag"===s.type?c:"")}return{tokens:t,raw:n.join(""),actual:r.join(""),proxy:o.join("")}},t.prototype._walkChunk=function(){for(var t=void 0,e=[this.proxyRoot];p.existy(t=e.shift());){var n=1===t.nodeType;if(!(n&&o(t,"proxyof"))){n&&(this.actuals[o(t,"id")]=t,i(t,"id"));var r=t.parentNode&&o(t.parentNode,"proxyof");r&&this.actuals[r].appendChild(t)}e.unshift.apply(e,p.toArray(t.childNodes))}},t.prototype._handleScriptToken=function(t){var e=this,n=this.parser.clear();n&&this.writeQueue.unshift(n),t.src=t.attrs.src||t.attrs.SRC,(t=this.options.beforeWriteToken(t))&&(t.src&&this.scriptStack.length?this.deferredRemote=t:this._onScriptStart(t),this._writeScriptToken(t,function(){e._onScriptDone(t)}))},t.prototype._handleStyleToken=function(t){var e=this.parser.clear();e&&this.writeQueue.unshift(e),t.type=t.attrs.type||t.attrs.TYPE||"text/css",t=this.options.beforeWriteToken(t),t&&this._writeStyleToken(t),e&&this.write()},t.prototype._writeStyleToken=function(t){var e=this._buildStyle(t);this._insertCursor(e,d),t.content&&(e.styleSheet&&!e.sheet?e.styleSheet.cssText=t.content:e.appendChild(this.doc.createTextNode(t.content)))},t.prototype._buildStyle=function(t){var e=this.doc.createElement(t.tagName);return e.setAttribute("type",t.type),p.eachKey(t.attrs,function(t,n){e.setAttribute(t,n)}),e},t.prototype._insertCursor=function(t,e){this._writeImpl('<span id="'+e+'"/>');var n=this.doc.getElementById(e);n&&n.parentNode.replaceChild(t,n)},t.prototype._onScriptStart=function(t){t.outerWrites=this.writeQueue,this.writeQueue=[],this.scriptStack.unshift(t)},t.prototype._onScriptDone=function(t){return t!==this.scriptStack[0]?void this.options.error({msg:"Bad script nesting or script finished twice"}):(this.scriptStack.shift(),this.write.apply(this,t.outerWrites),void(!this.scriptStack.length&&this.deferredRemote&&(this._onScriptStart(this.deferredRemote),this.deferredRemote=null)))},t.prototype._writeScriptToken=function(t,e){var n=this._buildScript(t),r=this._shouldRelease(n),o=this.options.afterAsync;t.src&&(n.src=t.src,this._scriptLoadHandler(n,r?o:function(){e(),o()}));try{this._insertCursor(n,f),n.src&&!r||e()}catch(t){this.options.error(t),e()}},t.prototype._buildScript=function(t){var e=this.doc.createElement(t.tagName);return p.eachKey(t.attrs,function(t,n){e.setAttribute(t,n)}),t.content&&(e.text=t.content),e},t.prototype._scriptLoadHandler=function(t,e){function n(){t=t.onload=t.onreadystatechange=t.onerror=null}function r(){n(),null!=e&&e(),e=null}function o(t){n(),s(t),null!=e&&e(),e=null}function i(t,e){var n=t["on"+e];null!=n&&(t["_on"+e]=n)}var s=this.options.error;i(t,"load"),i(t,"error"),a(t,{onload:function(){if(t._onload)try{t._onload.apply(this,Array.prototype.slice.call(arguments,0))}catch(e){o({msg:"onload handler failed "+e+" @ "+t.src})}r()},onerror:function(){if(t._onerror)try{t._onerror.apply(this,Array.prototype.slice.call(arguments,0))}catch(e){return void o({msg:"onerror handler failed "+e+" @ "+t.src})}o({msg:"remote script failed "+t.src})},onreadystatechange:function(){/^(loaded|complete)$/.test(t.readyState)&&r()}})},t.prototype._shouldRelease=function(t){return!/^script$/i.test(t.nodeName)||!!(this.options.releaseAsync&&t.src&&t.hasAttribute("async"))},t}();e.default=h},function(t,e,n){!function(e,n){t.exports=function(){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return t[r].call(o.exports,o,o.exports,e),o.loaded=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){"use strict";var r=n(1),o=function(t){return t&&t.__esModule?t:{default:t}}(r);t.exports=o.default},function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}e.__esModule=!0;var i=n(2),a=r(i),s=n(3),c=r(s),u=n(6),p=function(t){return t&&t.__esModule?t:{default:t}}(u),l=n(5),d={comment:/^<!--/,endTag:/^<\//,atomicTag:/^<\s*(script|style|noscript|iframe|textarea)[\s\/>]/i,startTag:/^</,chars:/^[^<]/},f=function(){function t(){var e=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};o(this,t),this.stream=n;var i=!1,s={};for(var c in a)a.hasOwnProperty(c)&&(r.autoFix&&(s[c+"Fix"]=!0),i=i||s[c+"Fix"]);i?(this._readToken=(0,p.default)(this,s,function(){return e._readTokenImpl()}),this._peekToken=(0,p.default)(this,s,function(){return e._peekTokenImpl()})):(this._readToken=this._readTokenImpl,this._peekToken=this._peekTokenImpl)}return t.prototype.append=function(t){this.stream+=t},t.prototype.prepend=function(t){this.stream=t+this.stream},t.prototype._readTokenImpl=function(){var t=this._peekTokenImpl();if(t)return this.stream=this.stream.slice(t.length),t},t.prototype._peekTokenImpl=function(){for(var t in d)if(d.hasOwnProperty(t)&&d[t].test(this.stream)){var e=c[t](this.stream);if(e)return"startTag"===e.type&&/script|style/i.test(e.tagName)?null:(e.text=this.stream.substr(0,e.length),e)}},t.prototype.peekToken=function(){return this._peekToken()},t.prototype.readToken=function(){return this._readToken()},t.prototype.readTokens=function(t){for(var e=void 0;e=this.readToken();)if(t[e.type]&&!1===t[e.type](e))return},t.prototype.clear=function(){var t=this.stream;return this.stream="",t},t.prototype.rest=function(){return this.stream},t}();e.default=f,f.tokenToString=function(t){return t.toString()},f.escapeAttributes=function(t){var e={};for(var n in t)t.hasOwnProperty(n)&&(e[n]=(0,l.escapeQuotes)(t[n],null));return e},f.supports=a;for(var h in a)a.hasOwnProperty(h)&&(f.browserHasFlaw=f.browserHasFlaw||!a[h]&&h)},function(t,e){"use strict";e.__esModule=!0;var n=!1,r=!1,o=window.document.createElement("div");try{var i="<P><I></P></I>";o.innerHTML=i,e.tagSoup=n=o.innerHTML!==i}catch(t){e.tagSoup=n=!1}try{o.innerHTML="<P><i><P></P></i></P>",e.selfClose=r=2===o.childNodes.length}catch(t){e.selfClose=r=!1}o=null,e.tagSoup=n,e.selfClose=r},function(t,e,n){"use strict";function r(t){var e=t.indexOf("--\x3e");if(e>=0)return new u.CommentToken(t.substr(4,e-1),e+3)}function o(t){var e=t.indexOf("<");return new u.CharsToken(e>=0?e:t.length)}function i(t){if(-1!==t.indexOf(">")){var e=t.match(p.startTag);if(e){var n=function(){var t={},n={},r=e[2];return e[2].replace(p.attr,function(e,o){arguments[2]||arguments[3]||arguments[4]||arguments[5]?arguments[5]?(t[arguments[5]]="",n[arguments[5]]=!0):t[o]=arguments[2]||arguments[3]||arguments[4]||p.fillAttr.test(o)&&o||"":t[o]="",r=r.replace(e,"")}),{v:new u.StartTagToken(e[1],e[0].length,t,n,!!e[3],r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""))}}();if("object"===(void 0===n?"undefined":c(n)))return n.v}}}function a(t){var e=i(t);if(e){var n=t.slice(e.length);if(n.match(new RegExp("</\\s*"+e.tagName+"\\s*>","i"))){var r=n.match(new RegExp("([\\s\\S]*?)</\\s*"+e.tagName+"\\s*>","i"));if(r)return new u.AtomicTagToken(e.tagName,r[0].length+e.length,e.attrs,e.booleanAttrs,r[1])}}}function s(t){var e=t.match(p.endTag);if(e)return new u.EndTagToken(e[1],e[0].length)}e.__esModule=!0;var c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};e.comment=r,e.chars=o,e.startTag=i,e.atomicTag=a,e.endTag=s;var u=n(4),p={startTag:/^<([\-A-Za-z0-9_]+)((?:\s+[\w\-]+(?:\s*=?\s*(?:(?:"[^"]*")|(?:'[^']*')|[^>\s]+))?)*)\s*(\/?)>/,endTag:/^<\/([\-A-Za-z0-9_]+)[^>]*>/,attr:/(?:([\-A-Za-z0-9_]+)\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|([^>\s]+)))|(?:([\-A-Za-z0-9_]+)(\s|$)+)/g,fillAttr:/^(checked|compact|declare|defer|disabled|ismap|multiple|nohref|noresize|noshade|nowrap|readonly|selected)$/i}},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}e.__esModule=!0,e.EndTagToken=e.AtomicTagToken=e.StartTagToken=e.TagToken=e.CharsToken=e.CommentToken=e.Token=void 0;var o=n(5),i=(e.Token=function t(e,n){r(this,t),this.type=e,this.length=n,this.text=""},e.CommentToken=function(){function t(e,n){r(this,t),this.type="comment",this.length=n||(e?e.length:0),this.text="",this.content=e}return t.prototype.toString=function(){return"\x3c!--"+this.content},t}(),e.CharsToken=function(){function t(e){r(this,t),this.type="chars",this.length=e,this.text=""}return t.prototype.toString=function(){return this.text},t}(),e.TagToken=function(){function t(e,n,o,i,a){r(this,t),this.type=e,this.length=o,this.text="",this.tagName=n,this.attrs=i,this.booleanAttrs=a,this.unary=!1,this.html5Unary=!1}return t.formatTag=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n="<"+t.tagName;for(var r in t.attrs)if(t.attrs.hasOwnProperty(r)){n+=" "+r;var i=t.attrs[r];void 0!==t.booleanAttrs&&void 0!==t.booleanAttrs[r]||(n+='="'+(0,o.escapeQuotes)(i)+'"')}return t.rest&&(n+=" "+t.rest),n+=t.unary&&!t.html5Unary?"/>":">",void 0!==e&&null!==e&&(n+=e+"</"+t.tagName+">"),n},t}());e.StartTagToken=function(){function t(e,n,o,i,a,s){r(this,t),this.type="startTag",this.length=n,this.text="",this.tagName=e,this.attrs=o,this.booleanAttrs=i,this.html5Unary=!1,this.unary=a,this.rest=s}return t.prototype.toString=function(){return i.formatTag(this)},t}(),e.AtomicTagToken=function(){function t(e,n,o,i,a){r(this,t),this.type="atomicTag",this.length=n,this.text="",this.tagName=e,this.attrs=o,this.booleanAttrs=i,this.unary=!1,this.html5Unary=!1,this.content=a}return t.prototype.toString=function(){return i.formatTag(this,this.content)},t}(),e.EndTagToken=function(){function t(e,n){r(this,t),this.type="endTag",this.length=n,this.text="",this.tagName=e}return t.prototype.toString=function(){return"</"+this.tagName+">"},t}()},function(t,e){"use strict";function n(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return t?t.replace(/([^"]*)"/g,function(t,e){return/\\/.test(e)?e+'"':e+'\\"'}):e}e.__esModule=!0,e.escapeQuotes=n},function(t,e){"use strict";function n(t){return t&&"startTag"===t.type&&(t.unary=s.test(t.tagName)||t.unary,t.html5Unary=!/\/>$/.test(t.text)),t}function r(t,e){var r=t.stream,o=n(e());return t.stream=r,o}function o(t,e){var n=e.pop();t.prepend("</"+n.tagName+">")}function i(){var t=[];return t.last=function(){return this[this.length-1]},t.lastTagNameEq=function(t){var e=this.last();return e&&e.tagName&&e.tagName.toUpperCase()===t.toUpperCase()},t.containsTagName=function(t){for(var e,n=0;e=this[n];n++)if(e.tagName===t)return!0;return!1},t}function a(t,e,a){function s(){var e=r(t,a);e&&p[e.type]&&p[e.type](e)}var u=i(),p={startTag:function(n){var r=n.tagName;"TR"===r.toUpperCase()&&u.lastTagNameEq("TABLE")?(t.prepend("<TBODY>"),s()):e.selfCloseFix&&c.test(r)&&u.containsTagName(r)?u.lastTagNameEq(r)?o(t,u):(t.prepend("</"+n.tagName+">"),s()):n.unary||u.push(n)},endTag:function(n){u.last()?e.tagSoupFix&&!u.lastTagNameEq(n.tagName)?o(t,u):u.pop():e.tagSoupFix&&(a(),s())}};return function(){return s(),n(a())}}e.__esModule=!0,e.default=a;var s=/^(AREA|BASE|BASEFONT|BR|COL|FRAME|HR|IMG|INPUT|ISINDEX|LINK|META|PARAM|EMBED)$/i,c=/^(COLGROUP|DD|DT|LI|OPTIONS|P|TD|TFOOT|TH|THEAD|TR)$/i}])}()}()},function(t,e){"use strict";function n(t){return void 0!==t&&null!==t}function r(t){return"function"==typeof t}function o(t,e,n){var r=void 0,o=t&&t.length||0;for(r=0;r<o;r++)e.call(n,t[r],r)}function i(t,e,n){for(var r in t)t.hasOwnProperty(r)&&e.call(n,r,t[r])}function a(t,e){return t=t||{},i(e,function(e,r){n(t[e])||(t[e]=r)}),t}function s(t){try{return Array.prototype.slice.call(t)}catch(n){var e=function(){var e=[];return o(t,function(t){e.push(t)}),{v:e}}();if("object"===(void 0===e?"undefined":d(e)))return e.v}}function c(t){return t[t.length-1]}function u(t,e){return!(!t||"startTag"!==t.type&&"atomicTag"!==t.type||!("tagName"in t)||!~t.tagName.toLowerCase().indexOf(e))}function p(t){return u(t,"script")}function l(t){return u(t,"style")}e.__esModule=!0;var d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};e.existy=n,e.isFunction=r,e.each=o,e.eachKey=i,e.defaults=a,e.toArray=s,e.last=c,e.isTag=u,e.isScript=p,e.isStyle=l}])}),function(t){var e={common:{init:function(){t(document).on("click",".gdpr-help-content-cnt .gdpr-faq-toggle h3",function(){var e=t(this).closest(".gdpr-faq-toggle");e.hasClass("gdpr-faq-open")?e.removeClass("gdpr-faq-open").find(".gdpr-faq-accordion-content").slideUp(200):(e.closest(".gdpr-help-content-block").find(".gdpr-faq-open").each(function(){t(this).find(".gdpr-faq-accordion-content").slideUp(200),t(this).removeClass("gdpr-faq-open")}),e.addClass("gdpr-faq-open").find(".gdpr-faq-accordion-content").slideDown(200))});var e=!1;t(document).on("click",".button-gdpr-deactivate-licence, .gdpr_deactivate_license_key",function(n){e?t(this).closest("form").submit():(n.preventDefault(),t(".gdpr-admin-popup.gdpr-admin-popup-deactivate").fadeIn(200))}),t(document).on("click",".gdpr-admin-popup .gdpr-popup-overlay, .gdpr-admin-popup .gdpr-popup-close",function(e){e.preventDefault(),t(this).closest(".gdpr-admin-popup").fadeOut(200)}),t(document).on("click",".gdpr-admin-popup.gdpr-admin-popup-deactivate .button-deactivate-confirm",function(n){n.preventDefault(),e=!0;var r=t("#moove_gdpr_license_settings").attr("data-key");t("<input type='hidden' value='1' />").attr("id","gdpr_deactivate_license").attr("name","gdpr_deactivate_license").appendTo("#moove_gdpr_license_settings"),t("#moove_gdpr_license_key").val(r),t("#moove_gdpr_license_settings").submit(),t("#moove_gdpr_license_key").val(""),t(this).closest(".gdpr-admin-popup").fadeOut(200)}),t(document).on("click",".gdpr-cookie-alert .gdpr-dismiss",function(e){e.preventDefault(),t(this).closest(".gdpr-cookie-alert").slideUp(400);var n=t(this).attr("data-adminajax"),r=t(this).attr("data-uid");jQuery.post(n,{action:"moove_hide_language_notice",user_id:r},function(t){})}),t(document).on("click",".gdpr-cookie-update-alert .gdpr-dismiss-update",function(e){e.preventDefault(),t(this).closest(".gdpr-cookie-alert").slideUp(400);var n=t(this).attr("data-adminajax"),r=t(this).attr("data-version");jQuery.post(n,{action:"moove_hide_update_notice",version:r},function(t){})}),t(document).on("click","a.gdpr-help-tab-toggle",function(e){e.preventDefault();var n=t(this).attr("href");t(n).length>0&&(t(".gdpr-help-content-block").slideUp(),t(n).slideDown(),t(".gdpr-help-tab-toggle").removeClass("active"),t(this).addClass("active"))}),t(document).on("click",".gdpr-script-tab-content .gdpr-tab-code-section-nav li > a ",function(e){e.preventDefault();var n=t(this).attr("href");t(this).closest(".gdpr-script-tab-content").find(".gdpr-active").removeClass("gdpr-active"),t(this).addClass("gdpr-active"),t(n).addClass("gdpr-active")}),t(document).find(".gdpr-conditional-field").each(function(){var e=t(this).attr("data-dependency");t(e).is(":checked")?t(this).addClass("gdpr-conditional-on"):t(this).removeClass("gdpr-conditional-on")}),t(document).on("change",'.gdpr-checkbox-toggle input[type="checkbox"]',function(){t(this).is(":checked")?t(document).find('.gdpr-conditional-field[data-dependency="#'+t(this).attr("id")+'"]').addClass("gdpr-conditional-on"):t(document).find('.gdpr-conditional-field[data-dependency="#'+t(this).attr("id")+'"]').removeClass("gdpr-conditional-on")}),t(document).on("keyup","input[name=moove_gdpr_company_logo]",function(){t(".moove_gdpr_company_logo_holder").css("background-image","url("+t(this).val()+")")}),t(document).on("change",'input[name="moove_gdpr_plugin_font_type"]',function(){"1"===t(this).val()||"2"===t(this).val()?t("#moove_gdpr_plugin_font_family").addClass("moove-not-visible"):t("#moove_gdpr_plugin_font_family").removeClass("moove-not-visible")}),t("#moove_form_checker_wrap .iris-colorpicker").each(function(){t(this).iris({width:300,hide:!0,change:function(e,n){t(this).css("background",n.color.toString())}}).on("click",function(){t(this).iris("toggle")}),t(this).iris("color",t(this).val())}),t(document).on("click",".iris-selectbtn",function(){t(this).parent().find(".iris-colorpicker").iris("toggle")}),t(document).on("click",".iris-picker:visible",function(){t(".iris-colorpicker").iris("hide")}),t(document).on("click",'#moove_gdpr_tab_advanced_cookies button[type="submit"]',function(e){var n=0,r=0;if("on"===t('input[name="moove_gdpr_advanced_cookies_enable"]:checked').val()&&(t(".gdpr-script-tab-content").find("textarea.code").each(function(){t.trim(t(this).val())||n++,r++}),r-n<1)){e.preventDefault();var o=t(".gdpr-script-tab-content").addClass("moove-gdpr-form-error").find(".alert.script-error").show();t("html, body").animate({scrollTop:o.offset().top-100},200)}}),t(document).on("click",'#moove_gdpr_tab_third_party_cookies button[type="submit"]',function(e){var n=0,r=0;if("on"===t('input[name="moove_gdpr_third_party_cookies_enable"]:checked').val()&&(t(".gdpr-script-tab-content").find("textarea.code").each(function(){t.trim(t(this).val())||n++,r++}),r-n<1)){e.preventDefault();var o=t(".gdpr-script-tab-content").addClass("moove-gdpr-form-error").find(".alert.script-error").show();t("html, body").animate({scrollTop:o.offset().top-100},200)}})},finalize:function(){}},home:{init:function(){},finalize:function(){}},about_us:{init:function(){}}},n={fire:function(t,n,r){var o,i=e;n=void 0===n?"init":n,o=""!==t,o=o&&i[t],(o=o&&"function"==typeof i[t][n])&&i[t][n](r)},loadEvents:function(){n.fire("common"),t.each(document.body.className.replace(/-/g,"_").split(/\s+/),function(t,e){n.fire(e),n.fire(e,"finalize")}),n.fire("common","finalize")}};t(document).ready(n.loadEvents)}(jQuery);
|
1 |
+
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.postscribe=e():t.postscribe=e()}(this,function(){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return t[r].call(o.exports,o,o.exports,e),o.loaded=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){"use strict";var r=n(1),o=function(t){return t&&t.__esModule?t:{default:t}}(r);t.exports=o.default},function(t,e,n){"use strict";function r(){}function o(){var t=h.shift();if(t){var e=l.last(t);e.afterDequeue(),t.stream=i.apply(void 0,t),e.afterStreamStart()}}function i(t,e,n){function i(t){t=n.beforeWrite(t),m.write(t),n.afterWrite(t)}m=new u.default(t,n),m.id=f++,m.name=n.name||m.id,a.streams[m.name]=m;var c=t.ownerDocument,p={close:c.close,open:c.open,write:c.write,writeln:c.writeln};s(c,{close:r,open:r,write:function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];return i(e.join(""))},writeln:function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];return i(e.join("")+"\n")}});var l=m.win.onerror||r;return m.win.onerror=function(t,e,r){n.error({msg:t+" - "+e+": "+r}),l.apply(m.win,[t,e,r])},m.write(e,function(){s(c,p),m.win.onerror=l,n.done(),m=null,o()}),m}function a(t,e,n){if(l.isFunction(n))n={done:n};else if("clear"===n)return h=[],m=null,void(f=0);n=l.defaults(n,d),t=/^#/.test(t)?window.document.getElementById(t.substr(1)):t.jquery?t[0]:t;var i=[t,e,n];return t.postscribe={cancel:function(){i.stream?i.stream.abort():i[1]=r}},n.beforeEnqueue(i),h.push(i),m||o(),t.postscribe}e.__esModule=!0;var s=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};e.default=a;var c=n(2),u=function(t){return t&&t.__esModule?t:{default:t}}(c),p=n(4),l=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}(p),d={afterAsync:r,afterDequeue:r,afterStreamStart:r,afterWrite:r,autoFix:!0,beforeEnqueue:r,beforeWriteToken:function(t){return t},beforeWrite:function(t){return t},done:r,error:function(t){throw new Error(t.msg)},releaseAsync:!1},f=0,h=[],m=null;s(a,{streams:{},queue:h,WriteStream:u.default})},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){var n=l+e,r=t.getAttribute(n);return p.existy(r)?String(r):r}function i(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=l+e;p.existy(n)&&""!==n?t.setAttribute(r,n):t.removeAttribute(r)}e.__esModule=!0;var a=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},s=n(3),c=function(t){return t&&t.__esModule?t:{default:t}}(s),u=n(4),p=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}(u),l="data-ps-",d="ps-style",f="ps-script",h=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};r(this,t),this.root=e,this.options=n,this.doc=e.ownerDocument,this.win=this.doc.defaultView||this.doc.parentWindow,this.parser=new c.default("",{autoFix:n.autoFix}),this.actuals=[e],this.proxyHistory="",this.proxyRoot=this.doc.createElement(e.nodeName),this.scriptStack=[],this.writeQueue=[],i(this.proxyRoot,"proxyof",0)}return t.prototype.write=function(){var t;for((t=this.writeQueue).push.apply(t,arguments);!this.deferredRemote&&this.writeQueue.length;){var e=this.writeQueue.shift();p.isFunction(e)?this._callFunction(e):this._writeImpl(e)}},t.prototype._callFunction=function(t){var e={type:"function",value:t.name||t.toString()};this._onScriptStart(e),t.call(this.win,this.doc),this._onScriptDone(e)},t.prototype._writeImpl=function(t){this.parser.append(t);for(var e=void 0,n=void 0,r=void 0,o=[];(e=this.parser.readToken())&&!(n=p.isScript(e))&&!(r=p.isStyle(e));)(e=this.options.beforeWriteToken(e))&&o.push(e);o.length>0&&this._writeStaticTokens(o),n&&this._handleScriptToken(e),r&&this._handleStyleToken(e)},t.prototype._writeStaticTokens=function(t){var e=this._buildChunk(t);return e.actual?(e.html=this.proxyHistory+e.actual,this.proxyHistory+=e.proxy,this.proxyRoot.innerHTML=e.html,this._walkChunk(),e):null},t.prototype._buildChunk=function(t){for(var e=this.actuals.length,n=[],r=[],o=[],i=t.length,a=0;a<i;a++){var s=t[a],c=s.toString();if(n.push(c),s.attrs){if(!/^noscript$/i.test(s.tagName)){var u=e++;r.push(c.replace(/(\/?>)/," "+l+"id="+u+" $1")),s.attrs.id!==f&&s.attrs.id!==d&&o.push("atomicTag"===s.type?"":"<"+s.tagName+" "+l+"proxyof="+u+(s.unary?" />":">"))}}else r.push(c),o.push("endTag"===s.type?c:"")}return{tokens:t,raw:n.join(""),actual:r.join(""),proxy:o.join("")}},t.prototype._walkChunk=function(){for(var t=void 0,e=[this.proxyRoot];p.existy(t=e.shift());){var n=1===t.nodeType;if(!(n&&o(t,"proxyof"))){n&&(this.actuals[o(t,"id")]=t,i(t,"id"));var r=t.parentNode&&o(t.parentNode,"proxyof");r&&this.actuals[r].appendChild(t)}e.unshift.apply(e,p.toArray(t.childNodes))}},t.prototype._handleScriptToken=function(t){var e=this,n=this.parser.clear();n&&this.writeQueue.unshift(n),t.src=t.attrs.src||t.attrs.SRC,(t=this.options.beforeWriteToken(t))&&(t.src&&this.scriptStack.length?this.deferredRemote=t:this._onScriptStart(t),this._writeScriptToken(t,function(){e._onScriptDone(t)}))},t.prototype._handleStyleToken=function(t){var e=this.parser.clear();e&&this.writeQueue.unshift(e),t.type=t.attrs.type||t.attrs.TYPE||"text/css",t=this.options.beforeWriteToken(t),t&&this._writeStyleToken(t),e&&this.write()},t.prototype._writeStyleToken=function(t){var e=this._buildStyle(t);this._insertCursor(e,d),t.content&&(e.styleSheet&&!e.sheet?e.styleSheet.cssText=t.content:e.appendChild(this.doc.createTextNode(t.content)))},t.prototype._buildStyle=function(t){var e=this.doc.createElement(t.tagName);return e.setAttribute("type",t.type),p.eachKey(t.attrs,function(t,n){e.setAttribute(t,n)}),e},t.prototype._insertCursor=function(t,e){this._writeImpl('<span id="'+e+'"/>');var n=this.doc.getElementById(e);n&&n.parentNode.replaceChild(t,n)},t.prototype._onScriptStart=function(t){t.outerWrites=this.writeQueue,this.writeQueue=[],this.scriptStack.unshift(t)},t.prototype._onScriptDone=function(t){return t!==this.scriptStack[0]?void this.options.error({msg:"Bad script nesting or script finished twice"}):(this.scriptStack.shift(),this.write.apply(this,t.outerWrites),void(!this.scriptStack.length&&this.deferredRemote&&(this._onScriptStart(this.deferredRemote),this.deferredRemote=null)))},t.prototype._writeScriptToken=function(t,e){var n=this._buildScript(t),r=this._shouldRelease(n),o=this.options.afterAsync;t.src&&(n.src=t.src,this._scriptLoadHandler(n,r?o:function(){e(),o()}));try{this._insertCursor(n,f),n.src&&!r||e()}catch(t){this.options.error(t),e()}},t.prototype._buildScript=function(t){var e=this.doc.createElement(t.tagName);return p.eachKey(t.attrs,function(t,n){e.setAttribute(t,n)}),t.content&&(e.text=t.content),e},t.prototype._scriptLoadHandler=function(t,e){function n(){t=t.onload=t.onreadystatechange=t.onerror=null}function r(){n(),null!=e&&e(),e=null}function o(t){n(),s(t),null!=e&&e(),e=null}function i(t,e){var n=t["on"+e];null!=n&&(t["_on"+e]=n)}var s=this.options.error;i(t,"load"),i(t,"error"),a(t,{onload:function(){if(t._onload)try{t._onload.apply(this,Array.prototype.slice.call(arguments,0))}catch(e){o({msg:"onload handler failed "+e+" @ "+t.src})}r()},onerror:function(){if(t._onerror)try{t._onerror.apply(this,Array.prototype.slice.call(arguments,0))}catch(e){return void o({msg:"onerror handler failed "+e+" @ "+t.src})}o({msg:"remote script failed "+t.src})},onreadystatechange:function(){/^(loaded|complete)$/.test(t.readyState)&&r()}})},t.prototype._shouldRelease=function(t){return!/^script$/i.test(t.nodeName)||!!(this.options.releaseAsync&&t.src&&t.hasAttribute("async"))},t}();e.default=h},function(t,e,n){!function(e,n){t.exports=function(){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return t[r].call(o.exports,o,o.exports,e),o.loaded=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){"use strict";var r=n(1),o=function(t){return t&&t.__esModule?t:{default:t}}(r);t.exports=o.default},function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}e.__esModule=!0;var i=n(2),a=r(i),s=n(3),c=r(s),u=n(6),p=function(t){return t&&t.__esModule?t:{default:t}}(u),l=n(5),d={comment:/^<!--/,endTag:/^<\//,atomicTag:/^<\s*(script|style|noscript|iframe|textarea)[\s\/>]/i,startTag:/^</,chars:/^[^<]/},f=function(){function t(){var e=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};o(this,t),this.stream=n;var i=!1,s={};for(var c in a)a.hasOwnProperty(c)&&(r.autoFix&&(s[c+"Fix"]=!0),i=i||s[c+"Fix"]);i?(this._readToken=(0,p.default)(this,s,function(){return e._readTokenImpl()}),this._peekToken=(0,p.default)(this,s,function(){return e._peekTokenImpl()})):(this._readToken=this._readTokenImpl,this._peekToken=this._peekTokenImpl)}return t.prototype.append=function(t){this.stream+=t},t.prototype.prepend=function(t){this.stream=t+this.stream},t.prototype._readTokenImpl=function(){var t=this._peekTokenImpl();if(t)return this.stream=this.stream.slice(t.length),t},t.prototype._peekTokenImpl=function(){for(var t in d)if(d.hasOwnProperty(t)&&d[t].test(this.stream)){var e=c[t](this.stream);if(e)return"startTag"===e.type&&/script|style/i.test(e.tagName)?null:(e.text=this.stream.substr(0,e.length),e)}},t.prototype.peekToken=function(){return this._peekToken()},t.prototype.readToken=function(){return this._readToken()},t.prototype.readTokens=function(t){for(var e=void 0;e=this.readToken();)if(t[e.type]&&!1===t[e.type](e))return},t.prototype.clear=function(){var t=this.stream;return this.stream="",t},t.prototype.rest=function(){return this.stream},t}();e.default=f,f.tokenToString=function(t){return t.toString()},f.escapeAttributes=function(t){var e={};for(var n in t)t.hasOwnProperty(n)&&(e[n]=(0,l.escapeQuotes)(t[n],null));return e},f.supports=a;for(var h in a)a.hasOwnProperty(h)&&(f.browserHasFlaw=f.browserHasFlaw||!a[h]&&h)},function(t,e){"use strict";e.__esModule=!0;var n=!1,r=!1,o=window.document.createElement("div");try{var i="<P><I></P></I>";o.innerHTML=i,e.tagSoup=n=o.innerHTML!==i}catch(t){e.tagSoup=n=!1}try{o.innerHTML="<P><i><P></P></i></P>",e.selfClose=r=2===o.childNodes.length}catch(t){e.selfClose=r=!1}o=null,e.tagSoup=n,e.selfClose=r},function(t,e,n){"use strict";function r(t){var e=t.indexOf("--\x3e");if(e>=0)return new u.CommentToken(t.substr(4,e-1),e+3)}function o(t){var e=t.indexOf("<");return new u.CharsToken(e>=0?e:t.length)}function i(t){if(-1!==t.indexOf(">")){var e=t.match(p.startTag);if(e){var n=function(){var t={},n={},r=e[2];return e[2].replace(p.attr,function(e,o){arguments[2]||arguments[3]||arguments[4]||arguments[5]?arguments[5]?(t[arguments[5]]="",n[arguments[5]]=!0):t[o]=arguments[2]||arguments[3]||arguments[4]||p.fillAttr.test(o)&&o||"":t[o]="",r=r.replace(e,"")}),{v:new u.StartTagToken(e[1],e[0].length,t,n,!!e[3],r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""))}}();if("object"===(void 0===n?"undefined":c(n)))return n.v}}}function a(t){var e=i(t);if(e){var n=t.slice(e.length);if(n.match(new RegExp("</\\s*"+e.tagName+"\\s*>","i"))){var r=n.match(new RegExp("([\\s\\S]*?)</\\s*"+e.tagName+"\\s*>","i"));if(r)return new u.AtomicTagToken(e.tagName,r[0].length+e.length,e.attrs,e.booleanAttrs,r[1])}}}function s(t){var e=t.match(p.endTag);if(e)return new u.EndTagToken(e[1],e[0].length)}e.__esModule=!0;var c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};e.comment=r,e.chars=o,e.startTag=i,e.atomicTag=a,e.endTag=s;var u=n(4),p={startTag:/^<([\-A-Za-z0-9_]+)((?:\s+[\w\-]+(?:\s*=?\s*(?:(?:"[^"]*")|(?:'[^']*')|[^>\s]+))?)*)\s*(\/?)>/,endTag:/^<\/([\-A-Za-z0-9_]+)[^>]*>/,attr:/(?:([\-A-Za-z0-9_]+)\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|([^>\s]+)))|(?:([\-A-Za-z0-9_]+)(\s|$)+)/g,fillAttr:/^(checked|compact|declare|defer|disabled|ismap|multiple|nohref|noresize|noshade|nowrap|readonly|selected)$/i}},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}e.__esModule=!0,e.EndTagToken=e.AtomicTagToken=e.StartTagToken=e.TagToken=e.CharsToken=e.CommentToken=e.Token=void 0;var o=n(5),i=(e.Token=function t(e,n){r(this,t),this.type=e,this.length=n,this.text=""},e.CommentToken=function(){function t(e,n){r(this,t),this.type="comment",this.length=n||(e?e.length:0),this.text="",this.content=e}return t.prototype.toString=function(){return"\x3c!--"+this.content},t}(),e.CharsToken=function(){function t(e){r(this,t),this.type="chars",this.length=e,this.text=""}return t.prototype.toString=function(){return this.text},t}(),e.TagToken=function(){function t(e,n,o,i,a){r(this,t),this.type=e,this.length=o,this.text="",this.tagName=n,this.attrs=i,this.booleanAttrs=a,this.unary=!1,this.html5Unary=!1}return t.formatTag=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n="<"+t.tagName;for(var r in t.attrs)if(t.attrs.hasOwnProperty(r)){n+=" "+r;var i=t.attrs[r];void 0!==t.booleanAttrs&&void 0!==t.booleanAttrs[r]||(n+='="'+(0,o.escapeQuotes)(i)+'"')}return t.rest&&(n+=" "+t.rest),n+=t.unary&&!t.html5Unary?"/>":">",void 0!==e&&null!==e&&(n+=e+"</"+t.tagName+">"),n},t}());e.StartTagToken=function(){function t(e,n,o,i,a,s){r(this,t),this.type="startTag",this.length=n,this.text="",this.tagName=e,this.attrs=o,this.booleanAttrs=i,this.html5Unary=!1,this.unary=a,this.rest=s}return t.prototype.toString=function(){return i.formatTag(this)},t}(),e.AtomicTagToken=function(){function t(e,n,o,i,a){r(this,t),this.type="atomicTag",this.length=n,this.text="",this.tagName=e,this.attrs=o,this.booleanAttrs=i,this.unary=!1,this.html5Unary=!1,this.content=a}return t.prototype.toString=function(){return i.formatTag(this,this.content)},t}(),e.EndTagToken=function(){function t(e,n){r(this,t),this.type="endTag",this.length=n,this.text="",this.tagName=e}return t.prototype.toString=function(){return"</"+this.tagName+">"},t}()},function(t,e){"use strict";function n(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return t?t.replace(/([^"]*)"/g,function(t,e){return/\\/.test(e)?e+'"':e+'\\"'}):e}e.__esModule=!0,e.escapeQuotes=n},function(t,e){"use strict";function n(t){return t&&"startTag"===t.type&&(t.unary=s.test(t.tagName)||t.unary,t.html5Unary=!/\/>$/.test(t.text)),t}function r(t,e){var r=t.stream,o=n(e());return t.stream=r,o}function o(t,e){var n=e.pop();t.prepend("</"+n.tagName+">")}function i(){var t=[];return t.last=function(){return this[this.length-1]},t.lastTagNameEq=function(t){var e=this.last();return e&&e.tagName&&e.tagName.toUpperCase()===t.toUpperCase()},t.containsTagName=function(t){for(var e,n=0;e=this[n];n++)if(e.tagName===t)return!0;return!1},t}function a(t,e,a){function s(){var e=r(t,a);e&&p[e.type]&&p[e.type](e)}var u=i(),p={startTag:function(n){var r=n.tagName;"TR"===r.toUpperCase()&&u.lastTagNameEq("TABLE")?(t.prepend("<TBODY>"),s()):e.selfCloseFix&&c.test(r)&&u.containsTagName(r)?u.lastTagNameEq(r)?o(t,u):(t.prepend("</"+n.tagName+">"),s()):n.unary||u.push(n)},endTag:function(n){u.last()?e.tagSoupFix&&!u.lastTagNameEq(n.tagName)?o(t,u):u.pop():e.tagSoupFix&&(a(),s())}};return function(){return s(),n(a())}}e.__esModule=!0,e.default=a;var s=/^(AREA|BASE|BASEFONT|BR|COL|FRAME|HR|IMG|INPUT|ISINDEX|LINK|META|PARAM|EMBED)$/i,c=/^(COLGROUP|DD|DT|LI|OPTIONS|P|TD|TFOOT|TH|THEAD|TR)$/i}])}()}()},function(t,e){"use strict";function n(t){return void 0!==t&&null!==t}function r(t){return"function"==typeof t}function o(t,e,n){var r=void 0,o=t&&t.length||0;for(r=0;r<o;r++)e.call(n,t[r],r)}function i(t,e,n){for(var r in t)t.hasOwnProperty(r)&&e.call(n,r,t[r])}function a(t,e){return t=t||{},i(e,function(e,r){n(t[e])||(t[e]=r)}),t}function s(t){try{return Array.prototype.slice.call(t)}catch(n){var e=function(){var e=[];return o(t,function(t){e.push(t)}),{v:e}}();if("object"===(void 0===e?"undefined":d(e)))return e.v}}function c(t){return t[t.length-1]}function u(t,e){return!(!t||"startTag"!==t.type&&"atomicTag"!==t.type||!("tagName"in t)||!~t.tagName.toLowerCase().indexOf(e))}function p(t){return u(t,"script")}function l(t){return u(t,"style")}e.__esModule=!0;var d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};e.existy=n,e.isFunction=r,e.each=o,e.eachKey=i,e.defaults=a,e.toArray=s,e.last=c,e.isTag=u,e.isScript=p,e.isStyle=l}])}),function(t){var e={common:{init:function(){t(document).on("click",".gdpr-help-content-cnt .gdpr-faq-toggle h3",function(){var e=t(this).closest(".gdpr-faq-toggle");e.hasClass("gdpr-faq-open")?e.removeClass("gdpr-faq-open").find(".gdpr-faq-accordion-content").slideUp(200):(e.closest(".gdpr-help-content-block").find(".gdpr-faq-open").each(function(){t(this).find(".gdpr-faq-accordion-content").slideUp(200),t(this).removeClass("gdpr-faq-open")}),e.addClass("gdpr-faq-open").find(".gdpr-faq-accordion-content").slideDown(200))});var e=!1,n=!1;t(document).on("click",".button-gdpr-deactivate-licence, .gdpr_deactivate_license_key",function(n){e?t(this).closest("form").submit():(n.preventDefault(),t(".gdpr-admin-popup.gdpr-admin-popup-deactivate").fadeIn(200))}),t(document).on("click",".button-reset-settings",function(e){e.preventDefault(),t(".gdpr-admin-popup.gdpr-admin-popup-reset-settings").fadeIn(200)}),t(document).on("click",".button-reset-settings-confirm",function(e){if(e.preventDefault(),!n){n=!0;var r=t(this).attr("data-ajaxurl");jQuery.post(r,{action:"gdpr_cookie_compliance_reset_settings"},function(t){n=!1,location.reload()})}}),t(document).on("click",".gdpr-admin-popup .gdpr-popup-overlay, .gdpr-admin-popup .gdpr-popup-close",function(e){e.preventDefault(),t(this).closest(".gdpr-admin-popup").fadeOut(200)}),t(document).on("click",".gdpr-admin-popup.gdpr-admin-popup-deactivate .button-deactivate-confirm",function(n){n.preventDefault(),e=!0;var r=t("#moove_gdpr_license_settings").attr("data-key");t("<input type='hidden' value='1' />").attr("id","gdpr_deactivate_license").attr("name","gdpr_deactivate_license").appendTo("#moove_gdpr_license_settings"),t("#moove_gdpr_license_key").val(r),t("#moove_gdpr_license_settings").submit(),t("#moove_gdpr_license_key").val(""),t(this).closest(".gdpr-admin-popup").fadeOut(200)}),t(document).on("click",".gdpr-cookie-alert .gdpr-dismiss",function(e){e.preventDefault(),t(this).closest(".gdpr-cookie-alert").slideUp(400);var n=t(this).attr("data-adminajax"),r=t(this).attr("data-uid");jQuery.post(n,{action:"moove_hide_language_notice",user_id:r},function(t){})}),t(document).on("click",".gdpr-cookie-update-alert .gdpr-dismiss-update",function(e){e.preventDefault(),t(this).closest(".gdpr-cookie-alert").slideUp(400);var n=t(this).attr("data-adminajax"),r=t(this).attr("data-version");jQuery.post(n,{action:"moove_hide_update_notice",version:r},function(t){})}),t(document).on("click","a.gdpr-help-tab-toggle",function(e){e.preventDefault();var n=t(this).attr("href");t(n).length>0&&(t(".gdpr-help-content-block").slideUp(),t(n).slideDown(),t(".gdpr-help-tab-toggle").removeClass("active"),t(this).addClass("active"))}),t(document).on("click",".gdpr-script-tab-content .gdpr-tab-code-section-nav li > a ",function(e){e.preventDefault();var n=t(this).attr("href");t(this).closest(".gdpr-script-tab-content").find(".gdpr-active").removeClass("gdpr-active"),t(this).addClass("gdpr-active"),t(n).addClass("gdpr-active")}),t(document).find(".gdpr-conditional-field").each(function(){var e=t(this).attr("data-dependency");t(e).is(":checked")?t(this).addClass("gdpr-conditional-on"):t(this).removeClass("gdpr-conditional-on")}),t(document).on("change",'.gdpr-checkbox-toggle input[type="checkbox"]',function(){t(this).is(":checked")?t(document).find('.gdpr-conditional-field[data-dependency="#'+t(this).attr("id")+'"]').addClass("gdpr-conditional-on"):t(document).find('.gdpr-conditional-field[data-dependency="#'+t(this).attr("id")+'"]').removeClass("gdpr-conditional-on")}),t(document).on("keyup","input[name=moove_gdpr_company_logo]",function(){t(".moove_gdpr_company_logo_holder").css("background-image","url("+t(this).val()+")")}),t(document).on("change",'input[name="moove_gdpr_plugin_font_type"]',function(){"1"===t(this).val()||"2"===t(this).val()?t("#moove_gdpr_plugin_font_family").addClass("moove-not-visible"):t("#moove_gdpr_plugin_font_family").removeClass("moove-not-visible")}),t("#moove_form_checker_wrap .iris-colorpicker").each(function(){t(this).iris({width:300,hide:!0,change:function(e,n){t(this).css("background",n.color.toString())}}).on("click",function(){t(this).iris("toggle")}),t(this).iris("color",t(this).val())}),t(document).on("click",".iris-selectbtn",function(){t(this).parent().find(".iris-colorpicker").iris("toggle")}),t(document).on("click",".iris-picker:visible",function(){t(".iris-colorpicker").iris("hide")}),t(document).on("click",'#moove_gdpr_tab_advanced_cookies button[type="submit"]',function(e){var n=0,r=0;if("on"===t('input[name="moove_gdpr_advanced_cookies_enable"]:checked').val()&&(t(".gdpr-script-tab-content").find("textarea.code").each(function(){t.trim(t(this).val())||n++,r++}),r-n<1)){e.preventDefault();var o=t(".gdpr-script-tab-content").addClass("moove-gdpr-form-error").find(".alert.script-error").show();t("html, body").animate({scrollTop:o.offset().top-100},200)}}),t(document).on("click",'#moove_gdpr_tab_third_party_cookies button[type="submit"]',function(e){var n=0,r=0;if("on"===t('input[name="moove_gdpr_third_party_cookies_enable"]:checked').val()&&(t(".gdpr-script-tab-content").find("textarea.code").each(function(){t.trim(t(this).val())||n++,r++}),r-n<1)){e.preventDefault();var o=t(".gdpr-script-tab-content").addClass("moove-gdpr-form-error").find(".alert.script-error").show();t("html, body").animate({scrollTop:o.offset().top-100},200)}})},finalize:function(){}},home:{init:function(){},finalize:function(){}},about_us:{init:function(){}}},n={fire:function(t,n,r){var o,i=e;n=void 0===n?"init":n,o=""!==t,o=o&&i[t],(o=o&&"function"==typeof i[t][n])&&i[t][n](r)},loadEvents:function(){n.fire("common"),t.each(document.body.className.replace(/-/g,"_").split(/\s+/),function(t,e){n.fire(e),n.fire(e,"finalize")}),n.fire("common","finalize")}};t(document).ready(n.loadEvents)}(jQuery);
|
dist/scripts/main.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1 |
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.postscribe=t():e.postscribe=t()}(this,function(){return function(e){function t(r){if(o[r])return o[r].exports;var n=o[r]={exports:{},id:r,loaded:!1};return e[r].call(n.exports,n,n.exports,t),n.loaded=!0,n.exports}var o={};return t.m=e,t.c=o,t.p="",t(0)}([function(e,t,o){"use strict";var r=o(1),n=function(e){return e&&e.__esModule?e:{default:e}}(r);e.exports=n.default},function(e,t,o){"use strict";function r(){}function n(){var e=f.shift();if(e){var t=l.last(e);t.afterDequeue(),e.stream=i.apply(void 0,e),t.afterStreamStart()}}function i(e,t,o){function i(e){e=o.beforeWrite(e),m.write(e),o.afterWrite(e)}m=new d.default(e,o),m.id=_++,m.name=o.name||m.id,s.streams[m.name]=m;var c=e.ownerDocument,p={close:c.close,open:c.open,write:c.write,writeln:c.writeln};a(c,{close:r,open:r,write:function(){for(var e=arguments.length,t=Array(e),o=0;o<e;o++)t[o]=arguments[o];return i(t.join(""))},writeln:function(){for(var e=arguments.length,t=Array(e),o=0;o<e;o++)t[o]=arguments[o];return i(t.join("")+"\n")}});var l=m.win.onerror||r;return m.win.onerror=function(e,t,r){o.error({msg:e+" - "+t+": "+r}),l.apply(m.win,[e,t,r])},m.write(t,function(){a(c,p),m.win.onerror=l,o.done(),m=null,n()}),m}function s(e,t,o){if(l.isFunction(o))o={done:o};else if("clear"===o)return f=[],m=null,void(_=0);o=l.defaults(o,u),e=/^#/.test(e)?window.document.getElementById(e.substr(1)):e.jquery?e[0]:e;var i=[e,t,o];return e.postscribe={cancel:function(){i.stream?i.stream.abort():i[1]=r}},o.beforeEnqueue(i),f.push(i),m||n(),e.postscribe}t.__esModule=!0;var a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var o=arguments[t];for(var r in o)Object.prototype.hasOwnProperty.call(o,r)&&(e[r]=o[r])}return e};t.default=s;var c=o(2),d=function(e){return e&&e.__esModule?e:{default:e}}(c),p=o(4),l=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t.default=e,t}(p),u={afterAsync:r,afterDequeue:r,afterStreamStart:r,afterWrite:r,autoFix:!0,beforeEnqueue:r,beforeWriteToken:function(e){return e},beforeWrite:function(e){return e},done:r,error:function(e){throw new Error(e.msg)},releaseAsync:!1},_=0,f=[],m=null;a(s,{streams:{},queue:f,WriteStream:d.default})},function(e,t,o){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){var o=l+t,r=e.getAttribute(o);return p.existy(r)?String(r):r}function i(e,t){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=l+t;p.existy(o)&&""!==o?e.setAttribute(r,o):e.removeAttribute(r)}t.__esModule=!0;var s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var o=arguments[t];for(var r in o)Object.prototype.hasOwnProperty.call(o,r)&&(e[r]=o[r])}return e},a=o(3),c=function(e){return e&&e.__esModule?e:{default:e}}(a),d=o(4),p=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t.default=e,t}(d),l="data-ps-",u="ps-style",_="ps-script",f=function(){function e(t){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};r(this,e),this.root=t,this.options=o,this.doc=t.ownerDocument,this.win=this.doc.defaultView||this.doc.parentWindow,this.parser=new c.default("",{autoFix:o.autoFix}),this.actuals=[t],this.proxyHistory="",this.proxyRoot=this.doc.createElement(t.nodeName),this.scriptStack=[],this.writeQueue=[],i(this.proxyRoot,"proxyof",0)}return e.prototype.write=function(){var e;for((e=this.writeQueue).push.apply(e,arguments);!this.deferredRemote&&this.writeQueue.length;){var t=this.writeQueue.shift();p.isFunction(t)?this._callFunction(t):this._writeImpl(t)}},e.prototype._callFunction=function(e){var t={type:"function",value:e.name||e.toString()};this._onScriptStart(t),e.call(this.win,this.doc),this._onScriptDone(t)},e.prototype._writeImpl=function(e){this.parser.append(e);for(var t=void 0,o=void 0,r=void 0,n=[];(t=this.parser.readToken())&&!(o=p.isScript(t))&&!(r=p.isStyle(t));)(t=this.options.beforeWriteToken(t))&&n.push(t);n.length>0&&this._writeStaticTokens(n),o&&this._handleScriptToken(t),r&&this._handleStyleToken(t)},e.prototype._writeStaticTokens=function(e){var t=this._buildChunk(e);return t.actual?(t.html=this.proxyHistory+t.actual,this.proxyHistory+=t.proxy,this.proxyRoot.innerHTML=t.html,this._walkChunk(),t):null},e.prototype._buildChunk=function(e){for(var t=this.actuals.length,o=[],r=[],n=[],i=e.length,s=0;s<i;s++){var a=e[s],c=a.toString();if(o.push(c),a.attrs){if(!/^noscript$/i.test(a.tagName)){var d=t++;r.push(c.replace(/(\/?>)/," "+l+"id="+d+" $1")),a.attrs.id!==_&&a.attrs.id!==u&&n.push("atomicTag"===a.type?"":"<"+a.tagName+" "+l+"proxyof="+d+(a.unary?" />":">"))}}else r.push(c),n.push("endTag"===a.type?c:"")}return{tokens:e,raw:o.join(""),actual:r.join(""),proxy:n.join("")}},e.prototype._walkChunk=function(){for(var e=void 0,t=[this.proxyRoot];p.existy(e=t.shift());){var o=1===e.nodeType;if(!(o&&n(e,"proxyof"))){o&&(this.actuals[n(e,"id")]=e,i(e,"id"));var r=e.parentNode&&n(e.parentNode,"proxyof");r&&this.actuals[r].appendChild(e)}t.unshift.apply(t,p.toArray(e.childNodes))}},e.prototype._handleScriptToken=function(e){var t=this,o=this.parser.clear();o&&this.writeQueue.unshift(o),e.src=e.attrs.src||e.attrs.SRC,(e=this.options.beforeWriteToken(e))&&(e.src&&this.scriptStack.length?this.deferredRemote=e:this._onScriptStart(e),this._writeScriptToken(e,function(){t._onScriptDone(e)}))},e.prototype._handleStyleToken=function(e){var t=this.parser.clear();t&&this.writeQueue.unshift(t),e.type=e.attrs.type||e.attrs.TYPE||"text/css",e=this.options.beforeWriteToken(e),e&&this._writeStyleToken(e),t&&this.write()},e.prototype._writeStyleToken=function(e){var t=this._buildStyle(e);this._insertCursor(t,u),e.content&&(t.styleSheet&&!t.sheet?t.styleSheet.cssText=e.content:t.appendChild(this.doc.createTextNode(e.content)))},e.prototype._buildStyle=function(e){var t=this.doc.createElement(e.tagName);return t.setAttribute("type",e.type),p.eachKey(e.attrs,function(e,o){t.setAttribute(e,o)}),t},e.prototype._insertCursor=function(e,t){this._writeImpl('<span id="'+t+'"/>');var o=this.doc.getElementById(t);o&&o.parentNode.replaceChild(e,o)},e.prototype._onScriptStart=function(e){e.outerWrites=this.writeQueue,this.writeQueue=[],this.scriptStack.unshift(e)},e.prototype._onScriptDone=function(e){return e!==this.scriptStack[0]?void this.options.error({msg:"Bad script nesting or script finished twice"}):(this.scriptStack.shift(),this.write.apply(this,e.outerWrites),void(!this.scriptStack.length&&this.deferredRemote&&(this._onScriptStart(this.deferredRemote),this.deferredRemote=null)))},e.prototype._writeScriptToken=function(e,t){var o=this._buildScript(e),r=this._shouldRelease(o),n=this.options.afterAsync;e.src&&(o.src=e.src,this._scriptLoadHandler(o,r?n:function(){t(),n()}));try{this._insertCursor(o,_),o.src&&!r||t()}catch(e){this.options.error(e),t()}},e.prototype._buildScript=function(e){var t=this.doc.createElement(e.tagName);return p.eachKey(e.attrs,function(e,o){t.setAttribute(e,o)}),e.content&&(t.text=e.content),t},e.prototype._scriptLoadHandler=function(e,t){function o(){e=e.onload=e.onreadystatechange=e.onerror=null}function r(){o(),null!=t&&t(),t=null}function n(e){o(),a(e),null!=t&&t(),t=null}function i(e,t){var o=e["on"+t];null!=o&&(e["_on"+t]=o)}var a=this.options.error;i(e,"load"),i(e,"error"),s(e,{onload:function(){if(e._onload)try{e._onload.apply(this,Array.prototype.slice.call(arguments,0))}catch(t){n({msg:"onload handler failed "+t+" @ "+e.src})}r()},onerror:function(){if(e._onerror)try{e._onerror.apply(this,Array.prototype.slice.call(arguments,0))}catch(t){return void n({msg:"onerror handler failed "+t+" @ "+e.src})}n({msg:"remote script failed "+e.src})},onreadystatechange:function(){/^(loaded|complete)$/.test(e.readyState)&&r()}})},e.prototype._shouldRelease=function(e){return!/^script$/i.test(e.nodeName)||!!(this.options.releaseAsync&&e.src&&e.hasAttribute("async"))},e}();t.default=f},function(e,t,o){!function(t,o){e.exports=function(){return function(e){function t(r){if(o[r])return o[r].exports;var n=o[r]={exports:{},id:r,loaded:!1};return e[r].call(n.exports,n,n.exports,t),n.loaded=!0,n.exports}var o={};return t.m=e,t.c=o,t.p="",t(0)}([function(e,t,o){"use strict";var r=o(1),n=function(e){return e&&e.__esModule?e:{default:e}}(r);e.exports=n.default},function(e,t,o){"use strict";function r(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t.default=e,t}function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=o(2),s=r(i),a=o(3),c=r(a),d=o(6),p=function(e){return e&&e.__esModule?e:{default:e}}(d),l=o(5),u={comment:/^<!--/,endTag:/^<\//,atomicTag:/^<\s*(script|style|noscript|iframe|textarea)[\s\/>]/i,startTag:/^</,chars:/^[^<]/},_=function(){function e(){var t=this,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};n(this,e),this.stream=o;var i=!1,a={};for(var c in s)s.hasOwnProperty(c)&&(r.autoFix&&(a[c+"Fix"]=!0),i=i||a[c+"Fix"]);i?(this._readToken=(0,p.default)(this,a,function(){return t._readTokenImpl()}),this._peekToken=(0,p.default)(this,a,function(){return t._peekTokenImpl()})):(this._readToken=this._readTokenImpl,this._peekToken=this._peekTokenImpl)}return e.prototype.append=function(e){this.stream+=e},e.prototype.prepend=function(e){this.stream=e+this.stream},e.prototype._readTokenImpl=function(){var e=this._peekTokenImpl();if(e)return this.stream=this.stream.slice(e.length),e},e.prototype._peekTokenImpl=function(){for(var e in u)if(u.hasOwnProperty(e)&&u[e].test(this.stream)){var t=c[e](this.stream);if(t)return"startTag"===t.type&&/script|style/i.test(t.tagName)?null:(t.text=this.stream.substr(0,t.length),t)}},e.prototype.peekToken=function(){return this._peekToken()},e.prototype.readToken=function(){return this._readToken()},e.prototype.readTokens=function(e){for(var t=void 0;t=this.readToken();)if(e[t.type]&&!1===e[t.type](t))return},e.prototype.clear=function(){var e=this.stream;return this.stream="",e},e.prototype.rest=function(){return this.stream},e}();t.default=_,_.tokenToString=function(e){return e.toString()},_.escapeAttributes=function(e){var t={};for(var o in e)e.hasOwnProperty(o)&&(t[o]=(0,l.escapeQuotes)(e[o],null));return t},_.supports=s;for(var f in s)s.hasOwnProperty(f)&&(_.browserHasFlaw=_.browserHasFlaw||!s[f]&&f)},function(e,t){"use strict";t.__esModule=!0;var o=!1,r=!1,n=window.document.createElement("div");try{var i="<P><I></P></I>";n.innerHTML=i,t.tagSoup=o=n.innerHTML!==i}catch(e){t.tagSoup=o=!1}try{n.innerHTML="<P><i><P></P></i></P>",t.selfClose=r=2===n.childNodes.length}catch(e){t.selfClose=r=!1}n=null,t.tagSoup=o,t.selfClose=r},function(e,t,o){"use strict";function r(e){var t=e.indexOf("--\x3e");if(t>=0)return new d.CommentToken(e.substr(4,t-1),t+3)}function n(e){var t=e.indexOf("<");return new d.CharsToken(t>=0?t:e.length)}function i(e){if(-1!==e.indexOf(">")){var t=e.match(p.startTag);if(t){var o=function(){var e={},o={},r=t[2];return t[2].replace(p.attr,function(t,n){arguments[2]||arguments[3]||arguments[4]||arguments[5]?arguments[5]?(e[arguments[5]]="",o[arguments[5]]=!0):e[n]=arguments[2]||arguments[3]||arguments[4]||p.fillAttr.test(n)&&n||"":e[n]="",r=r.replace(t,"")}),{v:new d.StartTagToken(t[1],t[0].length,e,o,!!t[3],r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""))}}();if("object"===(void 0===o?"undefined":c(o)))return o.v}}}function s(e){var t=i(e);if(t){var o=e.slice(t.length);if(o.match(new RegExp("</\\s*"+t.tagName+"\\s*>","i"))){var r=o.match(new RegExp("([\\s\\S]*?)</\\s*"+t.tagName+"\\s*>","i"));if(r)return new d.AtomicTagToken(t.tagName,r[0].length+t.length,t.attrs,t.booleanAttrs,r[1])}}}function a(e){var t=e.match(p.endTag);if(t)return new d.EndTagToken(t[1],t[0].length)}t.__esModule=!0;var c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.comment=r,t.chars=n,t.startTag=i,t.atomicTag=s,t.endTag=a;var d=o(4),p={startTag:/^<([\-A-Za-z0-9_]+)((?:\s+[\w\-]+(?:\s*=?\s*(?:(?:"[^"]*")|(?:'[^']*')|[^>\s]+))?)*)\s*(\/?)>/,endTag:/^<\/([\-A-Za-z0-9_]+)[^>]*>/,attr:/(?:([\-A-Za-z0-9_]+)\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|([^>\s]+)))|(?:([\-A-Za-z0-9_]+)(\s|$)+)/g,fillAttr:/^(checked|compact|declare|defer|disabled|ismap|multiple|nohref|noresize|noshade|nowrap|readonly|selected)$/i}},function(e,t,o){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0,t.EndTagToken=t.AtomicTagToken=t.StartTagToken=t.TagToken=t.CharsToken=t.CommentToken=t.Token=void 0;var n=o(5),i=(t.Token=function e(t,o){r(this,e),this.type=t,this.length=o,this.text=""},t.CommentToken=function(){function e(t,o){r(this,e),this.type="comment",this.length=o||(t?t.length:0),this.text="",this.content=t}return e.prototype.toString=function(){return"\x3c!--"+this.content},e}(),t.CharsToken=function(){function e(t){r(this,e),this.type="chars",this.length=t,this.text=""}return e.prototype.toString=function(){return this.text},e}(),t.TagToken=function(){function e(t,o,n,i,s){r(this,e),this.type=t,this.length=n,this.text="",this.tagName=o,this.attrs=i,this.booleanAttrs=s,this.unary=!1,this.html5Unary=!1}return e.formatTag=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o="<"+e.tagName;for(var r in e.attrs)if(e.attrs.hasOwnProperty(r)){o+=" "+r;var i=e.attrs[r];void 0!==e.booleanAttrs&&void 0!==e.booleanAttrs[r]||(o+='="'+(0,n.escapeQuotes)(i)+'"')}return e.rest&&(o+=" "+e.rest),o+=e.unary&&!e.html5Unary?"/>":">",void 0!==t&&null!==t&&(o+=t+"</"+e.tagName+">"),o},e}());t.StartTagToken=function(){function e(t,o,n,i,s,a){r(this,e),this.type="startTag",this.length=o,this.text="",this.tagName=t,this.attrs=n,this.booleanAttrs=i,this.html5Unary=!1,this.unary=s,this.rest=a}return e.prototype.toString=function(){return i.formatTag(this)},e}(),t.AtomicTagToken=function(){function e(t,o,n,i,s){r(this,e),this.type="atomicTag",this.length=o,this.text="",this.tagName=t,this.attrs=n,this.booleanAttrs=i,this.unary=!1,this.html5Unary=!1,this.content=s}return e.prototype.toString=function(){return i.formatTag(this,this.content)},e}(),t.EndTagToken=function(){function e(t,o){r(this,e),this.type="endTag",this.length=o,this.text="",this.tagName=t}return e.prototype.toString=function(){return"</"+this.tagName+">"},e}()},function(e,t){"use strict";function o(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return e?e.replace(/([^"]*)"/g,function(e,t){return/\\/.test(t)?t+'"':t+'\\"'}):t}t.__esModule=!0,t.escapeQuotes=o},function(e,t){"use strict";function o(e){return e&&"startTag"===e.type&&(e.unary=a.test(e.tagName)||e.unary,e.html5Unary=!/\/>$/.test(e.text)),e}function r(e,t){var r=e.stream,n=o(t());return e.stream=r,n}function n(e,t){var o=t.pop();e.prepend("</"+o.tagName+">")}function i(){var e=[];return e.last=function(){return this[this.length-1]},e.lastTagNameEq=function(e){var t=this.last();return t&&t.tagName&&t.tagName.toUpperCase()===e.toUpperCase()},e.containsTagName=function(e){for(var t,o=0;t=this[o];o++)if(t.tagName===e)return!0;return!1},e}function s(e,t,s){function a(){var t=r(e,s);t&&p[t.type]&&p[t.type](t)}var d=i(),p={startTag:function(o){var r=o.tagName;"TR"===r.toUpperCase()&&d.lastTagNameEq("TABLE")?(e.prepend("<TBODY>"),a()):t.selfCloseFix&&c.test(r)&&d.containsTagName(r)?d.lastTagNameEq(r)?n(e,d):(e.prepend("</"+o.tagName+">"),a()):o.unary||d.push(o)},endTag:function(o){d.last()?t.tagSoupFix&&!d.lastTagNameEq(o.tagName)?n(e,d):d.pop():t.tagSoupFix&&(s(),a())}};return function(){return a(),o(s())}}t.__esModule=!0,t.default=s;var a=/^(AREA|BASE|BASEFONT|BR|COL|FRAME|HR|IMG|INPUT|ISINDEX|LINK|META|PARAM|EMBED)$/i,c=/^(COLGROUP|DD|DT|LI|OPTIONS|P|TD|TFOOT|TH|THEAD|TR)$/i}])}()}()},function(e,t){"use strict";function o(e){return void 0!==e&&null!==e}function r(e){return"function"==typeof e}function n(e,t,o){var r=void 0,n=e&&e.length||0;for(r=0;r<n;r++)t.call(o,e[r],r)}function i(e,t,o){for(var r in e)e.hasOwnProperty(r)&&t.call(o,r,e[r])}function s(e,t){return e=e||{},i(t,function(t,r){o(e[t])||(e[t]=r)}),e}function a(e){try{return Array.prototype.slice.call(e)}catch(o){var t=function(){var t=[];return n(e,function(e){t.push(e)}),{v:t}}();if("object"===(void 0===t?"undefined":u(t)))return t.v}}function c(e){return e[e.length-1]}function d(e,t){return!(!e||"startTag"!==e.type&&"atomicTag"!==e.type||!("tagName"in e)||!~e.tagName.toLowerCase().indexOf(t))}function p(e){return d(e,"script")}function l(e){return d(e,"style")}t.__esModule=!0;var u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.existy=o,t.isFunction=r,t.each=n,t.eachKey=i,t.defaults=s,t.toArray=a,t.last=c,t.isTag=d,t.isScript=p,t.isStyle=l}])}),function(e){var t={common:{init:function(){"use strict";function t(e,t){try{jQuery().gdpr_cookie_compliance_analytics(e,t)}catch(e){}}function o(){var o=d("moove_gdpr_popup"),r={};return r.strict="0",r.thirdparty="0",r.advanced="0",o&&(o=JSON.parse(o),r.strict=o.strict,r.thirdparty=o.thirdparty,r.advanced=o.advanced,i(r),t("script_inject",o)),"1"!==moove_frontend_gdpr_scripts.strict_init&&e(document).find("iframe[data-gdpr-iframesrc]").each(function(){e(this).attr("src",e(this).attr("data-gdpr-iframesrc"))}),r}function r(e){c("moove_gdpr_popup",JSON.stringify({strict:"1",thirdparty:"1",advanced:"1"}),365),n("enabled-all"),t("accept_all","")}function n(t){var r=!1;try{void 0!==moove_frontend_gdpr_scripts.force_reload&&"true"===moove_frontend_gdpr_scripts.force_reload&&(r=!0)}catch(e){}var n=o(),i=moove_frontend_gdpr_scripts.enabled_default.third_party,a=moove_frontend_gdpr_scripts.enabled_default.advanced;if(document.cookie.indexOf("moove_gdpr_popup")>=0||1==i||1==a){d("moove_gdpr_popup");1==i&&(f.strict=1,f.thirdparty=i),1==a&&(f.strict=1,f.advanced=a),f&&(parseInt(n.strict)-parseInt(f.strict)<0&&(r=!0),parseInt(n.thirdparty)-parseInt(f.thirdparty)<0&&(r=!0),parseInt(n.advanced)-parseInt(f.advanced)<0&&(r=!0))}if(r)location.reload(!0);else{p(d("moove_gdpr_popup")),s(),e("#moove_gdpr_save_popup_settings_button").show()}}function i(t){t&&(1===parseInt(t.strict)?e("#moove_gdpr_strict_cookies").is(":checked")||(e("#moove_gdpr_strict_cookies").click(),e("#third_party_cookies fieldset").removeClass("fl-disabled"),e("#moove_gdpr_performance_cookies").prop("disabled",!1),e("#third_party_cookies .moove-gdpr-strict-secondary-warning-message").slideUp(),e("#advanced-cookies fieldset").removeClass("fl-disabled"),e("#advanced-cookies .moove-gdpr-strict-secondary-warning-message").slideUp(),e("#moove_gdpr_advanced_cookies").prop("disabled",!1)):e("#moove_gdpr_strict_cookies").is(":checked")&&(e("#moove_gdpr_strict_cookies").click().prop("checked",!0),e("#third_party_cookies fieldset").addClass("fl-disabled").closest(".moove-gdpr-status-bar").removeClass("checkbox-selected"),e("#moove_gdpr_performance_cookies").prop("disabled",!0).prop("checked",!1),e("#advanced-cookies fieldset").addClass("fl-disabled").closest(".moove-gdpr-status-bar").removeClass("checkbox-selected"),e("#moove_gdpr_advanced_cookies").prop("disabled",!0).prop("checked",!1)),1===parseInt(t.thirdparty)?e("#moove_gdpr_performance_cookies").is(":checked")||e("#moove_gdpr_performance_cookies").click():e("#moove_gdpr_performance_cookies").is(":checked")&&e("#moove_gdpr_performance_cookies").click(),1===parseInt(t.advanced)?e("#moove_gdpr_advanced_cookies").is(":checked")||e("#moove_gdpr_advanced_cookies").click():e("#moove_gdpr_advanced_cookies").is(":checked")&&e("#moove_gdpr_advanced_cookies").click(),e('input[data-name="moove_gdpr_performance_cookies"]').prop("checked",e("#moove_gdpr_performance_cookies").is(":checked")),e('input[data-name="moove_gdpr_strict_cookies"]').prop("checked",e("#moove_gdpr_strict_cookies").is(":checked")),e('input[data-name="moove_gdpr_advanced_cookies"]').prop("checked",e("#moove_gdpr_advanced_cookies").is(":checked")))}function s(){e("#moove_gdpr_cookie_info_bar").length>0&&(e("#moove_gdpr_cookie_info_bar").addClass("moove-gdpr-info-bar-hidden"),e("body").removeClass("gdpr-infobar-visible"))}function a(){if(void 0!==moove_frontend_gdpr_scripts.display_cookie_banner){if("true"===moove_frontend_gdpr_scripts.display_cookie_banner)e("#moove_gdpr_cookie_info_bar").length>0&&(e("#moove_gdpr_cookie_info_bar").removeClass("moove-gdpr-info-bar-hidden"),e("#moove_gdpr_save_popup_settings_button:not(.button-visible)").hide(),e("body").addClass("gdpr-infobar-visible"),t("show_infobar",""));else if(e("#moove_gdpr_cookie_info_bar").length>0){e("#moove_gdpr_cookie_info_bar").addClass("moove-gdpr-info-bar-hidden"),e("body").removeClass("gdpr-infobar-visible");var o={strict:1,thirdparty:1,advanced:1};p(JSON.stringify(o))}}else e("#moove_gdpr_cookie_info_bar").length>0&&(e("#moove_gdpr_cookie_info_bar").removeClass("moove-gdpr-info-bar-hidden"),e("#moove_gdpr_save_popup_settings_button:not(.button-visible)").hide(),e("body").addClass("gdpr-infobar-visible"),t("show_infobar",""))}function c(e,t,o){var r;if(o){var n=new Date;n.setTime(n.getTime()+24*o*60*60*1e3),r="; expires="+n.toGMTString()}else r="";document.cookie=encodeURIComponent(e)+"="+encodeURIComponent(t)+r+"; path=/",JSON.parse(t)}function d(e){for(var t=encodeURIComponent(e)+"=",o=document.cookie.split(";"),r=0;r<o.length;r++){for(var n=o[r];" "===n.charAt(0);)n=n.substring(1,n.length);if(0===n.indexOf(t))return decodeURIComponent(n.substring(t.length,n.length))}return null}function p(r){if(f=o(),r){var n=r;r=JSON.parse(r);o();if(!1!==m){var i=JSON.parse(m);1===parseInt(i.thirdparty)&&1===parseInt(r.thirdparty)&&(r.thirdparty="0"),1===parseInt(i.advanced)&&1===parseInt(r.advanced)&&(r.advanced="0")}t("script_inject",r),h=!0,1===parseInt(r.strict)&&e(document).find("iframe[data-gdpr-iframesrc]").each(function(){e(this).attr("src",e(this).attr("data-gdpr-iframesrc"))}),e.post(moove_frontend_gdpr_scripts.ajaxurl,{action:"moove_gdpr_get_scripts",strict:r.strict,thirdparty:r.thirdparty,advanced:r.advanced},function(t){m=n;var o=JSON.parse(t);o.header&&postscribe(document.head,o.header),o.body&&e(o.body).prependTo(document.body),o.footer&&postscribe(document.body,o.footer)})}else a()}function l(){var t=!0;e("#moove_gdpr_cookie_modal").find("input[type=checkbox]").each(function(){e(this).is(":checked")||(t=!1)}),t?e(".moove-gdpr-button-holder .moove-gdpr-modal-allow-all").hide().removeClass("button-visible"):e(".moove-gdpr-button-holder .moove-gdpr-modal-save-settings").is(":visible")?e(".moove-gdpr-button-holder .moove-gdpr-modal-allow-all").hide().removeClass("button-visible"):e(".moove-gdpr-button-holder .moove-gdpr-modal-allow-all").show().addClass("button-visible")}function u(){for(var e=document.cookie.split("; "),t=0;t<e.length;t++)for(var o=window.location.hostname.split(".");o.length>0;){var r=encodeURIComponent(e[t].split(";")[0].split("=")[0])+"=; expires=Thu, 01-Jan-1970 00:00:01 GMT; domain="+o.join(".")+" ; path=",n=location.pathname.split("/");for(document.cookie=r+"/";n.length>0;)document.cookie=r+n.join("/"),n.pop();o.shift()}}function _(){var t=d("moove_gdpr_popup");u();var o="0",r="0",n="0",i=!1;t&&(t=JSON.parse(t),o=t.strict,r=t.advanced,n=t.thirdparty),e("#moove_gdpr_strict_cookies").length>0?e("#moove_gdpr_strict_cookies").is(":checked")?(o="1",i=!0):o="0":(i=!0,o="1"),e("#moove_gdpr_performance_cookies").is(":checked")?(n="1",i=!0):n="0",e("#moove_gdpr_advanced_cookies").is(":checked")?(r="1",i=!0):r="0",!t&&i?(c("moove_gdpr_popup",JSON.stringify({strict:o,thirdparty:n,advanced:r}),365),s(),e("#moove_gdpr_save_popup_settings_button").show()):t&&c("moove_gdpr_popup",JSON.stringify({strict:o,thirdparty:n,advanced:r}),365);var t=d("moove_gdpr_popup");t&&(t=JSON.parse(t),"0"==t.strict&&"0"==t.advanced&&"0"==t.thirdparty&&u())}e(document).on("click","#moove_gdpr_cookie_info_bar .moove-gdpr-infobar-reject-btn",function(t){t.preventDefault(),c("moove_gdpr_popup",JSON.stringify({strict:"1",thirdparty:"0",advanced:"0"}),365),e("#moove_gdpr_cookie_info_bar").length>0&&(e("#moove_gdpr_cookie_info_bar").addClass("moove-gdpr-info-bar-hidden"),e("body").removeClass("gdpr-infobar-visible"),location.reload(!0))}),e.fn.moove_gdpr_read_cookies=function(e){var t=d("moove_gdpr_popup"),o={};return o.strict="0",o.thirdparty="0",o.advanced="0",t&&(t=JSON.parse(t),o.strict=t.strict,o.thirdparty=t.thirdparty,o.advanced=t.advanced),o};var f=o(),m=!1,h=!1;if(e.fn.moove_gdpr_save_cookie=function(o){var r=d("moove_gdpr_popup"),n=e(window).scrollTop();if(!r){if(o.thirdParty)var s="1";else var s="0";if(o.advanced)var a="1";else var a="0";if(o.scrollEnable){var p=o.scrollEnable;e(window).scroll(function(){!h&&e(this).scrollTop()-n>p&&("undefined"===o.thirdparty&&"undefined"===o.advanced||(c("moove_gdpr_popup",JSON.stringify({strict:"1",thirdparty:s,advanced:a}),365),r=JSON.parse(r),i(r)))})}else"undefined"===o.thirdparty&&"undefined"===o.advanced||(c("moove_gdpr_popup",JSON.stringify({strict:"1",thirdparty:s,advanced:a}),365),r=JSON.parse(r),i(r));r=d("moove_gdpr_popup"),r&&(r=JSON.parse(r),t("script_inject",r),h=!0,1===parseInt(r.strict)&&e(document).find("iframe[data-gdpr-iframesrc]").each(function(){e(this).attr("src",e(this).attr("data-gdpr-iframesrc"))}),jQuery.post(moove_frontend_gdpr_scripts.ajaxurl,{action:"moove_gdpr_get_scripts",strict:r.strict,thirdparty:r.thirdparty,advanced:r.advanced},function(t){var o=JSON.parse(t);o.header&&postscribe(document.head,o.header),o.body&&e(o.body).prependTo(document.body),o.footer&&postscribe(document.body,o.footer)}))}},"undefined"==typeof lity&&"true"===moove_frontend_gdpr_scripts.load_lity){var v=moove_frontend_gdpr_scripts.plugin_dir+"/dist/scripts/lity.js",g=moove_frontend_gdpr_scripts.plugin_dir+"/dist/styles/lity.css";postscribe(document.body,'<script src="'+v+'"><\/script>'),postscribe(document.head,'<link href="'+g+'" rel="stylesheet">'),console.log("lity lightbox loaded by JS")}var y="",k=!1;if(window.location.hash){var b=window.location.hash.substring(1);"moove_gdpr_cookie_modal"===b&&(k=!0,t("opened_modal_from_link",""),setTimeout(function(){y=lity("#moove_gdpr_cookie_modal"),e(".lity").addClass("moove_gdpr_cookie_modal_open"),e(document).moove_lity_open()},500))}if(window.location.hash){var b=window.location.hash.substring(1);"gdpr_cookie_modal"===b&&(k=!0,t("opened_modal_from_link",""),setTimeout(function(){y=lity("#moove_gdpr_cookie_modal"),e(".lity").addClass("moove_gdpr_cookie_modal_open"),e(document).moove_lity_open()},500))}!function(){var t=(location.pathname,e(window).scrollTop());e("#moove_gdpr_save_popup_settings_button").show();var r=moove_frontend_gdpr_scripts.enabled_default.third_party,n=moove_frontend_gdpr_scripts.enabled_default.advanced;if(void 0!==moove_frontend_gdpr_scripts.enable_on_scroll&&"true"===moove_frontend_gdpr_scripts.enable_on_scroll&&1!==parseInt(r)&&1!==parseInt(n)&&(r=1,n=1),document.cookie.indexOf("moove_gdpr_popup")>=0||1==r||1==n){var l=d("moove_gdpr_popup");if(l){var _=o();"0"==_.strict&&"0"==_.advanced&&"0"==_.thirdparty&&(u(),a())}else{var f=!1;if("undefined"!=typeof sessionStorage&&(f=sessionStorage.getItem("gdpr_session")),void 0!==moove_frontend_gdpr_scripts.enable_on_scroll&&"true"===moove_frontend_gdpr_scripts.enable_on_scroll)if(f)try{i(JSON.parse(f)),a(),h=!0,p(f)}catch(e){}else e(window).scroll(function(){if(!h&&e(this).scrollTop()-t>200){l={strict:1,thirdparty:r,advanced:n},d("moove_gdpr_popup")||"undefined"!=typeof sessionStorage&&((f=sessionStorage.getItem("gdpr_session"))||(sessionStorage.setItem("gdpr_session",JSON.stringify(l)),f=sessionStorage.getItem("gdpr_session")));try{i(l),l=JSON.stringify(l),a(),h=!0,p(l),void 0!==moove_frontend_gdpr_scripts.gdpr_aos_hide&&"true"===moove_frontend_gdpr_scripts.gdpr_aos_hide&&(c("moove_gdpr_popup",l,365),s())}catch(e){}}});else l={strict:1,thirdparty:r,advanced:n},i(l),l=JSON.stringify(l),a()}p(l)}else a()}(),e(document).on("click",'[data-href*="#moove_gdpr_cookie_modal"],[href*="#moove_gdpr_cookie_modal"]',function(o){o.preventDefault(),k=!0,y=lity("#moove_gdpr_cookie_modal"),e(".lity").addClass("moove_gdpr_cookie_modal_open"),e(document).moove_lity_open(),t("opened_modal_from_link","")}),e(document).on("click",'[data-href*="#gdpr_cookie_modal"],[href*="#gdpr_cookie_modal"]',function(o){o.preventDefault(),k=!0,y=lity("#moove_gdpr_cookie_modal"),e(".lity").addClass("moove_gdpr_cookie_modal_open"),e(document).moove_lity_open(),t("opened_modal_from_link","")}),e(document).on("click","#moove_gdpr_cookie_info_bar .moove-gdpr-close-modal-button a, #moove_gdpr_cookie_info_bar .moove-gdpr-close-modal-button button",function(e){e.preventDefault()}),e(document).on("click",".moove-gdpr-modal-close",function(t){t.preventDefault(),e(".lity .lity-close").click(),e(document).moove_lity_close()}),e(document).on("click","#moove-gdpr-menu .moove-gdpr-tab-nav",function(o){o.preventDefault(),o.stopPropagation(),e("#moove-gdpr-menu li").removeClass("menu-item-selected"),e(this).parent().addClass("menu-item-selected"),e(".moove-gdpr-tab-content .moove-gdpr-tab-main").hide(),e(e(this).attr("href")).show(),e(e(this).attr("data-href")).show(),t("clicked_to_tab",e(this).attr("data-href"))}),e(document).on("lity:close",function(t,o){e(document).moove_lity_close()}),e.fn.moove_lity_close=function(t){k&&(e("body").removeClass("moove_gdpr_overflow"),k=!1)},e.fn.moove_lity_open=function(t){if(k){e("body").addClass("moove_gdpr_overflow");var o=d("moove_gdpr_popup");e(".moove-gdpr-status-bar input[type=checkbox]").each(function(){e(this).is(":checked")?e(this).closest(".moove-gdpr-tab-main").find(".moove-gdpr-strict-warning-message").slideUp():e(this).closest(".moove-gdpr-tab-main").find(".moove-gdpr-strict-warning-message").slideDown()}),o&&(o=JSON.parse(o),i(o)),e(".moove-gdpr-modal-save-settings").hide().removeClass("button-visible"),l()}},e(document).on("lity:open",function(t,o){e(document).moove_lity_open()}),e(document).on("click",".fl-disabled",function(t){e("#moove_gdpr_cookie_modal .moove-gdpr-modal-content").is(".moove_gdpr_modal_theme_v2")?(e("#moove_gdpr_strict_cookies").click(),e(this).click()):e(this).closest(".moove-gdpr-tab-main-content").find(".moove-gdpr-strict-secondary-warning-message").slideDown()}),e(document).on("change",".moove-gdpr-status-bar input[type=checkbox]",function(t){e(".moove-gdpr-modal-save-settings").show().addClass("button-visible"),e(".moove-gdpr-modal-allow-all").hide().removeClass("button-visible");var o=e(this).closest(".moove-gdpr-tab-main").attr("id");e(this).closest(".moove-gdpr-status-bar").toggleClass("checkbox-selected"),e(this).closest(".moove-gdpr-tab-main").toggleClass("checkbox-selected"),e("#moove-gdpr-menu .menu-item-"+o).toggleClass("menu-item-off"),e(this).is(":checked")?e(this).closest(".moove-gdpr-tab-main").find(".moove-gdpr-strict-warning-message").slideUp():e(this).closest(".moove-gdpr-tab-main").find(".moove-gdpr-strict-warning-message").slideDown(),e(this).is("#moove_gdpr_strict_cookies")&&(e(this).is(":checked")?(e("#third_party_cookies fieldset").removeClass("fl-disabled"),e("#moove_gdpr_performance_cookies").prop("disabled",!1),e("#third_party_cookies .moove-gdpr-strict-secondary-warning-message").slideUp(),e("#advanced-cookies fieldset").removeClass("fl-disabled"),e("#advanced-cookies .moove-gdpr-strict-secondary-warning-message").slideUp(),e("#moove_gdpr_advanced_cookies").prop("disabled",!1)):(e(".gdpr_cookie_settings_shortcode_content").find("input").each(function(){e(this).prop("checked",!1)}),
|
2 |
-
e("#third_party_cookies fieldset").addClass("fl-disabled").closest(".moove-gdpr-status-bar").removeClass("checkbox-selected"),e("#moove_gdpr_performance_cookies").prop("disabled",!0).prop("checked",!1),e("#advanced-cookies fieldset").addClass("fl-disabled").closest(".moove-gdpr-status-bar").removeClass("checkbox-selected"),e("#moove_gdpr_advanced_cookies").prop("disabled",!0).prop("checked",!1))),e('input[data-name="'+e(this).attr("name")+'"]').prop("checked",e(this).is(":checked")),
|
1 |
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.postscribe=t():e.postscribe=t()}(this,function(){return function(e){function t(r){if(o[r])return o[r].exports;var n=o[r]={exports:{},id:r,loaded:!1};return e[r].call(n.exports,n,n.exports,t),n.loaded=!0,n.exports}var o={};return t.m=e,t.c=o,t.p="",t(0)}([function(e,t,o){"use strict";var r=o(1),n=function(e){return e&&e.__esModule?e:{default:e}}(r);e.exports=n.default},function(e,t,o){"use strict";function r(){}function n(){var e=f.shift();if(e){var t=l.last(e);t.afterDequeue(),e.stream=i.apply(void 0,e),t.afterStreamStart()}}function i(e,t,o){function i(e){e=o.beforeWrite(e),m.write(e),o.afterWrite(e)}m=new d.default(e,o),m.id=_++,m.name=o.name||m.id,s.streams[m.name]=m;var c=e.ownerDocument,p={close:c.close,open:c.open,write:c.write,writeln:c.writeln};a(c,{close:r,open:r,write:function(){for(var e=arguments.length,t=Array(e),o=0;o<e;o++)t[o]=arguments[o];return i(t.join(""))},writeln:function(){for(var e=arguments.length,t=Array(e),o=0;o<e;o++)t[o]=arguments[o];return i(t.join("")+"\n")}});var l=m.win.onerror||r;return m.win.onerror=function(e,t,r){o.error({msg:e+" - "+t+": "+r}),l.apply(m.win,[e,t,r])},m.write(t,function(){a(c,p),m.win.onerror=l,o.done(),m=null,n()}),m}function s(e,t,o){if(l.isFunction(o))o={done:o};else if("clear"===o)return f=[],m=null,void(_=0);o=l.defaults(o,u),e=/^#/.test(e)?window.document.getElementById(e.substr(1)):e.jquery?e[0]:e;var i=[e,t,o];return e.postscribe={cancel:function(){i.stream?i.stream.abort():i[1]=r}},o.beforeEnqueue(i),f.push(i),m||n(),e.postscribe}t.__esModule=!0;var a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var o=arguments[t];for(var r in o)Object.prototype.hasOwnProperty.call(o,r)&&(e[r]=o[r])}return e};t.default=s;var c=o(2),d=function(e){return e&&e.__esModule?e:{default:e}}(c),p=o(4),l=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t.default=e,t}(p),u={afterAsync:r,afterDequeue:r,afterStreamStart:r,afterWrite:r,autoFix:!0,beforeEnqueue:r,beforeWriteToken:function(e){return e},beforeWrite:function(e){return e},done:r,error:function(e){throw new Error(e.msg)},releaseAsync:!1},_=0,f=[],m=null;a(s,{streams:{},queue:f,WriteStream:d.default})},function(e,t,o){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){var o=l+t,r=e.getAttribute(o);return p.existy(r)?String(r):r}function i(e,t){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=l+t;p.existy(o)&&""!==o?e.setAttribute(r,o):e.removeAttribute(r)}t.__esModule=!0;var s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var o=arguments[t];for(var r in o)Object.prototype.hasOwnProperty.call(o,r)&&(e[r]=o[r])}return e},a=o(3),c=function(e){return e&&e.__esModule?e:{default:e}}(a),d=o(4),p=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t.default=e,t}(d),l="data-ps-",u="ps-style",_="ps-script",f=function(){function e(t){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};r(this,e),this.root=t,this.options=o,this.doc=t.ownerDocument,this.win=this.doc.defaultView||this.doc.parentWindow,this.parser=new c.default("",{autoFix:o.autoFix}),this.actuals=[t],this.proxyHistory="",this.proxyRoot=this.doc.createElement(t.nodeName),this.scriptStack=[],this.writeQueue=[],i(this.proxyRoot,"proxyof",0)}return e.prototype.write=function(){var e;for((e=this.writeQueue).push.apply(e,arguments);!this.deferredRemote&&this.writeQueue.length;){var t=this.writeQueue.shift();p.isFunction(t)?this._callFunction(t):this._writeImpl(t)}},e.prototype._callFunction=function(e){var t={type:"function",value:e.name||e.toString()};this._onScriptStart(t),e.call(this.win,this.doc),this._onScriptDone(t)},e.prototype._writeImpl=function(e){this.parser.append(e);for(var t=void 0,o=void 0,r=void 0,n=[];(t=this.parser.readToken())&&!(o=p.isScript(t))&&!(r=p.isStyle(t));)(t=this.options.beforeWriteToken(t))&&n.push(t);n.length>0&&this._writeStaticTokens(n),o&&this._handleScriptToken(t),r&&this._handleStyleToken(t)},e.prototype._writeStaticTokens=function(e){var t=this._buildChunk(e);return t.actual?(t.html=this.proxyHistory+t.actual,this.proxyHistory+=t.proxy,this.proxyRoot.innerHTML=t.html,this._walkChunk(),t):null},e.prototype._buildChunk=function(e){for(var t=this.actuals.length,o=[],r=[],n=[],i=e.length,s=0;s<i;s++){var a=e[s],c=a.toString();if(o.push(c),a.attrs){if(!/^noscript$/i.test(a.tagName)){var d=t++;r.push(c.replace(/(\/?>)/," "+l+"id="+d+" $1")),a.attrs.id!==_&&a.attrs.id!==u&&n.push("atomicTag"===a.type?"":"<"+a.tagName+" "+l+"proxyof="+d+(a.unary?" />":">"))}}else r.push(c),n.push("endTag"===a.type?c:"")}return{tokens:e,raw:o.join(""),actual:r.join(""),proxy:n.join("")}},e.prototype._walkChunk=function(){for(var e=void 0,t=[this.proxyRoot];p.existy(e=t.shift());){var o=1===e.nodeType;if(!(o&&n(e,"proxyof"))){o&&(this.actuals[n(e,"id")]=e,i(e,"id"));var r=e.parentNode&&n(e.parentNode,"proxyof");r&&this.actuals[r].appendChild(e)}t.unshift.apply(t,p.toArray(e.childNodes))}},e.prototype._handleScriptToken=function(e){var t=this,o=this.parser.clear();o&&this.writeQueue.unshift(o),e.src=e.attrs.src||e.attrs.SRC,(e=this.options.beforeWriteToken(e))&&(e.src&&this.scriptStack.length?this.deferredRemote=e:this._onScriptStart(e),this._writeScriptToken(e,function(){t._onScriptDone(e)}))},e.prototype._handleStyleToken=function(e){var t=this.parser.clear();t&&this.writeQueue.unshift(t),e.type=e.attrs.type||e.attrs.TYPE||"text/css",e=this.options.beforeWriteToken(e),e&&this._writeStyleToken(e),t&&this.write()},e.prototype._writeStyleToken=function(e){var t=this._buildStyle(e);this._insertCursor(t,u),e.content&&(t.styleSheet&&!t.sheet?t.styleSheet.cssText=e.content:t.appendChild(this.doc.createTextNode(e.content)))},e.prototype._buildStyle=function(e){var t=this.doc.createElement(e.tagName);return t.setAttribute("type",e.type),p.eachKey(e.attrs,function(e,o){t.setAttribute(e,o)}),t},e.prototype._insertCursor=function(e,t){this._writeImpl('<span id="'+t+'"/>');var o=this.doc.getElementById(t);o&&o.parentNode.replaceChild(e,o)},e.prototype._onScriptStart=function(e){e.outerWrites=this.writeQueue,this.writeQueue=[],this.scriptStack.unshift(e)},e.prototype._onScriptDone=function(e){return e!==this.scriptStack[0]?void this.options.error({msg:"Bad script nesting or script finished twice"}):(this.scriptStack.shift(),this.write.apply(this,e.outerWrites),void(!this.scriptStack.length&&this.deferredRemote&&(this._onScriptStart(this.deferredRemote),this.deferredRemote=null)))},e.prototype._writeScriptToken=function(e,t){var o=this._buildScript(e),r=this._shouldRelease(o),n=this.options.afterAsync;e.src&&(o.src=e.src,this._scriptLoadHandler(o,r?n:function(){t(),n()}));try{this._insertCursor(o,_),o.src&&!r||t()}catch(e){this.options.error(e),t()}},e.prototype._buildScript=function(e){var t=this.doc.createElement(e.tagName);return p.eachKey(e.attrs,function(e,o){t.setAttribute(e,o)}),e.content&&(t.text=e.content),t},e.prototype._scriptLoadHandler=function(e,t){function o(){e=e.onload=e.onreadystatechange=e.onerror=null}function r(){o(),null!=t&&t(),t=null}function n(e){o(),a(e),null!=t&&t(),t=null}function i(e,t){var o=e["on"+t];null!=o&&(e["_on"+t]=o)}var a=this.options.error;i(e,"load"),i(e,"error"),s(e,{onload:function(){if(e._onload)try{e._onload.apply(this,Array.prototype.slice.call(arguments,0))}catch(t){n({msg:"onload handler failed "+t+" @ "+e.src})}r()},onerror:function(){if(e._onerror)try{e._onerror.apply(this,Array.prototype.slice.call(arguments,0))}catch(t){return void n({msg:"onerror handler failed "+t+" @ "+e.src})}n({msg:"remote script failed "+e.src})},onreadystatechange:function(){/^(loaded|complete)$/.test(e.readyState)&&r()}})},e.prototype._shouldRelease=function(e){return!/^script$/i.test(e.nodeName)||!!(this.options.releaseAsync&&e.src&&e.hasAttribute("async"))},e}();t.default=f},function(e,t,o){!function(t,o){e.exports=function(){return function(e){function t(r){if(o[r])return o[r].exports;var n=o[r]={exports:{},id:r,loaded:!1};return e[r].call(n.exports,n,n.exports,t),n.loaded=!0,n.exports}var o={};return t.m=e,t.c=o,t.p="",t(0)}([function(e,t,o){"use strict";var r=o(1),n=function(e){return e&&e.__esModule?e:{default:e}}(r);e.exports=n.default},function(e,t,o){"use strict";function r(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t.default=e,t}function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=o(2),s=r(i),a=o(3),c=r(a),d=o(6),p=function(e){return e&&e.__esModule?e:{default:e}}(d),l=o(5),u={comment:/^<!--/,endTag:/^<\//,atomicTag:/^<\s*(script|style|noscript|iframe|textarea)[\s\/>]/i,startTag:/^</,chars:/^[^<]/},_=function(){function e(){var t=this,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};n(this,e),this.stream=o;var i=!1,a={};for(var c in s)s.hasOwnProperty(c)&&(r.autoFix&&(a[c+"Fix"]=!0),i=i||a[c+"Fix"]);i?(this._readToken=(0,p.default)(this,a,function(){return t._readTokenImpl()}),this._peekToken=(0,p.default)(this,a,function(){return t._peekTokenImpl()})):(this._readToken=this._readTokenImpl,this._peekToken=this._peekTokenImpl)}return e.prototype.append=function(e){this.stream+=e},e.prototype.prepend=function(e){this.stream=e+this.stream},e.prototype._readTokenImpl=function(){var e=this._peekTokenImpl();if(e)return this.stream=this.stream.slice(e.length),e},e.prototype._peekTokenImpl=function(){for(var e in u)if(u.hasOwnProperty(e)&&u[e].test(this.stream)){var t=c[e](this.stream);if(t)return"startTag"===t.type&&/script|style/i.test(t.tagName)?null:(t.text=this.stream.substr(0,t.length),t)}},e.prototype.peekToken=function(){return this._peekToken()},e.prototype.readToken=function(){return this._readToken()},e.prototype.readTokens=function(e){for(var t=void 0;t=this.readToken();)if(e[t.type]&&!1===e[t.type](t))return},e.prototype.clear=function(){var e=this.stream;return this.stream="",e},e.prototype.rest=function(){return this.stream},e}();t.default=_,_.tokenToString=function(e){return e.toString()},_.escapeAttributes=function(e){var t={};for(var o in e)e.hasOwnProperty(o)&&(t[o]=(0,l.escapeQuotes)(e[o],null));return t},_.supports=s;for(var f in s)s.hasOwnProperty(f)&&(_.browserHasFlaw=_.browserHasFlaw||!s[f]&&f)},function(e,t){"use strict";t.__esModule=!0;var o=!1,r=!1,n=window.document.createElement("div");try{var i="<P><I></P></I>";n.innerHTML=i,t.tagSoup=o=n.innerHTML!==i}catch(e){t.tagSoup=o=!1}try{n.innerHTML="<P><i><P></P></i></P>",t.selfClose=r=2===n.childNodes.length}catch(e){t.selfClose=r=!1}n=null,t.tagSoup=o,t.selfClose=r},function(e,t,o){"use strict";function r(e){var t=e.indexOf("--\x3e");if(t>=0)return new d.CommentToken(e.substr(4,t-1),t+3)}function n(e){var t=e.indexOf("<");return new d.CharsToken(t>=0?t:e.length)}function i(e){if(-1!==e.indexOf(">")){var t=e.match(p.startTag);if(t){var o=function(){var e={},o={},r=t[2];return t[2].replace(p.attr,function(t,n){arguments[2]||arguments[3]||arguments[4]||arguments[5]?arguments[5]?(e[arguments[5]]="",o[arguments[5]]=!0):e[n]=arguments[2]||arguments[3]||arguments[4]||p.fillAttr.test(n)&&n||"":e[n]="",r=r.replace(t,"")}),{v:new d.StartTagToken(t[1],t[0].length,e,o,!!t[3],r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""))}}();if("object"===(void 0===o?"undefined":c(o)))return o.v}}}function s(e){var t=i(e);if(t){var o=e.slice(t.length);if(o.match(new RegExp("</\\s*"+t.tagName+"\\s*>","i"))){var r=o.match(new RegExp("([\\s\\S]*?)</\\s*"+t.tagName+"\\s*>","i"));if(r)return new d.AtomicTagToken(t.tagName,r[0].length+t.length,t.attrs,t.booleanAttrs,r[1])}}}function a(e){var t=e.match(p.endTag);if(t)return new d.EndTagToken(t[1],t[0].length)}t.__esModule=!0;var c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.comment=r,t.chars=n,t.startTag=i,t.atomicTag=s,t.endTag=a;var d=o(4),p={startTag:/^<([\-A-Za-z0-9_]+)((?:\s+[\w\-]+(?:\s*=?\s*(?:(?:"[^"]*")|(?:'[^']*')|[^>\s]+))?)*)\s*(\/?)>/,endTag:/^<\/([\-A-Za-z0-9_]+)[^>]*>/,attr:/(?:([\-A-Za-z0-9_]+)\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|([^>\s]+)))|(?:([\-A-Za-z0-9_]+)(\s|$)+)/g,fillAttr:/^(checked|compact|declare|defer|disabled|ismap|multiple|nohref|noresize|noshade|nowrap|readonly|selected)$/i}},function(e,t,o){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0,t.EndTagToken=t.AtomicTagToken=t.StartTagToken=t.TagToken=t.CharsToken=t.CommentToken=t.Token=void 0;var n=o(5),i=(t.Token=function e(t,o){r(this,e),this.type=t,this.length=o,this.text=""},t.CommentToken=function(){function e(t,o){r(this,e),this.type="comment",this.length=o||(t?t.length:0),this.text="",this.content=t}return e.prototype.toString=function(){return"\x3c!--"+this.content},e}(),t.CharsToken=function(){function e(t){r(this,e),this.type="chars",this.length=t,this.text=""}return e.prototype.toString=function(){return this.text},e}(),t.TagToken=function(){function e(t,o,n,i,s){r(this,e),this.type=t,this.length=n,this.text="",this.tagName=o,this.attrs=i,this.booleanAttrs=s,this.unary=!1,this.html5Unary=!1}return e.formatTag=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o="<"+e.tagName;for(var r in e.attrs)if(e.attrs.hasOwnProperty(r)){o+=" "+r;var i=e.attrs[r];void 0!==e.booleanAttrs&&void 0!==e.booleanAttrs[r]||(o+='="'+(0,n.escapeQuotes)(i)+'"')}return e.rest&&(o+=" "+e.rest),o+=e.unary&&!e.html5Unary?"/>":">",void 0!==t&&null!==t&&(o+=t+"</"+e.tagName+">"),o},e}());t.StartTagToken=function(){function e(t,o,n,i,s,a){r(this,e),this.type="startTag",this.length=o,this.text="",this.tagName=t,this.attrs=n,this.booleanAttrs=i,this.html5Unary=!1,this.unary=s,this.rest=a}return e.prototype.toString=function(){return i.formatTag(this)},e}(),t.AtomicTagToken=function(){function e(t,o,n,i,s){r(this,e),this.type="atomicTag",this.length=o,this.text="",this.tagName=t,this.attrs=n,this.booleanAttrs=i,this.unary=!1,this.html5Unary=!1,this.content=s}return e.prototype.toString=function(){return i.formatTag(this,this.content)},e}(),t.EndTagToken=function(){function e(t,o){r(this,e),this.type="endTag",this.length=o,this.text="",this.tagName=t}return e.prototype.toString=function(){return"</"+this.tagName+">"},e}()},function(e,t){"use strict";function o(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return e?e.replace(/([^"]*)"/g,function(e,t){return/\\/.test(t)?t+'"':t+'\\"'}):t}t.__esModule=!0,t.escapeQuotes=o},function(e,t){"use strict";function o(e){return e&&"startTag"===e.type&&(e.unary=a.test(e.tagName)||e.unary,e.html5Unary=!/\/>$/.test(e.text)),e}function r(e,t){var r=e.stream,n=o(t());return e.stream=r,n}function n(e,t){var o=t.pop();e.prepend("</"+o.tagName+">")}function i(){var e=[];return e.last=function(){return this[this.length-1]},e.lastTagNameEq=function(e){var t=this.last();return t&&t.tagName&&t.tagName.toUpperCase()===e.toUpperCase()},e.containsTagName=function(e){for(var t,o=0;t=this[o];o++)if(t.tagName===e)return!0;return!1},e}function s(e,t,s){function a(){var t=r(e,s);t&&p[t.type]&&p[t.type](t)}var d=i(),p={startTag:function(o){var r=o.tagName;"TR"===r.toUpperCase()&&d.lastTagNameEq("TABLE")?(e.prepend("<TBODY>"),a()):t.selfCloseFix&&c.test(r)&&d.containsTagName(r)?d.lastTagNameEq(r)?n(e,d):(e.prepend("</"+o.tagName+">"),a()):o.unary||d.push(o)},endTag:function(o){d.last()?t.tagSoupFix&&!d.lastTagNameEq(o.tagName)?n(e,d):d.pop():t.tagSoupFix&&(s(),a())}};return function(){return a(),o(s())}}t.__esModule=!0,t.default=s;var a=/^(AREA|BASE|BASEFONT|BR|COL|FRAME|HR|IMG|INPUT|ISINDEX|LINK|META|PARAM|EMBED)$/i,c=/^(COLGROUP|DD|DT|LI|OPTIONS|P|TD|TFOOT|TH|THEAD|TR)$/i}])}()}()},function(e,t){"use strict";function o(e){return void 0!==e&&null!==e}function r(e){return"function"==typeof e}function n(e,t,o){var r=void 0,n=e&&e.length||0;for(r=0;r<n;r++)t.call(o,e[r],r)}function i(e,t,o){for(var r in e)e.hasOwnProperty(r)&&t.call(o,r,e[r])}function s(e,t){return e=e||{},i(t,function(t,r){o(e[t])||(e[t]=r)}),e}function a(e){try{return Array.prototype.slice.call(e)}catch(o){var t=function(){var t=[];return n(e,function(e){t.push(e)}),{v:t}}();if("object"===(void 0===t?"undefined":u(t)))return t.v}}function c(e){return e[e.length-1]}function d(e,t){return!(!e||"startTag"!==e.type&&"atomicTag"!==e.type||!("tagName"in e)||!~e.tagName.toLowerCase().indexOf(t))}function p(e){return d(e,"script")}function l(e){return d(e,"style")}t.__esModule=!0;var u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.existy=o,t.isFunction=r,t.each=n,t.eachKey=i,t.defaults=s,t.toArray=a,t.last=c,t.isTag=d,t.isScript=p,t.isStyle=l}])}),function(e){var t={common:{init:function(){"use strict";function t(e,t){try{jQuery().gdpr_cookie_compliance_analytics(e,t)}catch(e){}}function o(){var e=p("moove_gdpr_popup"),o={};return o.strict="0",o.thirdparty="0",o.advanced="0",e&&(e=JSON.parse(e),o.strict=e.strict,o.thirdparty=e.thirdparty,o.advanced=e.advanced,s(o),t("script_inject",e)),void 0!==moove_frontend_gdpr_scripts.ifbc?("strict"===moove_frontend_gdpr_scripts.ifbc&&e&&1===parseInt(e.strict)&&r(),"thirdparty"===moove_frontend_gdpr_scripts.ifbc&&e&&1===parseInt(e.thirdparty)&&r(),"advanced"===moove_frontend_gdpr_scripts.ifbc&&e&&1===parseInt(e.advanced)&&r()):"1"!==moove_frontend_gdpr_scripts.strict_init&&r(),o}function r(){e(document).find("iframe[data-gdpr-iframesrc]").each(function(){e(this).attr("src",e(this).attr("data-gdpr-iframesrc"))})}function n(e){d("moove_gdpr_popup",JSON.stringify({strict:"1",thirdparty:"1",advanced:"1"}),m),i("enabled-all"),t("accept_all","")}function i(t){var r=!1;try{void 0!==moove_frontend_gdpr_scripts.force_reload&&"true"===moove_frontend_gdpr_scripts.force_reload&&(r=!0)}catch(e){}var n=o(),i=moove_frontend_gdpr_scripts.enabled_default.third_party,s=moove_frontend_gdpr_scripts.enabled_default.advanced;if(document.cookie.indexOf("moove_gdpr_popup")>=0||1==i||1==s){p("moove_gdpr_popup");1==i&&(h.strict=1,h.thirdparty=i),1==s&&(h.strict=1,h.advanced=s),h&&(parseInt(n.strict)-parseInt(h.strict)<0&&(r=!0),parseInt(n.thirdparty)-parseInt(h.thirdparty)<0&&(r=!0),parseInt(n.advanced)-parseInt(h.advanced)<0&&(r=!0))}if(r)location.reload(!0);else{l(p("moove_gdpr_popup")),a(),e("#moove_gdpr_save_popup_settings_button").show()}}function s(t){t&&(1===parseInt(t.strict)?e("#moove_gdpr_strict_cookies").is(":checked")||(e("#moove_gdpr_strict_cookies").click(),e("#third_party_cookies fieldset").removeClass("fl-disabled"),e("#moove_gdpr_performance_cookies").prop("disabled",!1),e("#third_party_cookies .moove-gdpr-strict-secondary-warning-message").slideUp(),e("#advanced-cookies fieldset").removeClass("fl-disabled"),e("#advanced-cookies .moove-gdpr-strict-secondary-warning-message").slideUp(),e("#moove_gdpr_advanced_cookies").prop("disabled",!1)):e("#moove_gdpr_strict_cookies").is(":checked")&&(e("#moove_gdpr_strict_cookies").click().prop("checked",!0),e("#third_party_cookies fieldset").addClass("fl-disabled").closest(".moove-gdpr-status-bar").removeClass("checkbox-selected"),e("#moove_gdpr_performance_cookies").prop("disabled",!0).prop("checked",!1),e("#advanced-cookies fieldset").addClass("fl-disabled").closest(".moove-gdpr-status-bar").removeClass("checkbox-selected"),e("#moove_gdpr_advanced_cookies").prop("disabled",!0).prop("checked",!1)),1===parseInt(t.thirdparty)?e("#moove_gdpr_performance_cookies").is(":checked")||e("#moove_gdpr_performance_cookies").click():e("#moove_gdpr_performance_cookies").is(":checked")&&e("#moove_gdpr_performance_cookies").click(),1===parseInt(t.advanced)?e("#moove_gdpr_advanced_cookies").is(":checked")||e("#moove_gdpr_advanced_cookies").click():e("#moove_gdpr_advanced_cookies").is(":checked")&&e("#moove_gdpr_advanced_cookies").click(),e('input[data-name="moove_gdpr_performance_cookies"]').prop("checked",e("#moove_gdpr_performance_cookies").is(":checked")),e('input[data-name="moove_gdpr_strict_cookies"]').prop("checked",e("#moove_gdpr_strict_cookies").is(":checked")),e('input[data-name="moove_gdpr_advanced_cookies"]').prop("checked",e("#moove_gdpr_advanced_cookies").is(":checked")))}function a(){e("#moove_gdpr_cookie_info_bar").length>0&&(e("#moove_gdpr_cookie_info_bar").addClass("moove-gdpr-info-bar-hidden"),e("body").removeClass("gdpr-infobar-visible"))}function c(){if(void 0!==moove_frontend_gdpr_scripts.display_cookie_banner){if("true"===moove_frontend_gdpr_scripts.display_cookie_banner)e("#moove_gdpr_cookie_info_bar").length>0&&(e("#moove_gdpr_cookie_info_bar").removeClass("moove-gdpr-info-bar-hidden"),e("#moove_gdpr_save_popup_settings_button:not(.button-visible)").hide(),e("body").addClass("gdpr-infobar-visible"),t("show_infobar",""));else if(e("#moove_gdpr_cookie_info_bar").length>0){e("#moove_gdpr_cookie_info_bar").addClass("moove-gdpr-info-bar-hidden"),e("body").removeClass("gdpr-infobar-visible");var o={strict:1,thirdparty:1,advanced:1};l(JSON.stringify(o))}}else e("#moove_gdpr_cookie_info_bar").length>0&&(e("#moove_gdpr_cookie_info_bar").removeClass("moove-gdpr-info-bar-hidden"),e("#moove_gdpr_save_popup_settings_button:not(.button-visible)").hide(),e("body").addClass("gdpr-infobar-visible"),t("show_infobar",""))}function d(e,t,o){var r;if(o){var n=new Date;n.setTime(n.getTime()+24*o*60*60*1e3),r="; expires="+n.toGMTString()}else r="";document.cookie=encodeURIComponent(e)+"="+encodeURIComponent(t)+r+"; path=/",JSON.parse(t)}function p(e){for(var t=encodeURIComponent(e)+"=",o=document.cookie.split(";"),r=0;r<o.length;r++){for(var n=o[r];" "===n.charAt(0);)n=n.substring(1,n.length);if(0===n.indexOf(t))return decodeURIComponent(n.substring(t.length,n.length))}return null}function l(n){if(h=o(),n){var i=n;n=JSON.parse(n);o();if(!1!==v){var s=JSON.parse(v);1===parseInt(s.thirdparty)&&1===parseInt(n.thirdparty)&&(n.thirdparty="0"),1===parseInt(s.advanced)&&1===parseInt(n.advanced)&&(n.advanced="0")}t("script_inject",n),g=!0,void 0!==moove_frontend_gdpr_scripts.ifbc?("strict"===moove_frontend_gdpr_scripts.ifbc&&n&&1===parseInt(n.strict)&&r(),"thirdparty"===moove_frontend_gdpr_scripts.ifbc&&n&&1===parseInt(n.thirdparty)&&r(),"advanced"===moove_frontend_gdpr_scripts.ifbc&&n&&1===parseInt(n.advanced)&&r()):1===parseInt(n.strict)&&r(),e.post(moove_frontend_gdpr_scripts.ajaxurl,{action:"moove_gdpr_get_scripts",strict:n.strict,thirdparty:n.thirdparty,advanced:n.advanced},function(t){v=i;var o=JSON.parse(t);o.header&&postscribe(document.head,o.header),o.body&&e(o.body).prependTo(document.body),o.footer&&postscribe(document.body,o.footer)})}else c()}function u(){var t=!0;e("#moove_gdpr_cookie_modal").find("input[type=checkbox]").each(function(){e(this).is(":checked")||(t=!1)}),t?e(".moove-gdpr-button-holder .moove-gdpr-modal-allow-all").hide().removeClass("button-visible"):e(".moove-gdpr-button-holder .moove-gdpr-modal-save-settings").is(":visible")?e(".moove-gdpr-button-holder .moove-gdpr-modal-allow-all").hide().removeClass("button-visible"):e(".moove-gdpr-button-holder .moove-gdpr-modal-allow-all").show().addClass("button-visible")}function _(){for(var e=document.cookie.split("; "),t=0;t<e.length;t++)for(var o=window.location.hostname.split(".");o.length>0;){var r=encodeURIComponent(e[t].split(";")[0].split("=")[0])+"=; expires=Thu, 01-Jan-1970 00:00:01 GMT; domain="+o.join(".")+" ; path=",n=location.pathname.split("/");for(document.cookie=r+"/";n.length>0;)document.cookie=r+n.join("/"),n.pop();o.shift()}}function f(){var t=p("moove_gdpr_popup");_();var o="0",r="0",n="0",i=!1;t&&(t=JSON.parse(t),o=t.strict,r=t.advanced,n=t.thirdparty),e("#moove_gdpr_strict_cookies").length>0?e("#moove_gdpr_strict_cookies").is(":checked")?(o="1",i=!0):o="0":(i=!0,o="1"),e("#moove_gdpr_performance_cookies").is(":checked")?(n="1",i=!0):n="0",e("#moove_gdpr_advanced_cookies").is(":checked")?(r="1",i=!0):r="0",!t&&i?(d("moove_gdpr_popup",JSON.stringify({strict:o,thirdparty:n,advanced:r}),m),a(),e("#moove_gdpr_save_popup_settings_button").show()):t&&d("moove_gdpr_popup",JSON.stringify({strict:o,thirdparty:n,advanced:r}),m);var t=p("moove_gdpr_popup");t&&(t=JSON.parse(t),"0"==t.strict&&"0"==t.advanced&&"0"==t.thirdparty&&_())}var m=365;void 0!==moove_frontend_gdpr_scripts.cookie_expiration&&(m=moove_frontend_gdpr_scripts.cookie_expiration),e(document).on("click","#moove_gdpr_cookie_info_bar .moove-gdpr-infobar-reject-btn",function(t){t.preventDefault(),d("moove_gdpr_popup",JSON.stringify({strict:"1",thirdparty:"0",advanced:"0"}),m),e("#moove_gdpr_cookie_info_bar").length>0&&(e("#moove_gdpr_cookie_info_bar").addClass("moove-gdpr-info-bar-hidden"),e("body").removeClass("gdpr-infobar-visible"),location.reload(!0))}),e.fn.moove_gdpr_read_cookies=function(e){var t=p("moove_gdpr_popup"),o={};return o.strict="0",o.thirdparty="0",o.advanced="0",t&&(t=JSON.parse(t),o.strict=t.strict,o.thirdparty=t.thirdparty,o.advanced=t.advanced),o};var h=o(),v=!1,g=!1;if(e.fn.moove_gdpr_save_cookie=function(o){var n=p("moove_gdpr_popup"),i=e(window).scrollTop();if(!n){if(o.thirdParty)var a="1";else var a="0";if(o.advanced)var c="1";else var c="0";if(o.scrollEnable){var l=o.scrollEnable;e(window).scroll(function(){!g&&e(this).scrollTop()-i>l&&("undefined"===o.thirdparty&&"undefined"===o.advanced||(d("moove_gdpr_popup",JSON.stringify({strict:"1",thirdparty:a,advanced:c}),m),n=JSON.parse(n),s(n)))})}else"undefined"===o.thirdparty&&"undefined"===o.advanced||(d("moove_gdpr_popup",JSON.stringify({strict:"1",thirdparty:a,advanced:c}),m),n=JSON.parse(n),s(n));n=p("moove_gdpr_popup"),n&&(n=JSON.parse(n),t("script_inject",n),g=!0,void 0!==moove_frontend_gdpr_scripts.ifbc?("strict"===moove_frontend_gdpr_scripts.ifbc&&n&&1===parseInt(n.strict)&&r(),"thirdparty"===moove_frontend_gdpr_scripts.ifbc&&n&&1===parseInt(n.thirdparty)&&r(),"advanced"===moove_frontend_gdpr_scripts.ifbc&&n&&1===parseInt(n.advanced)&&r()):1===parseInt(n.strict)&&r(),jQuery.post(moove_frontend_gdpr_scripts.ajaxurl,{action:"moove_gdpr_get_scripts",strict:n.strict,thirdparty:n.thirdparty,advanced:n.advanced},function(t){var o=JSON.parse(t);o.header&&postscribe(document.head,o.header),o.body&&e(o.body).prependTo(document.body),o.footer&&postscribe(document.body,o.footer)}))}},"undefined"==typeof lity&&"true"===moove_frontend_gdpr_scripts.load_lity){var y=moove_frontend_gdpr_scripts.plugin_dir+"/dist/scripts/lity.js",k=moove_frontend_gdpr_scripts.plugin_dir+"/dist/styles/lity.css";postscribe(document.body,'<script src="'+y+'"><\/script>'),postscribe(document.head,'<link href="'+k+'" rel="stylesheet">'),console.log("lity lightbox loaded by JS")}var b="",T=!1;if(window.location.hash){var w=window.location.hash.substring(1);"moove_gdpr_cookie_modal"===w&&(T=!0,t("opened_modal_from_link",""),setTimeout(function(){b=lity("#moove_gdpr_cookie_modal"),e(".lity").addClass("moove_gdpr_cookie_modal_open"),e(document).moove_lity_open()},500))}if(window.location.hash){var w=window.location.hash.substring(1);"gdpr_cookie_modal"===w&&(T=!0,t("opened_modal_from_link",""),setTimeout(function(){b=lity("#moove_gdpr_cookie_modal"),e(".lity").addClass("moove_gdpr_cookie_modal_open"),e(document).moove_lity_open()},500))}!function(){var t=(location.pathname,e(window).scrollTop());e("#moove_gdpr_save_popup_settings_button").show();var r=moove_frontend_gdpr_scripts.enabled_default.third_party,n=moove_frontend_gdpr_scripts.enabled_default.advanced;if(void 0!==moove_frontend_gdpr_scripts.enable_on_scroll&&"true"===moove_frontend_gdpr_scripts.enable_on_scroll&&1!==parseInt(r)&&1!==parseInt(n)&&(r=1,n=1),document.cookie.indexOf("moove_gdpr_popup")>=0||1==r||1==n){var i=p("moove_gdpr_popup");if(i){var u=o();"0"==u.strict&&"0"==u.advanced&&"0"==u.thirdparty&&(_(),c())}else{var f=!1;if("undefined"!=typeof sessionStorage&&(f=sessionStorage.getItem("gdpr_session")),void 0!==moove_frontend_gdpr_scripts.enable_on_scroll&&"true"===moove_frontend_gdpr_scripts.enable_on_scroll)if(f)try{s(JSON.parse(f)),c(),g=!0,l(f)}catch(e){}else e(window).scroll(function(){if(!g&&e(this).scrollTop()-t>200){i={strict:1,thirdparty:r,advanced:n},p("moove_gdpr_popup")||"undefined"!=typeof sessionStorage&&((f=sessionStorage.getItem("gdpr_session"))||(sessionStorage.setItem("gdpr_session",JSON.stringify(i)),f=sessionStorage.getItem("gdpr_session")));try{s(i),i=JSON.stringify(i),c(),g=!0,l(i),void 0!==moove_frontend_gdpr_scripts.gdpr_aos_hide&&"true"===moove_frontend_gdpr_scripts.gdpr_aos_hide&&(d("moove_gdpr_popup",i,m),a())}catch(e){}}});else i={strict:1,thirdparty:r,advanced:n},s(i),i=JSON.stringify(i),c()}l(i)}else c()}(),e(document).on("click",'[data-href*="#moove_gdpr_cookie_modal"],[href*="#moove_gdpr_cookie_modal"]',function(o){o.preventDefault(),T=!0,b=lity("#moove_gdpr_cookie_modal"),e(".lity").addClass("moove_gdpr_cookie_modal_open"),e(document).moove_lity_open(),t("opened_modal_from_link","")}),e(document).on("click",'[data-href*="#gdpr_cookie_modal"],[href*="#gdpr_cookie_modal"]',function(o){o.preventDefault(),T=!0,b=lity("#moove_gdpr_cookie_modal"),e(".lity").addClass("moove_gdpr_cookie_modal_open"),e(document).moove_lity_open(),t("opened_modal_from_link","")}),e(document).on("click","#moove_gdpr_cookie_info_bar .moove-gdpr-close-modal-button a, #moove_gdpr_cookie_info_bar .moove-gdpr-close-modal-button button",function(e){e.preventDefault()}),e(document).on("click",".moove-gdpr-modal-close",function(t){t.preventDefault(),e(".lity .lity-close").click(),e(document).moove_lity_close()}),e(document).on("click","#moove-gdpr-menu .moove-gdpr-tab-nav",function(o){o.preventDefault(),o.stopPropagation(),e("#moove-gdpr-menu li").removeClass("menu-item-selected"),e(this).parent().addClass("menu-item-selected"),e(".moove-gdpr-tab-content .moove-gdpr-tab-main").hide(),e(e(this).attr("href")).show(),e(e(this).attr("data-href")).show(),t("clicked_to_tab",e(this).attr("data-href"))}),e(document).on("lity:close",function(t,o){e(document).moove_lity_close()}),e.fn.moove_lity_close=function(t){T&&(e("body").removeClass("moove_gdpr_overflow"),T=!1)},e.fn.moove_lity_open=function(t){if(T){e("body").addClass("moove_gdpr_overflow");var o=p("moove_gdpr_popup");e(".moove-gdpr-status-bar input[type=checkbox]").each(function(){e(this).is(":checked")?e(this).closest(".moove-gdpr-tab-main").find(".moove-gdpr-strict-warning-message").slideUp():e(this).closest(".moove-gdpr-tab-main").find(".moove-gdpr-strict-warning-message").slideDown()}),o&&(o=JSON.parse(o),s(o)),e(".moove-gdpr-modal-save-settings").hide().removeClass("button-visible"),u()}},e(document).on("lity:open",function(t,o){e(document).moove_lity_open()}),e(document).on("click",".fl-disabled",function(t){e("#moove_gdpr_cookie_modal .moove-gdpr-modal-content").is(".moove_gdpr_modal_theme_v2")?(e("#moove_gdpr_strict_cookies").click(),e(this).click()):e(this).closest(".moove-gdpr-tab-main-content").find(".moove-gdpr-strict-secondary-warning-message").slideDown()}),e(document).on("change",".moove-gdpr-status-bar input[type=checkbox]",function(t){e(".moove-gdpr-modal-save-settings").show().addClass("button-visible"),e(".moove-gdpr-modal-allow-all").hide().removeClass("button-visible");var o=e(this).closest(".moove-gdpr-tab-main").attr("id");e(this).closest(".moove-gdpr-status-bar").toggleClass("checkbox-selected"),e(this).closest(".moove-gdpr-tab-main").toggleClass("checkbox-selected"),e("#moove-gdpr-menu .menu-item-"+o).toggleClass("menu-item-off"),
|
2 |
+
e(this).is(":checked")?e(this).closest(".moove-gdpr-tab-main").find(".moove-gdpr-strict-warning-message").slideUp():e(this).closest(".moove-gdpr-tab-main").find(".moove-gdpr-strict-warning-message").slideDown(),e(this).is("#moove_gdpr_strict_cookies")&&(e(this).is(":checked")?(e("#third_party_cookies fieldset").removeClass("fl-disabled"),e("#moove_gdpr_performance_cookies").prop("disabled",!1),e("#third_party_cookies .moove-gdpr-strict-secondary-warning-message").slideUp(),e("#advanced-cookies fieldset").removeClass("fl-disabled"),e("#advanced-cookies .moove-gdpr-strict-secondary-warning-message").slideUp(),e("#moove_gdpr_advanced_cookies").prop("disabled",!1)):(e(".gdpr_cookie_settings_shortcode_content").find("input").each(function(){e(this).prop("checked",!1)}),e("#third_party_cookies fieldset").addClass("fl-disabled").closest(".moove-gdpr-status-bar").removeClass("checkbox-selected"),e("#moove_gdpr_performance_cookies").prop("disabled",!0).prop("checked",!1),e("#advanced-cookies fieldset").addClass("fl-disabled").closest(".moove-gdpr-status-bar").removeClass("checkbox-selected"),e("#moove_gdpr_advanced_cookies").prop("disabled",!0).prop("checked",!1))),e('input[data-name="'+e(this).attr("name")+'"]').prop("checked",e(this).is(":checked")),u()}),e(document).on("click",".gdpr_cookie_settings_shortcode_content a.gdpr-shr-save-settings",function(t){t.preventDefault(),f(),e(".lity .lity-close").click(),e(document).moove_lity_close(),i("modal-save-settings")}),e(document).on("change",".gdpr_cookie_settings_shortcode_content input[type=checkbox]",function(t){var o=e(this).attr("data-name"),r=e("#"+o);e(this).is(":checked")?(e('input[data-name="'+o+'"]').prop("checked",!0),"moove_gdpr_strict_cookies"!==e(this).attr("data-name")&&(e(this).closest(".gdpr_cookie_settings_shortcode_content").find('input[data-name="moove_gdpr_strict_cookies"]').is(":checked")||(e('input[data-name="'+o+'"]').prop("checked",!1),e('.gdpr_cookie_settings_shortcode_content input[data-name="moove_gdpr_strict_cookies"]').closest(".gdpr-shr-switch").css("transform","scale(1.2)"),setTimeout(function(){e('.gdpr_cookie_settings_shortcode_content input[data-name="moove_gdpr_strict_cookies"]').closest(".gdpr-shr-switch").css("transform","scale(1)")},300)))):(e('input[data-name="'+o+'"]').prop("checked",e(this).is(":checked")),"moove_gdpr_strict_cookies"===e(this).attr("data-name")&&e(".gdpr_cookie_settings_shortcode_content").find('input[type="checkbox"]').prop("checked",!1)),r.click()}),e(document).on("click",".moove-gdpr-modal-allow-all",function(t){t.preventDefault(),e("#moove_gdpr_cookie_modal").find("input[type=checkbox]").each(function(){var t=e(this);t.is(":checked")||t.click()}),n("enable_all enable-all-button"),e(".lity .lity-close").click(),a(),f(),e(document).moove_lity_close()}),e(document).on("click",".moove-gdpr-infobar-allow-all",function(e){e.preventDefault(),n("enable_all allow-btn")}),e(document).on("click",".moove-gdpr-modal-save-settings",function(t){t.preventDefault(),f(),e(".lity .lity-close").click(),e(document).moove_lity_close(),i("modal-save-settings")})},finalize:function(){}}},o={fire:function(e,o,r){var n,i=t;o=void 0===o?"init":o,n=""!==e,n=n&&i[e],(n=n&&"function"==typeof i[e][o])&&i[e][o](r)},loadEvents:function(){void 0!==moove_frontend_gdpr_scripts.geo_location&&"true"===moove_frontend_gdpr_scripts.geo_location?jQuery.post(moove_frontend_gdpr_scripts.ajaxurl,{action:"moove_gdpr_localize_scripts"},function(e){var t=JSON.parse(e);void 0!==t.display_cookie_banner&&(moove_frontend_gdpr_scripts.display_cookie_banner=t.display_cookie_banner),void 0!==t.enabled_default&&(moove_frontend_gdpr_scripts.enabled_default=t.enabled_default),o.fire("common")}):o.fire("common"),e.each(document.body.className.replace(/-/g,"_").split(/\s+/),function(e,t){o.fire(t),o.fire(t,"finalize")}),o.fire("common","finalize")}};e(document).ready(o.loadEvents)}(jQuery);
|
dist/styles/admin.css
CHANGED
@@ -1 +1 @@
|
|
1 |
-
@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-200.eot);src:url(../fonts/nunito-v8-latin-200.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-200.woff2) format("woff2"),url(../fonts/nunito-v8-latin-200.woff) format("woff"),url(../fonts/nunito-v8-latin-200.ttf) format("truetype"),url(../fonts/nunito-v8-latin-200.svg#svgFontName) format("svg");font-style:normal;font-weight:200}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-200italic.eot);src:url(../fonts/nunito-v8-latin-200italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-200italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-200italic.woff) format("woff"),url(../fonts/nunito-v8-latin-200italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-200italic.svg#svgFontName) format("svg");font-style:italic;font-weight:200}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-300.eot);src:url(../fonts/nunito-v8-latin-300.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-300.woff2) format("woff2"),url(../fonts/nunito-v8-latin-300.woff) format("woff"),url(../fonts/nunito-v8-latin-300.ttf) format("truetype"),url(../fonts/nunito-v8-latin-300.svg#svgFontName) format("svg");font-style:normal;font-weight:300}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-300italic.eot);src:url(../fonts/nunito-v8-latin-300italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-300italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-300italic.woff) format("woff"),url(../fonts/nunito-v8-latin-300italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-300italic.svg#svgFontName) format("svg");font-style:italic;font-weight:300}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-regular.eot);src:url(../fonts/nunito-v8-latin-regular.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-regular.woff2) format("woff2"),url(../fonts/nunito-v8-latin-regular.woff) format("woff"),url(../fonts/nunito-v8-latin-regular.ttf) format("truetype"),url(../fonts/nunito-v8-latin-regular.svg#svgFontName) format("svg");font-style:normal;font-weight:400}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-italic.eot);src:url(../fonts/nunito-v8-latin-italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-italic.woff) format("woff"),url(../fonts/nunito-v8-latin-italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-italic.svg#svgFontName) format("svg");font-style:italic;font-weight:400}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-600.eot);src:url(../fonts/nunito-v8-latin-600.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-600.woff2) format("woff2"),url(../fonts/nunito-v8-latin-600.woff) format("woff"),url(../fonts/nunito-v8-latin-600.ttf) format("truetype"),url(../fonts/nunito-v8-latin-600.svg#svgFontName) format("svg");font-style:normal;font-weight:600}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-600italic.eot);src:url(../fonts/nunito-v8-latin-600italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-600italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-600italic.woff) format("woff"),url(../fonts/nunito-v8-latin-600italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-600italic.svg#svgFontName) format("svg");font-style:italic;font-weight:600}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-700.eot);src:url(../fonts/nunito-v8-latin-700.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-700.woff2) format("woff2"),url(../fonts/nunito-v8-latin-700.woff) format("woff"),url(../fonts/nunito-v8-latin-700.ttf) format("truetype"),url(../fonts/nunito-v8-latin-700.svg#svgFontName) format("svg");font-style:normal;font-weight:700}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-700italic.eot);src:url(../fonts/nunito-v8-latin-700italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-700italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-700italic.woff) format("woff"),url(../fonts/nunito-v8-latin-700italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-700italic.svg#svgFontName) format("svg");font-style:italic;font-weight:700}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-800.eot);src:url(../fonts/nunito-v8-latin-800.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-800.woff2) format("woff2"),url(../fonts/nunito-v8-latin-800.woff) format("woff"),url(../fonts/nunito-v8-latin-800.ttf) format("truetype"),url(../fonts/nunito-v8-latin-800.svg#svgFontName) format("svg");font-style:normal;font-weight:800}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-800italic.eot);src:url(../fonts/nunito-v8-latin-800italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-800italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-800italic.woff) format("woff"),url(../fonts/nunito-v8-latin-800italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-800italic.svg#svgFontName) format("svg");font-style:italic;font-weight:800}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-900.eot);src:url(../fonts/nunito-v8-latin-900.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-900.woff2) format("woff2"),url(../fonts/nunito-v8-latin-900.woff) format("woff"),url(../fonts/nunito-v8-latin-900.ttf) format("truetype"),url(../fonts/nunito-v8-latin-900.svg#svgFontName) format("svg");font-style:normal;font-weight:900}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-900italic.eot);src:url(../fonts/nunito-v8-latin-900italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-900italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-900italic.woff) format("woff"),url(../fonts/nunito-v8-latin-900italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-900italic.svg#svgFontName) format("svg");font-style:italic;font-weight:900}.moove-gdpr-donation-box-wrapper{width:auto;margin:10px 20px 0 2px}.moove-gdpr-donation-box-wrapper .moove-gdpr-donate-form{float:left;margin-right:20px}.moove-gdpr-donation-box-wrapper .moove-donation-box{padding-bottom:20px}.gdpr-admin-popup{position:fixed;top:0;left:0;width:100%;height:100%;z-index:999}.gdpr-admin-popup,.gdpr-admin-popup .gdpr-popup-close{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}.gdpr-admin-popup .gdpr-popup-close{position:absolute;top:-15px;right:-15px;width:30px;height:30px;text-decoration:none;border-radius:50%;background-color:#f79322;color:#fff;transition:all .4 ease}.gdpr-admin-popup .gdpr-popup-close:hover{background-color:#232323}.gdpr-admin-popup .gdpr-popup-overlay{background-color:rgba(0,0,0,.8);position:absolute;top:0;left:0;bottom:0;right:0;z-index:15}.gdpr-admin-popup .gdpr-popup-content{width:420px;max-width:70vw;background-color:#fff;padding:30px;border-radius:8px;text-align:center;position:relative;z-index:35}.gdpr-admin-popup .gdpr-popup-content p{font-size:14px;line-height:20px;margin-top:0}.gdpr-admin-popup .gdpr-popup-content h4{font-size:18px;line-height:28px;margin-top:0}#moove-gdpr-setting-error-settings_updated .wrap{width:100%;margin:0}#moove-gdpr-setting-error-settings_updated .wrap p{padding-left:0;margin-left:0}.gdpr-video-tutorial-content{position:relative;padding-bottom:56.25%;padding-top:25px;height:0}.gdpr_admin_link{text-decoration:none;color:#f79322;transition:all .4s ease}.gdpr_admin_link:hover{text-decoration:underline;color:#f79322}.gdpr_license_info{font-style:italic}#moove_gdpr_license_settings .wrap,#moove_gdpr_license_settings pre{width:100%;white-space:normal;word-break:break-all;margin:0}#moove_gdpr_license_settings .wrap span,#moove_gdpr_license_settings pre span{font-size:13px}#moove_gdpr_license_settings .wrap p,#moove_gdpr_license_settings pre p{margin-bottom:0}#moove_gdpr_license_settings .gdpr_license_log{padding:0}.gdpr-video-tutorial-content iframe{width:100%;height:auto;position:absolute;top:0;left:0;height:100%}.gdpr-faq-accordion-content textarea{width:100%;height:auto;height:200px}.gdpr-cookie-alert{background-color:#f79322;border:1px solid #f79322;color:#fff;box-shadow:0 3px 51px 0 rgba(0,0,0,.05);padding:10px;display:inline-block;width:auto;box-sizing:border-box;margin:10px 0 20px;border-radius:3px;padding-right:50px;position:relative}.gdpr-cookie-alert.gdpr-cookie-update-alert{display:block;width:100%;background-color:#fff;border:1px solid #ccc;box-shadow:0 3px 51px 0 rgba(0,0,0,.05);color:#23282d}.gdpr-cookie-alert.gdpr-cookie-update-alert a{color:#f79322}.gdpr-cookie-alert.gdpr-cookie-update-alert span.gdpr-dismiss,.gdpr-cookie-alert.gdpr-cookie-update-alert span.gdpr-dismiss-update{color:#23282d}.gdpr-cookie-alert.gdpr-cookie-update-alert span.gdpr-dismiss-update:hover,.gdpr-cookie-alert.gdpr-cookie-update-alert span.gdpr-dismiss:hover{color:#f79322}.gdpr-cookie-alert span.gdpr-dismiss,.gdpr-cookie-alert span.gdpr-dismiss-update{position:absolute;top:4px;right:8px;font-size:25px;font-weight:400;line-height:1;color:#fff;cursor:pointer;transition:all .4s ease}.gdpr-cookie-alert span.gdpr-dismiss-update:hover,.gdpr-cookie-alert span.gdpr-dismiss:hover{color:#23282d}.gdpr-cookie-alert h4{margin:0 0 10px;font-size:16px}.gdpr-cookie-alert p{margin:0;font-size:13px;font-weight:500}.gdpr-cookie-alert p strong{padding:2px 3px;display:inline-block;background-color:#fff;color:#23282d;margin:0 5px}.gdpr-disabled{pointer-events:none;cursor:default;opacity:.5}.gdpr-script-tabs-main-cnt{position:relative;overflow:hidden}body.toplevel_page_moove-gdpr{background-color:#fff}#moove_form_checker_wrap .moove-gdpr-form-container{min-height:750px}.gdpr_license_log_alert{padding:0}.gdpr_license_log_alert .wrap>.update-messages,.gdpr_license_log_alert .wrap>h1,.gdpr_license_log_alert .wrap>p{display:none}.gdpr_license_log_alert .gdpr-admin-alert{position:relative;padding-right:40px;margin:20px 0}.gdpr_license_log_alert .gdpr-admin-alert .gdpr-alert-content{padding-right:30px}.gdpr_license_log_alert .gdpr-admin-alert .dashicons{position:absolute;top:5px;right:5px;width:30px;height:30px;border-radius:50%;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;color:rgba(5,150,24,.5);font-size:34px!important;background-color:#fff}.gdpr_license_log_alert .gdpr-admin-alert a{color:inherit;text-decoration:underline;margin-right:5px;font-weight:700}.gdpr_license_log_alert .gdpr-admin-alert a:hover{color:#262c33;text-decoration:underline}.gdpr_license_log_alert .gdpr-admin-alert.gdpr-admin-alert-success{background-color:rgba(5,150,24,.1);color:#059618;padding:5px 10px;border-radius:15px;border:2px solid rgba(5,150,24,.5)}.gdpr_license_log_alert .gdpr-admin-alert.gdpr-admin-alert-error{background-color:rgba(225,0,0,.1);color:#e10000;padding:5px 10px;border-radius:15px;border:2px solid rgba(225,0,0,.5)}.gdpr_license_log_alert .gdpr-admin-alert.gdpr-admin-alert-error .dashicons{color:rgba(225,0,0,.5)}.gdpr_license_log_alert .gdpr-admin-alert p{margin:5px 0}.gdpr-plugin-star-rating{display:inline-block;color:#ffb900;position:relative;top:3px}.gdpr-plugin-star-rating svg,.gdpr-plugin-star-rating svg:hover{fill:#ffb900}.gdpr-plugin-star-rating svg:hover~svg{fill:none}@font-face{font-family:gdpr-admin-icon;src:url(../fonts/gdpr-admin-icon.eot);src:url(../fonts/gdpr-admin-icon.eot#iefix) format("embedded-opentype"),url(../fonts/gdpr-admin-icon.woff2) format("woff2"),url(../fonts/gdpr-admin-icon.woff) format("woff"),url(../fonts/gdpr-admin-icon.ttf) format("truetype"),url(../fonts/gdpr-admin-icon.svg#gdpr-admin-icon) format("svg");font-weight:400;font-style:normal}#toplevel_page_moove-gdpr .dashicons-before{font-family:gdpr-admin-icon;font-style:normal;font-weight:400;speak:none;display:inline-block;text-decoration:inherit;width:1em;margin-right:.2em;text-align:center;font-variant:normal;text-transform:none;line-height:1em;margin-left:.2em;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}#toplevel_page_moove-gdpr .dashicons-before:before{content:"\e806";font-family:inherit;position:relative;top:2px}.gdpr-help-content-cnt .gdpr-help-content-block{margin-top:20px}.gdpr-help-content-cnt .gdpr-faq-toggle{box-shadow:0 3px 51px 0 rgba(0,0,0,.05);border:1px solid #ccc;margin-bottom:20px}.gdpr-help-content-cnt .gdpr-faq-toggle.gdpr-faq-open .gdpr-faq-accordion-header h3{background-color:#f79322;color:#fff}.gdpr-help-content-cnt .gdpr-faq-toggle.gdpr-faq-open .gdpr-faq-accordion-header h3:after{content:"-"}.gdpr-help-content-cnt .gdpr-faq-toggle .gdpr-faq-accordion-header h3{margin:0;position:relative;padding:15px 20px;padding-right:60px;cursor:pointer;transition:all .3s ease;font-size:16px!important}.gdpr-help-content-cnt .gdpr-faq-toggle .gdpr-faq-accordion-header h3:hover{background-color:#f79322;color:#fff}.gdpr-help-content-cnt .gdpr-faq-toggle .gdpr-faq-accordion-header h3:after{content:"+";width:50px;position:absolute;top:0;right:0;border-left:1px solid #ccc;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;font-size:26px;text-align:center;bottom:0;-ms-flex-pack:center;justify-content:center}.gdpr-help-content-cnt .gdpr-faq-toggle .gdpr-faq-accordion-content{padding:15px 60px 15px 20px;border-top:1px solid #ccc}.gdpr-help-content-cnt .gdpr-faq-toggle .gdpr-faq-accordion-content code{line-height:1.8;overflow:auto;display:block}.gdpr-disable-posts-nav{list-style-type:none;padding:5px 10px;margin:20px 0;background-color:#fff;box-shadow:0 3px 51px 0 rgba(0,0,0,.05);border:1px solid #ccc}.gdpr-disable-posts-nav li:first-child a{padding-left:0}.gdpr-disable-posts-nav li:last-child a{padding-right:0}.gdpr-disable-posts-nav li:after{content:"|";display:inline-block;position:absolute;right:-2px;top:10px}.gdpr-disable-posts-nav li:first-child:after,.gdpr-disable-posts-nav li:last-child:after{display:none}.gdpr-disable-posts-nav li{list-style:none;display:inline-block;float:left;position:relative;margin:0}.gdpr-disable-posts-nav li a.active{color:#f79322}.gdpr-disable-posts-nav li a,.gdpr-disable-posts-nav li strong{display:block;padding:10px;outline:none;box-shadow:none}.gdpr-disable-posts-nav li strong{padding-left:0}body.toplevel_page_moove-gdpr #wpcontent{background-color:#fff}.gdpr-script-tab-content{position:relative;overflow:hidden}.gdpr-script-tab-content .gdpr-tab-code-section{transition:all .8s ease;top:0;right:0;left:0}.gdpr-script-tab-content .gdpr-tab-code-section:not(.gdpr-active){height:0;opacity:0;margin:0;position:absolute;top:100%;visibility:hidden}.gdpr-tab-code-section-nav ul{list-style-type:none;padding:0;margin:20px 1px 0;display:-ms-flexbox;display:flex}.gdpr-tab-code-section-nav ul li{list-style:none;padding:0;margin:0 -1px;position:relative;border:1px solid #f79322;border-bottom:0;overflow:hidden}.gdpr-tab-code-section-nav ul li:first-child{border-top-left-radius:10px}.gdpr-tab-code-section-nav ul li:last-child{border-top-right-radius:10px}.gdpr-tab-code-section-nav ul li a{background-color:#fff;display:block;padding:8px 20px;text-decoration:none;font-weight:700;font-size:14px;color:#555;transition:all .3s ease;outline:none;box-shadow:none}.gdpr-tab-code-section-nav ul li a:before{content:"\21B3";transform:rotate(90deg);display:inline-block;position:absolute;top:0;left:0;width:0;color:#fff;opacity:0;transition:all .3s ease}.gdpr-tab-code-section-nav ul li a.gdpr-active:before{opacity:1;top:4px;left:10px}.gdpr-tab-code-section-nav ul li a.gdpr-active,.gdpr-tab-code-section-nav ul li a:hover{background-color:#f79322;color:#fff}.gdpr-tab-code-section{background-color:#fff;padding:20px;border:1px solid #f79322;border-bottom-left-radius:10px;border-bottom-right-radius:10px;border-top-right-radius:10px;position:relative;overflow-wrap:hidden}.gdpr-tab-code-section .CodeMirror{font-size:15px;width:100%;height:300px;box-sizing:border-box;background-color:#fff;border:1px solid #ccc}.gdpr-tab-code-section .CodeMirror-gutters{padding-bottom:0;background-color:#f1f1f1}.gdpr-tab-code-section p.description{font-weight:600;font-size:13px}.gdpr-tab-code-section h4{margin:-20px -20px 0;padding:15px 20px;border-bottom:1px solid #ccc}.gdpr-tab-code-section table{width:100%}.gdpr-tab-code-section .gdpr-code{padding:10px;background-color:#f1f1f1}.gdpr-img-responsive{max-width:100%;height:auto}.gdpr-tab-section-cnt{max-width:calc(100% - 380px);display:inline-block;width:100%}.gdpr-tab-section-cnt .regular-text{width:100%}.gdpr-tab-section-cnt .powered-by-label{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;margin-bottom:15px}.gdpr-tab-section-cnt .powered-by-label label{white-space:nowrap;margin-right:20px}.gdpr-conditional-field:not(.gdpr-conditional-on){display:none}.gdpr-checkbox-toggle{position:relative;display:inline-block;width:160px;height:24px;box-sizing:border-box}.gdpr-checkbox-toggle *{box-sizing:border-box}.gdpr-checkbox-toggle.gdpr-checkbox-inverted input:checked+.gdpr-checkbox-slider{background-color:red}.gdpr-checkbox-toggle.gdpr-checkbox-inverted input:checked+.gdpr-checkbox-slider:after{content:attr(data-disable)}.gdpr-checkbox-toggle.gdpr-checkbox-inverted .gdpr-checkbox-slider{background-color:#2e9935}.gdpr-checkbox-toggle.gdpr-checkbox-inverted .gdpr-checkbox-slider:after{content:attr(data-enable)}.gdpr-checkbox-toggle.gdpr-color-scheme-toggle input:checked+.gdpr-checkbox-slider{background-color:#202020}.gdpr-checkbox-toggle.gdpr-color-scheme-toggle input:checked+.gdpr-checkbox-slider:after{color:#fff}.gdpr-checkbox-toggle.gdpr-color-scheme-toggle .gdpr-checkbox-slider,.gdpr-checkbox-toggle.gdpr-color-scheme-toggle input:checked+.gdpr-checkbox-slider:before{background-color:#fff}.gdpr-checkbox-toggle.gdpr-color-scheme-toggle .gdpr-checkbox-slider:after{color:#202020}.gdpr-checkbox-toggle.gdpr-color-scheme-toggle .gdpr-checkbox-slider:before{background-color:#202020}.gdpr-checkbox-toggle input{opacity:0;width:0;height:0}.gdpr-checkbox-toggle input:checked+.gdpr-checkbox-slider{background-color:#2e9935}.gdpr-checkbox-toggle input:checked+.gdpr-checkbox-slider:after{content:attr(data-enable)}.gdpr-checkbox-toggle input:checked+.gdpr-checkbox-slider:before{transform:translateX(136px)}.gdpr-checkbox-toggle .gdpr-checkbox-slider{position:absolute;cursor:pointer;top:0;left:0;right:0;bottom:0;background-color:red;transition:.4s;border-radius:34px;border:1px solid #ddd}.gdpr-checkbox-toggle .gdpr-checkbox-slider:before{position:absolute;content:"";height:20px;width:20px;left:1px;bottom:1px;background-color:#fff;transition:.4s;border-radius:50%}.gdpr-checkbox-toggle .gdpr-checkbox-slider:after{content:attr(data-disable);position:absolute;top:5px;left:0;right:0;color:#fff;font-size:12px;display:block;z-index:4;text-transform:uppercase;text-align:center;font-weight:600;font-family:Helvetica;letter-spacing:.5px}.moove-plugins-info-boxes{display:inline-block;float:right;width:350px;background-color:#fff}.moove-plugins-info-boxes .m-plugin-box{border:1px solid #ccc;margin-bottom:30px;background-color:#fff;border-radius:5px;box-shadow:0 3px 51px 0 rgba(0,0,0,.05)}.moove-plugins-info-boxes .m-plugin-box.m-plugin-box-highlighted{border:2px solid #f79322}.moove-plugins-info-boxes .m-plugin-box.m-plugin-box-highlighted .box-header{background-color:#f79322;border-color:#f79322;color:#fff}.moove-plugins-info-boxes .m-plugin-box.m-plugin-box-support:not(.m-plugin-box-highlighted) .gdpr-review-bnt{background-color:rgba(85,85,85,.5);color:#fff}.moove-plugins-info-boxes .m-plugin-box.m-plugin-box-support:not(.m-plugin-box-highlighted) .gdpr-review-bnt:hover{background-color:#232323;color:#fff}.moove-plugins-info-boxes .m-plugin-box .box-content .gdpr-faq-forum-content p{position:relative;padding-left:15px;line-height:1.3;margin-bottom:10px}.moove-plugins-info-boxes .m-plugin-box .box-content .gdpr-faq-forum-content p .gdpr-chevron-left{color:#f79322;font-size:18px;position:absolute;left:0;top:7px;line-height:0}.moove-plugins-info-boxes .m-plugin-box a:not(.gdpr-review-bnt):not(.plugin-buy-now-btn){color:#f79322;transition:all .3s ease}.moove-plugins-info-boxes .m-plugin-box a:not(.gdpr-review-bnt):not(.plugin-buy-now-btn):hover{color:#23282d}.moove-plugins-info-boxes .m-plugin-box .gdpr-review-bnt{text-decoration:none;outline:none;padding:7px 20px;font-size:12px;font-weight:500;background-color:#f79322;color:#fff;transition:all .3s ease;line-height:18px;border:none;display:inline-block;margin:10px 0}.moove-plugins-info-boxes .m-plugin-box .gdpr-review-bnt:hover{background-color:#262c33}.moove-plugins-info-boxes .m-plugin-box .box-header{padding:10px;border-bottom:1px solid #ccc}.moove-plugins-info-boxes .m-plugin-box .box-header h4{font-size:14px;font-weight:600;margin:0;font-family:Nunito}.moove-plugins-info-boxes .m-plugin-box .box-content{padding:10px}.moove-plugins-info-boxes .m-plugin-box .box-content p{margin-top:5px;margin-bottom:5px}.moove-plugins-info-boxes .m-plugin-box .box-content hr{margin:10px 0}.moove-plugins-info-boxes .m-plugin-box .plugin-rating{display:-ms-flexbox;display:flex;margin:10px 0 20px;-ms-flex-align:center;align-items:center;transform:scale(1.3);width:100%;padding-left:13%}.moove-plugins-info-boxes .m-plugin-box .plugin-rating .plugin-stars{display:inline-block;width:50%}.moove-plugins-info-boxes .m-plugin-box .gdpr-review-container{display:block;text-align:left;margin:0}.moove-plugins-info-boxes .m-plugin-box .plugin-stats{display:-ms-flexbox;display:flex}.moove-plugins-info-boxes .m-plugin-box .plugin-stats *{box-sizing:border-box}.moove-plugins-info-boxes .m-plugin-box .plugin-stats .plugin-download-ainstalls-cnt{display:inline-block;width:calc(100% - 130px);line-height:20px}.moove-plugins-info-boxes .m-plugin-box .plugin-stats .plugin-rating{width:125px;box-sizing:border-box;text-align:right;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:end;justify-content:flex-end;padding:0;margin:0}.moove-plugins-info-boxes .m-plugin-box .plugin-stats .plugin-rating .plugin-stars{width:100px;transform:scale(.8)}.moove-plugins-info-boxes .m-plugin-box .plugin-features{padding-left:20px;margin-top:5px}.moove-plugins-info-boxes .m-plugin-box .plugin-features li{list-style-type:square}.moove-plugins-info-boxes .m-plugin-box .plugin-buy-now-btn{display:block;text-decoration:none;outline:none;box-shadow:none;padding:7px 20px;background-color:#f79322;color:#fff;text-align:center;transition:all .3s ease;margin:15px 0;font-weight:600;font-size:12px}.moove-plugins-info-boxes .m-plugin-box .plugin-buy-now-btn:hover{background-color:#232323}.gdpr-tab-section-cnt{position:relative;overflow:hidden}.gdpr-tab-section-cnt .form-table th{width:250px;max-width:250px}@media (max-width:1280px){.gdpr-tab-section-cnt{max-width:100%;display:block;width:100%}.gdpr-tab-section-cnt .form-table th{width:200px}.moove-plugins-info-boxes{display:inline-block;float:none;width:100%;padding:0;margin:15px 0;background-color:#f1f1f1}}.gdpr-locked-section{padding:0 40px;background-color:#fff;border:1px solid #ccc;display:-ms-flexbox;display:flex;-ms-flex-item-align:center;align-self:center;margin-top:90px;border-radius:5px}.gdpr-locked-section span{display:block;width:100%;transform:translateY(-50px);text-align:center}.gdpr-locked-section h4{font-size:28px;line-height:32px;margin:60px 0 30px;text-align:center}.gdpr-locked-section *{box-sizing:border-box}.gdpr-locked-section i{font-size:30px;line-height:55px;color:#f79322;width:60px;height:50px;background-color:#fff;border:1px solid #ccc;border-bottom:1px solid #fff;border-top-left-radius:100px;border-top-right-radius:100px}.gdpr-locked-section .plugin-buy-now-btn{display:block;text-decoration:none;outline:none;box-shadow:none;padding:7px 20px;background-color:#f79322;color:#fff;text-align:center;transition:all .3s ease;margin:15px auto 0;font-weight:600;font-size:12px;max-width:200px}.gdpr-locked-section .plugin-buy-now-btn:hover{background-color:#232323}#moove_form_checker_wrap .nav-tab-wrapper a.nav-tab.gdpr-cc-addon.gdpr-cc-disabled{background-color:#fff;color:#f79322;line-height:20px}.moove-donation-box{position:relative;width:calc(100% - 20px);margin:16px 0;padding:0 15px 10px;box-shadow:0 1px 1px rgba(0,0,0,.04);background:#fff;font-size:13px}.moove-donation-box .notice-dismiss:before{float:left;margin:0 4px -2px 0}.moove-redirect-box{width:100%}.moove-not-visible{opacity:0;visibility:hidden;position:absolute}.moove-gdpr-form-container{min-height:45vh}.moove-gdpr-form-container input[type=radio].on-off{margin:0}.moove-gdpr-form-container input.iris-colorpicker{text-shadow:1px 0 0 #fff,-1px 0 0 #fff,0 1px 0 #fff,0 -1px 0 #fff,1px 1px #fff,-1px -1px 0 #fff,1px -1px 0 #fff,-1px 1px 0 #fff;text-transform:uppercase;outline:none!important;box-shadow:none!important;font-weight:700;font-size:14px;border:none;width:120px;height:30px;margin:0;border-top-left-radius:5px;border-bottom-left-radius:5px}.moove-gdpr-form-container .iris-selectbtn{position:relative;background-color:#fff;display:inline-block;padding:0 5px;text-transform:uppercase;font-size:11px;line-height:30px;font-weight:700;float:right;border-top-right-radius:5px;border-bottom-right-radius:5px;cursor:pointer}.moove-gdpr-form-container .iris-colorpicker-group-cnt{display:inline-block;border:1px solid #ddd;border-radius:5px}.moove-gdpr-form-container .iris-picker{position:absolute}.moove-gdpr-form-container .iris-picker:before{content:"";position:fixed;width:100%;height:100%;top:0;left:0}.moove-gdpr-form-container .iris-picker .iris-picker-inner{z-index:100}.moove-clearfix:after{content:"";clear:both;display:table}.moove_gdpr_company_logo_holder{display:inline-block;padding-bottom:50px;width:130px;height:0;background-position:0;background-repeat:no-repeat;background-size:contain}#wp-moove_gdpr_advanced_cookies_tab_content-wrap,#wp-moove_gdpr_cookies_policy_tab_content-wrap,#wp-moove_gdpr_ifb_content-wrap,#wp-moove_gdpr_info_bar_content-wrap,#wp-moove_gdpr_modal_strictly_secondary_notice-wrap,#wp-moove_gdpr_performance_cookies_tab_content-wrap,#wp-moove_gdpr_privacy_overview_tab_content-wrap,#wp-moove_gdpr_strict_necessary_cookies_tab_content-wrap,#wp-moove_gdpr_strictly_necessary_cookies_warning-wrap{max-width:100%}span.separator{display:inline-block;margin-left:10px}.gdpr-cookie-compliance-header-section{padding-left:100px;position:relative;margin:30px 0}.gdpr-cookie-compliance-header-section a{color:#f79322}.gdpr-cookie-compliance-header-section:before{content:"";position:absolute;left:0;top:0;width:100px;height:100px;background-image:url(../images/gdpr-cookie-compliance-icon.png);background-position:0;background-repeat:no-repeat;background-size:contain}.gdpr-cookie-compliance-header-section h2{font-family:Nunito,sans-serif;font-size:30px;font-weight:800;padding-top:25px;margin-bottom:10px}.gdpr-cookie-compliance-header-section h2 .gdpr-plugin-version{font-size:16px;font-weight:400;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;color:#565656;margin-left:5px}.gdpr-cookie-compliance-header-section h4{margin-top:10px}#moove_form_checker_wrap{position:relative}#moove_form_checker_wrap .button-primary{background-color:#f89e26;border:none;border-radius:0;text-shadow:none;box-shadow:none;outline:none;padding:8px 15px;font-size:12px;font-weight:500;color:#fff;transition:all .3s ease;height:auto;line-height:18px;border:1px solid #d28b21}#moove_form_checker_wrap .button-primary.button-inverse,#moove_form_checker_wrap .button-primary:hover{background-color:#262c33;border:1px solid #737373}#moove_form_checker_wrap .button-primary.button-inverse:hover{background-color:#f89e26;border:1px solid #d28b21}#moove_form_checker_wrap h1{margin:0;padding:0}#moove_form_checker_wrap h2,#moove_form_checker_wrap h3{font-family:Nunito,sans-serif;font-weight:800;font-size:20px}#moove_form_checker_wrap .gdpr-tab-section-cnt:after{content:"";clear:both;display:table}#moove_form_checker_wrap .nav-tab-wrapper{width:200px;display:inline-block;padding-right:17px;padding-top:0;position:relative}#moove_form_checker_wrap .nav-tab-wrapper a.nav-tab{font-size:12px;padding:10px 8px;width:100%;margin-left:0;outline:none;box-shadow:none;border-right:0;position:relative;white-space:normal;line-height:1.3}#moove_form_checker_wrap .nav-tab-wrapper .nav-tab-active,#moove_form_checker_wrap .nav-tab-wrapper .nav-tab-active:focus,#moove_form_checker_wrap .nav-tab-wrapper .nav-tab-active:focus:active,#moove_form_checker_wrap .nav-tab-wrapper .nav-tab-active:hover{border-bottom:1px solid #ccc;color:#f79322;outline:none;box-shadow:none;background-color:#fff}#moove_form_checker_wrap .nav-tab-wrapper .nav-tab-active:after{content:"";position:absolute;right:-1px;top:0;width:2px;bottom:0;background-color:#fff}#moove_form_checker_wrap .moove-gdpr-form-container{width:calc(100% - 279px);float:right;padding:5px 30px 30px;border:1px solid #ccc}#moove_gdpr_info_bar_content-html,#moove_gdpr_info_bar_content-tmce{display:none}#moove_form_checker_wrap .moove-gdpr-settings-branding{margin:25px 0;font-style:italic}#moove_form_checker_wrap .moove-gdpr-settings-branding hr{margin:0}#moove_form_checker_wrap .moove-gdpr-settings-branding p{margin:15px 0}#moove_form_checker_wrap .moove-gdpr-settings-branding p span{display:inline-block;background-image:url(../images/moove_logo_br.png);width:66px;height:15px;background-size:contain;background-repeat:no-repeat;background-position:0 100%}#moove_form_checker_wrap .moove-gdpr-settings-branding p a{text-decoration:none;color:inherit}#moove_form_checker_wrap .moove-gdpr-settings-branding p a:hover{text-decoration:underline}.moove-gdpr-form-error .alert.script-error{color:#fff;padding:10px;background-color:red;text-transform:uppercase}#moove_form_checker_wrap .CodeMirror{font-family:monospace;height:300px;color:#000;direction:ltr}#moove_form_checker_wrap .gdpr-faq-accordion-content .CodeMirror{max-height:300px;height:auto}#moove_form_checker_wrap .CodeMirror-lines{padding:4px 0}#moove_form_checker_wrap .CodeMirror pre{padding:0 4px}#moove_form_checker_wrap .CodeMirror-gutter-filler,#moove_form_checker_wrap .CodeMirror-scrollbar-filler{background-color:#fff}#moove_form_checker_wrap .CodeMirror-gutters{border-right:1px solid #ddd;background-color:#f7f7f7;white-space:nowrap}#moove_form_checker_wrap .CodeMirror-linenumber{padding:0 3px 0 5px;min-width:20px;text-align:right;color:#999;white-space:nowrap}#moove_form_checker_wrap .CodeMirror-guttermarker{color:#000}#moove_form_checker_wrap .CodeMirror-guttermarker-subtle{color:#999}#moove_form_checker_wrap .CodeMirror-cursor{border-left:1px solid #000;border-right:none;width:0}#moove_form_checker_wrap .CodeMirror div.CodeMirror-secondarycursor{border-left:1px solid silver}#moove_form_checker_wrap .cm-fat-cursor .CodeMirror-cursor{width:auto;border:0!important;background:#7e7}#moove_form_checker_wrap .cm-fat-cursor div.CodeMirror-cursors{z-index:1}#moove_form_checker_wrap .cm-fat-cursor-mark{background-color:rgba(20,255,20,.5);animation:blink 1.06s steps(1) infinite}#moove_form_checker_wrap .cm-animate-fat-cursor{width:auto;border:0;animation:blink 1.06s steps(1) infinite;background-color:#7e7}@keyframes blink{50%{background-color:transparent}}#moove_form_checker_wrap .cm-tab{display:inline-block;text-decoration:inherit}#moove_form_checker_wrap .CodeMirror-rulers{position:absolute;left:0;right:0;top:-50px;bottom:-20px;overflow:hidden}#moove_form_checker_wrap .CodeMirror-ruler{border-left:1px solid #ccc;top:0;bottom:0;position:absolute}#moove_form_checker_wrap .cm-s-default .cm-header{color:blue}#moove_form_checker_wrap .cm-s-default .cm-quote{color:#090}#moove_form_checker_wrap .cm-negative{color:#d44}#moove_form_checker_wrap .cm-positive{color:#292}#moove_form_checker_wrap .cm-header,.cm-strong{font-weight:700}#moove_form_checker_wrap .cm-em{font-style:italic}#moove_form_checker_wrap .cm-link{text-decoration:underline}#moove_form_checker_wrap .cm-strikethrough{text-decoration:line-through}#moove_form_checker_wrap .cm-s-default .cm-keyword{color:#708}#moove_form_checker_wrap .cm-s-default .cm-atom{color:#219}#moove_form_checker_wrap .cm-s-default .cm-number{color:#164}#moove_form_checker_wrap .cm-s-default .cm-def{color:#00f}#moove_form_checker_wrap .cm-s-default .cm-variable-2{color:#05a}#moove_form_checker_wrap .cm-s-default .cm-variable-3,.cm-s-default .cm-type{color:#085}#moove_form_checker_wrap .cm-s-default .cm-comment{color:#a50}#moove_form_checker_wrap .cm-s-default .cm-string{color:#a11}#moove_form_checker_wrap .cm-s-default .cm-string-2{color:#f50}#moove_form_checker_wrap .cm-s-default .cm-meta,#moove_form_checker_wrap .cm-s-default .cm-qualifier{color:#555}#moove_form_checker_wrap .cm-s-default .cm-builtin{color:#30a}#moove_form_checker_wrap .cm-s-default .cm-bracket{color:#997}#moove_form_checker_wrap .cm-s-default .cm-tag{color:#170}#moove_form_checker_wrap .cm-s-default .cm-attribute{color:#00c}#moove_form_checker_wrap .cm-s-default .cm-hr{color:#999}#moove_form_checker_wrap .cm-s-default .cm-link{color:#00c}#moove_form_checker_wrap .cm-invalidchar,#moove_form_checker_wrap .cm-s-default .cm-error{color:red}#moove_form_checker_wrap .CodeMirror-composing{border-bottom:2px solid}#moove_form_checker_wrap div.CodeMirror span.CodeMirror-matchingbracket{color:#0b0}#moove_form_checker_wrap div.CodeMirror span.CodeMirror-nonmatchingbracket{color:#a22}#moove_form_checker_wrap .CodeMirror-matchingtag{background:rgba(255,150,0,.3)}#moove_form_checker_wrap .CodeMirror-activeline-background{background:#e8f2ff}#moove_form_checker_wrap .CodeMirror{position:relative;overflow:hidden;background:#fff}#moove_form_checker_wrap .CodeMirror-scroll{overflow:scroll!important;margin-bottom:-30px;margin-right:-30px;padding-bottom:30px;height:100%;outline:none;position:relative}#moove_form_checker_wrap .CodeMirror-sizer{position:relative;border-right:30px solid transparent}#moove_form_checker_wrap .CodeMirror-gutter-filler,#moove_form_checker_wrap .CodeMirror-hscrollbar,#moove_form_checker_wrap .CodeMirror-scrollbar-filler,#moove_form_checker_wrap .CodeMirror-vscrollbar{position:absolute;z-index:6;display:none}#moove_form_checker_wrap .CodeMirror-vscrollbar{right:0;top:0;overflow-x:hidden;overflow-y:scroll}#moove_form_checker_wrap .CodeMirror-hscrollbar{bottom:0;left:0;overflow-y:hidden;overflow-x:scroll}#moove_form_checker_wrap .CodeMirror-scrollbar-filler{right:0;bottom:0}#moove_form_checker_wrap .CodeMirror-gutter-filler{left:0;bottom:0}#moove_form_checker_wrap .CodeMirror-gutters{position:absolute;left:0;top:0;min-height:100%;z-index:3}#moove_form_checker_wrap .CodeMirror-gutter{white-space:normal;height:100%;display:inline-block;vertical-align:top;margin-bottom:-30px}#moove_form_checker_wrap .CodeMirror-gutter-wrapper{position:absolute;z-index:4;background:none!important;border:none!important}#moove_form_checker_wrap .CodeMirror-gutter-background{position:absolute;top:0;bottom:0;z-index:4}#moove_form_checker_wrap .CodeMirror-gutter-elt{position:absolute;cursor:default;z-index:4}#moove_form_checker_wrap .CodeMirror-gutter-wrapper ::selection{background-color:transparent}#moove_form_checker_wrap .CodeMirror-gutter-wrapper ::-moz-selection{background-color:transparent}#moove_form_checker_wrap .CodeMirror-lines{cursor:text;min-height:1px}#moove_form_checker_wrap .CodeMirror pre{border-radius:0;border-width:0;background:transparent;font-family:inherit;font-size:inherit;margin:0;white-space:pre;word-wrap:normal;line-height:inherit;color:inherit;z-index:2;position:relative;overflow:visible;-webkit-tap-highlight-color:transparent;font-variant-ligatures:contextual}#moove_form_checker_wrap .CodeMirror-wrap pre{word-wrap:break-word;white-space:pre-wrap;word-break:normal}#moove_form_checker_wrap .CodeMirror-linebackground{position:absolute;left:0;right:0;top:0;bottom:0;z-index:0}#moove_form_checker_wrap .CodeMirror-linewidget{position:relative;z-index:2;padding:.1px}#moove_form_checker_wrap .CodeMirror-rtl pre{direction:rtl}#moove_form_checker_wrap .CodeMirror-code{outline:none}#moove_form_checker_wrap .CodeMirror-gutter,#moove_form_checker_wrap .CodeMirror-gutters,#moove_form_checker_wrap .CodeMirror-linenumber,#moove_form_checker_wrap .CodeMirror-scroll,#moove_form_checker_wrap .CodeMirror-sizer{box-sizing:content-box}#moove_form_checker_wrap .CodeMirror-measure{position:absolute;width:100%;height:0;overflow:hidden;visibility:hidden}#moove_form_checker_wrap .CodeMirror-cursor{position:absolute;pointer-events:none}#moove_form_checker_wrap .CodeMirror-measure pre{position:static}#moove_form_checker_wrap div.CodeMirror-cursors{visibility:hidden;position:relative;z-index:3}#moove_form_checker_wrap .CodeMirror-focused div.CodeMirror-cursors,#moove_form_checker_wrap div.CodeMirror-dragcursors{visibility:visible}#moove_form_checker_wrap .CodeMirror-selected{background:#d9d9d9}#moove_form_checker_wrap .CodeMirror-focused .CodeMirror-selected{background:#d7d4f0}#moove_form_checker_wrap .CodeMirror-crosshair{cursor:crosshair}#moove_form_checker_wrap .CodeMirror-line::selection,.CodeMirror-line>span::selection,.CodeMirror-line>span>span::selection{background:#d7d4f0}#moove_form_checker_wrap .CodeMirror-line::-moz-selection,.CodeMirror-line>span::-moz-selection,.CodeMirror-line>span>span::-moz-selection{background:#d7d4f0}#moove_form_checker_wrap .cm-searching{background-color:#ffa;background-color:rgba(255,255,0,.4)}#moove_form_checker_wrap .cm-force-border{padding-right:.1px}@media print{#moove_form_checker_wrap .CodeMirror div.CodeMirror-cursors{visibility:hidden}}#moove_form_checker_wrap .cm-tab-wrap-hack:after{content:""}#moove_form_checker_wrap span.CodeMirror-selectedtext{background:none}
|
1 |
+
@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-200.eot);src:url(../fonts/nunito-v8-latin-200.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-200.woff2) format("woff2"),url(../fonts/nunito-v8-latin-200.woff) format("woff"),url(../fonts/nunito-v8-latin-200.ttf) format("truetype"),url(../fonts/nunito-v8-latin-200.svg#svgFontName) format("svg");font-style:normal;font-weight:200}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-200italic.eot);src:url(../fonts/nunito-v8-latin-200italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-200italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-200italic.woff) format("woff"),url(../fonts/nunito-v8-latin-200italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-200italic.svg#svgFontName) format("svg");font-style:italic;font-weight:200}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-300.eot);src:url(../fonts/nunito-v8-latin-300.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-300.woff2) format("woff2"),url(../fonts/nunito-v8-latin-300.woff) format("woff"),url(../fonts/nunito-v8-latin-300.ttf) format("truetype"),url(../fonts/nunito-v8-latin-300.svg#svgFontName) format("svg");font-style:normal;font-weight:300}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-300italic.eot);src:url(../fonts/nunito-v8-latin-300italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-300italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-300italic.woff) format("woff"),url(../fonts/nunito-v8-latin-300italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-300italic.svg#svgFontName) format("svg");font-style:italic;font-weight:300}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-regular.eot);src:url(../fonts/nunito-v8-latin-regular.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-regular.woff2) format("woff2"),url(../fonts/nunito-v8-latin-regular.woff) format("woff"),url(../fonts/nunito-v8-latin-regular.ttf) format("truetype"),url(../fonts/nunito-v8-latin-regular.svg#svgFontName) format("svg");font-style:normal;font-weight:400}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-italic.eot);src:url(../fonts/nunito-v8-latin-italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-italic.woff) format("woff"),url(../fonts/nunito-v8-latin-italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-italic.svg#svgFontName) format("svg");font-style:italic;font-weight:400}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-600.eot);src:url(../fonts/nunito-v8-latin-600.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-600.woff2) format("woff2"),url(../fonts/nunito-v8-latin-600.woff) format("woff"),url(../fonts/nunito-v8-latin-600.ttf) format("truetype"),url(../fonts/nunito-v8-latin-600.svg#svgFontName) format("svg");font-style:normal;font-weight:600}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-600italic.eot);src:url(../fonts/nunito-v8-latin-600italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-600italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-600italic.woff) format("woff"),url(../fonts/nunito-v8-latin-600italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-600italic.svg#svgFontName) format("svg");font-style:italic;font-weight:600}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-700.eot);src:url(../fonts/nunito-v8-latin-700.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-700.woff2) format("woff2"),url(../fonts/nunito-v8-latin-700.woff) format("woff"),url(../fonts/nunito-v8-latin-700.ttf) format("truetype"),url(../fonts/nunito-v8-latin-700.svg#svgFontName) format("svg");font-style:normal;font-weight:700}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-700italic.eot);src:url(../fonts/nunito-v8-latin-700italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-700italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-700italic.woff) format("woff"),url(../fonts/nunito-v8-latin-700italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-700italic.svg#svgFontName) format("svg");font-style:italic;font-weight:700}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-800.eot);src:url(../fonts/nunito-v8-latin-800.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-800.woff2) format("woff2"),url(../fonts/nunito-v8-latin-800.woff) format("woff"),url(../fonts/nunito-v8-latin-800.ttf) format("truetype"),url(../fonts/nunito-v8-latin-800.svg#svgFontName) format("svg");font-style:normal;font-weight:800}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-800italic.eot);src:url(../fonts/nunito-v8-latin-800italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-800italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-800italic.woff) format("woff"),url(../fonts/nunito-v8-latin-800italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-800italic.svg#svgFontName) format("svg");font-style:italic;font-weight:800}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-900.eot);src:url(../fonts/nunito-v8-latin-900.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-900.woff2) format("woff2"),url(../fonts/nunito-v8-latin-900.woff) format("woff"),url(../fonts/nunito-v8-latin-900.ttf) format("truetype"),url(../fonts/nunito-v8-latin-900.svg#svgFontName) format("svg");font-style:normal;font-weight:900}@font-face{font-family:Nunito;src:url(../fonts/nunito-v8-latin-900italic.eot);src:url(../fonts/nunito-v8-latin-900italic.eot?#iefix) format("embedded-opentype"),url(../fonts/nunito-v8-latin-900italic.woff2) format("woff2"),url(../fonts/nunito-v8-latin-900italic.woff) format("woff"),url(../fonts/nunito-v8-latin-900italic.ttf) format("truetype"),url(../fonts/nunito-v8-latin-900italic.svg#svgFontName) format("svg");font-style:italic;font-weight:900}.moove-gdpr-donation-box-wrapper{width:auto;margin:10px 20px 0 2px}.moove-gdpr-donation-box-wrapper .moove-gdpr-donate-form{float:left;margin-right:20px}.moove-gdpr-donation-box-wrapper .moove-donation-box{padding-bottom:20px}.gdpr-admin-popup{position:fixed;top:0;left:0;width:100%;height:100%;z-index:999}.gdpr-admin-popup,.gdpr-admin-popup .gdpr-popup-close{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}.gdpr-admin-popup .gdpr-popup-close{position:absolute;top:-15px;right:-15px;width:30px;height:30px;text-decoration:none;border-radius:50%;background-color:#f79322;color:#fff;transition:all .4 ease}.gdpr-admin-popup .gdpr-popup-close:hover{background-color:#232323}.gdpr-admin-popup .gdpr-popup-overlay{background-color:rgba(0,0,0,.8);position:absolute;top:0;left:0;bottom:0;right:0;z-index:15}.gdpr-admin-popup .gdpr-popup-content{width:420px;max-width:70vw;background-color:#fff;padding:30px;border-radius:8px;text-align:center;position:relative;z-index:35}.gdpr-admin-popup .gdpr-popup-content p{font-size:14px;line-height:20px;margin-top:0}.gdpr-admin-popup .gdpr-popup-content h4{font-size:18px;line-height:28px;margin-top:0}#moove-gdpr-setting-error-settings_updated .wrap{width:100%;margin:0}#moove-gdpr-setting-error-settings_updated .wrap p{padding-left:0;margin-left:0}.gdpr-video-tutorial-content{position:relative;padding-bottom:56.25%;padding-top:25px;height:0}.gdpr_admin_link{text-decoration:none;color:#f79322;transition:all .4s ease}.gdpr_admin_link:hover{text-decoration:underline;color:#f79322}.gdpr_license_info{font-style:italic}#moove_gdpr_license_settings .wrap,#moove_gdpr_license_settings pre{width:100%;white-space:normal;word-break:break-all;margin:0}#moove_gdpr_license_settings .wrap span,#moove_gdpr_license_settings pre span{font-size:13px}#moove_gdpr_license_settings .wrap p,#moove_gdpr_license_settings pre p{margin-bottom:0}#moove_gdpr_license_settings .gdpr_license_log{padding:0}.gdpr-video-tutorial-content iframe{width:100%;height:auto;position:absolute;top:0;left:0;height:100%}.gdpr-faq-accordion-content textarea{width:100%;height:auto;height:200px}.gdpr-cookie-alert{background-color:#f79322;border:1px solid #f79322;color:#fff;box-shadow:0 3px 51px 0 rgba(0,0,0,.05);padding:10px;display:inline-block;width:auto;box-sizing:border-box;margin:10px 0 20px;border-radius:3px;padding-right:50px;position:relative}.gdpr-cookie-alert.gdpr-cookie-update-alert{display:block;width:100%;background-color:#fff;border:1px solid #ccc;box-shadow:0 3px 51px 0 rgba(0,0,0,.05);color:#23282d}.gdpr-cookie-alert.gdpr-cookie-update-alert a{color:#f79322}.gdpr-cookie-alert.gdpr-cookie-update-alert span.gdpr-dismiss,.gdpr-cookie-alert.gdpr-cookie-update-alert span.gdpr-dismiss-update{color:#23282d}.gdpr-cookie-alert.gdpr-cookie-update-alert span.gdpr-dismiss-update:hover,.gdpr-cookie-alert.gdpr-cookie-update-alert span.gdpr-dismiss:hover{color:#f79322}.gdpr-cookie-alert span.gdpr-dismiss,.gdpr-cookie-alert span.gdpr-dismiss-update{position:absolute;top:4px;right:8px;font-size:25px;font-weight:400;line-height:1;color:#fff;cursor:pointer;transition:all .4s ease}.gdpr-cookie-alert span.gdpr-dismiss-update:hover,.gdpr-cookie-alert span.gdpr-dismiss:hover{color:#23282d}.gdpr-cookie-alert h4{margin:0 0 10px;font-size:16px}.gdpr-cookie-alert p{margin:0;font-size:13px;font-weight:500}.gdpr-cookie-alert p strong{padding:2px 3px;display:inline-block;background-color:#fff;color:#23282d;margin:0 5px}.gdpr-disabled{pointer-events:none;cursor:default;opacity:.5}.gdpr-script-tabs-main-cnt{position:relative;overflow:hidden}body.toplevel_page_moove-gdpr{background-color:#fff}#moove_form_checker_wrap button.button-primary.button-reset-settings{float:right;background-color:#262c33;border-color:#737373;opacity:.5}#moove_form_checker_wrap button.button-primary.button-reset-settings:hover{opacity:1}#moove_form_checker_wrap .moove-gdpr-form-container{min-height:750px}.gdpr_license_log_alert{padding:0}.gdpr_license_log_alert .wrap>.update-messages,.gdpr_license_log_alert .wrap>h1,.gdpr_license_log_alert .wrap>p{display:none}.gdpr_license_log_alert .gdpr-admin-alert{position:relative;padding-right:40px;margin:20px 0}.gdpr_license_log_alert .gdpr-admin-alert .gdpr-alert-content{padding-right:30px}.gdpr_license_log_alert .gdpr-admin-alert .dashicons{position:absolute;top:5px;right:5px;width:30px;height:30px;border-radius:50%;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;color:rgba(5,150,24,.5);font-size:34px!important;background-color:#fff}.gdpr_license_log_alert .gdpr-admin-alert a{color:inherit;text-decoration:underline;margin-right:5px;font-weight:700}.gdpr_license_log_alert .gdpr-admin-alert a:hover{color:#262c33;text-decoration:underline}.gdpr_license_log_alert .gdpr-admin-alert.gdpr-admin-alert-success{background-color:rgba(5,150,24,.1);color:#059618;padding:5px 10px;border-radius:15px;border:2px solid rgba(5,150,24,.5)}.gdpr_license_log_alert .gdpr-admin-alert.gdpr-admin-alert-error{background-color:rgba(225,0,0,.1);color:#e10000;padding:5px 10px;border-radius:15px;border:2px solid rgba(225,0,0,.5)}.gdpr_license_log_alert .gdpr-admin-alert.gdpr-admin-alert-error .dashicons{color:rgba(225,0,0,.5)}.gdpr_license_log_alert .gdpr-admin-alert p{margin:5px 0}.gdpr-plugin-star-rating{display:inline-block;color:#ffb900;position:relative;top:3px}.gdpr-plugin-star-rating svg,.gdpr-plugin-star-rating svg:hover{fill:#ffb900}.gdpr-plugin-star-rating svg:hover~svg{fill:none}@font-face{font-family:gdpr-admin-icon;src:url(../fonts/gdpr-admin-icon.eot);src:url(../fonts/gdpr-admin-icon.eot#iefix) format("embedded-opentype"),url(../fonts/gdpr-admin-icon.woff2) format("woff2"),url(../fonts/gdpr-admin-icon.woff) format("woff"),url(../fonts/gdpr-admin-icon.ttf) format("truetype"),url(../fonts/gdpr-admin-icon.svg#gdpr-admin-icon) format("svg");font-weight:400;font-style:normal}#toplevel_page_moove-gdpr .dashicons-before{font-family:gdpr-admin-icon;font-style:normal;font-weight:400;speak:none;display:inline-block;text-decoration:inherit;width:1em;margin-right:.2em;text-align:center;font-variant:normal;text-transform:none;line-height:1em;margin-left:.2em;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}#toplevel_page_moove-gdpr .dashicons-before:before{content:"\e806";font-family:inherit;position:relative;top:2px}.gdpr-help-content-cnt .gdpr-help-content-block{margin-top:20px}.gdpr-help-content-cnt .gdpr-faq-toggle{box-shadow:0 3px 51px 0 rgba(0,0,0,.05);border:1px solid #ccc;margin-bottom:20px}.gdpr-help-content-cnt .gdpr-faq-toggle.gdpr-faq-open .gdpr-faq-accordion-header h3{background-color:#f79322;color:#fff}.gdpr-help-content-cnt .gdpr-faq-toggle.gdpr-faq-open .gdpr-faq-accordion-header h3:after{content:"-"}.gdpr-help-content-cnt .gdpr-faq-toggle .gdpr-faq-accordion-header h3{margin:0;position:relative;padding:15px 20px;padding-right:60px;cursor:pointer;transition:all .3s ease;font-size:16px!important}.gdpr-help-content-cnt .gdpr-faq-toggle .gdpr-faq-accordion-header h3:hover{background-color:#f79322;color:#fff}.gdpr-help-content-cnt .gdpr-faq-toggle .gdpr-faq-accordion-header h3:after{content:"+";width:50px;position:absolute;top:0;right:0;border-left:1px solid #ccc;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;font-size:26px;text-align:center;bottom:0;-ms-flex-pack:center;justify-content:center}.gdpr-help-content-cnt .gdpr-faq-toggle .gdpr-faq-accordion-content{padding:15px 60px 15px 20px;border-top:1px solid #ccc}.gdpr-help-content-cnt .gdpr-faq-toggle .gdpr-faq-accordion-content code{line-height:1.8;overflow:auto;display:block}.gdpr-disable-posts-nav{list-style-type:none;padding:5px 10px;margin:20px 0;background-color:#fff;box-shadow:0 3px 51px 0 rgba(0,0,0,.05);border:1px solid #ccc}.gdpr-disable-posts-nav li:first-child a{padding-left:0}.gdpr-disable-posts-nav li:last-child a{padding-right:0}.gdpr-disable-posts-nav li:after{content:"|";display:inline-block;position:absolute;right:-2px;top:10px}.gdpr-disable-posts-nav li:first-child:after,.gdpr-disable-posts-nav li:last-child:after{display:none}.gdpr-disable-posts-nav li{list-style:none;display:inline-block;float:left;position:relative;margin:0}.gdpr-disable-posts-nav li a.active{color:#f79322}.gdpr-disable-posts-nav li a,.gdpr-disable-posts-nav li strong{display:block;padding:10px;outline:none;box-shadow:none}.gdpr-disable-posts-nav li strong{padding-left:0}body.toplevel_page_moove-gdpr #wpcontent{background-color:#fff}.gdpr-script-tab-content{position:relative;overflow:hidden}.gdpr-script-tab-content .gdpr-tab-code-section{transition:all .8s ease;top:0;right:0;left:0}.gdpr-script-tab-content .gdpr-tab-code-section:not(.gdpr-active){height:0;opacity:0;margin:0;position:absolute;top:100%;visibility:hidden}.gdpr-tab-code-section-nav ul{list-style-type:none;padding:0;margin:20px 1px 0;display:-ms-flexbox;display:flex}.gdpr-tab-code-section-nav ul li{list-style:none;padding:0;margin:0 -1px;position:relative;border:1px solid #f79322;border-bottom:0;overflow:hidden}.gdpr-tab-code-section-nav ul li:first-child{border-top-left-radius:10px}.gdpr-tab-code-section-nav ul li:last-child{border-top-right-radius:10px}.gdpr-tab-code-section-nav ul li a{background-color:#fff;display:block;padding:8px 20px;text-decoration:none;font-weight:700;font-size:14px;color:#555;transition:all .3s ease;outline:none;box-shadow:none}.gdpr-tab-code-section-nav ul li a:before{content:"\21B3";transform:rotate(90deg);display:inline-block;position:absolute;top:0;left:0;width:0;color:#fff;opacity:0;transition:all .3s ease}.gdpr-tab-code-section-nav ul li a.gdpr-active:before{opacity:1;top:4px;left:10px}.gdpr-tab-code-section-nav ul li a.gdpr-active,.gdpr-tab-code-section-nav ul li a:hover{background-color:#f79322;color:#fff}.gdpr-tab-code-section{background-color:#fff;padding:20px;border:1px solid #f79322;border-bottom-left-radius:10px;border-bottom-right-radius:10px;border-top-right-radius:10px;position:relative;overflow-wrap:hidden}.gdpr-tab-code-section .CodeMirror{font-size:15px;width:100%;height:300px;box-sizing:border-box;background-color:#fff;border:1px solid #ccc}.gdpr-tab-code-section .CodeMirror-gutters{padding-bottom:0;background-color:#f1f1f1}.gdpr-tab-code-section p.description{font-weight:600;font-size:13px}.gdpr-tab-code-section h4{margin:-20px -20px 0;padding:15px 20px;border-bottom:1px solid #ccc}.gdpr-tab-code-section table{width:100%}.gdpr-tab-code-section .gdpr-code{padding:10px;background-color:#f1f1f1}.gdpr-img-responsive{max-width:100%;height:auto}.gdpr-tab-section-cnt{max-width:calc(100% - 380px);display:inline-block;width:100%}.gdpr-tab-section-cnt .regular-text{width:100%}.gdpr-tab-section-cnt .powered-by-label{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;margin-bottom:15px}.gdpr-tab-section-cnt .powered-by-label label{white-space:nowrap;margin-right:20px}.gdpr-conditional-field:not(.gdpr-conditional-on){display:none}.gdpr-checkbox-toggle{position:relative;display:inline-block;width:160px;height:24px;box-sizing:border-box}.gdpr-checkbox-toggle *{box-sizing:border-box}.gdpr-checkbox-toggle.gdpr-checkbox-inverted input:checked+.gdpr-checkbox-slider{background-color:red}.gdpr-checkbox-toggle.gdpr-checkbox-inverted input:checked+.gdpr-checkbox-slider:after{content:attr(data-disable)}.gdpr-checkbox-toggle.gdpr-checkbox-inverted .gdpr-checkbox-slider{background-color:#2e9935}.gdpr-checkbox-toggle.gdpr-checkbox-inverted .gdpr-checkbox-slider:after{content:attr(data-enable)}.gdpr-checkbox-toggle.gdpr-color-scheme-toggle input:checked+.gdpr-checkbox-slider{background-color:#202020}.gdpr-checkbox-toggle.gdpr-color-scheme-toggle input:checked+.gdpr-checkbox-slider:after{color:#fff}.gdpr-checkbox-toggle.gdpr-color-scheme-toggle .gdpr-checkbox-slider,.gdpr-checkbox-toggle.gdpr-color-scheme-toggle input:checked+.gdpr-checkbox-slider:before{background-color:#fff}.gdpr-checkbox-toggle.gdpr-color-scheme-toggle .gdpr-checkbox-slider:after{color:#202020}.gdpr-checkbox-toggle.gdpr-color-scheme-toggle .gdpr-checkbox-slider:before{background-color:#202020}.gdpr-checkbox-toggle input{opacity:0;width:0;height:0}.gdpr-checkbox-toggle input:checked+.gdpr-checkbox-slider{background-color:#2e9935}.gdpr-checkbox-toggle input:checked+.gdpr-checkbox-slider:after{content:attr(data-enable)}.gdpr-checkbox-toggle input:checked+.gdpr-checkbox-slider:before{transform:translateX(136px)}.gdpr-checkbox-toggle .gdpr-checkbox-slider{position:absolute;cursor:pointer;top:0;left:0;right:0;bottom:0;background-color:red;transition:.4s;border-radius:34px;border:1px solid #ddd}.gdpr-checkbox-toggle .gdpr-checkbox-slider:before{position:absolute;content:"";height:20px;width:20px;left:1px;bottom:1px;background-color:#fff;transition:.4s;border-radius:50%}.gdpr-checkbox-toggle .gdpr-checkbox-slider:after{content:attr(data-disable);position:absolute;top:5px;left:0;right:0;color:#fff;font-size:12px;display:block;z-index:4;text-transform:uppercase;text-align:center;font-weight:600;font-family:Helvetica;letter-spacing:.5px}.moove-plugins-info-boxes{display:inline-block;float:right;width:350px;background-color:#fff}.moove-plugins-info-boxes .m-plugin-box{border:1px solid #ccc;margin-bottom:30px;background-color:#fff;border-radius:5px;box-shadow:0 3px 51px 0 rgba(0,0,0,.05)}.moove-plugins-info-boxes .m-plugin-box.m-plugin-box-highlighted{border:2px solid #f79322}.moove-plugins-info-boxes .m-plugin-box.m-plugin-box-highlighted .box-header{background-color:#f79322;border-color:#f79322;color:#fff}.moove-plugins-info-boxes .m-plugin-box.m-plugin-box-support:not(.m-plugin-box-highlighted) .gdpr-review-bnt{background-color:rgba(85,85,85,.5);color:#fff}.moove-plugins-info-boxes .m-plugin-box.m-plugin-box-support:not(.m-plugin-box-highlighted) .gdpr-review-bnt:hover{background-color:#232323;color:#fff}.moove-plugins-info-boxes .m-plugin-box .box-content .gdpr-faq-forum-content p{position:relative;padding-left:15px;line-height:1.3;margin-bottom:10px}.moove-plugins-info-boxes .m-plugin-box .box-content .gdpr-faq-forum-content p .gdpr-chevron-left{color:#f79322;font-size:18px;position:absolute;left:0;top:7px;line-height:0}.moove-plugins-info-boxes .m-plugin-box a:not(.gdpr-review-bnt):not(.plugin-buy-now-btn){color:#f79322;transition:all .3s ease}.moove-plugins-info-boxes .m-plugin-box a:not(.gdpr-review-bnt):not(.plugin-buy-now-btn):hover{color:#23282d}.moove-plugins-info-boxes .m-plugin-box .gdpr-review-bnt{text-decoration:none;outline:none;padding:7px 20px;font-size:12px;font-weight:500;background-color:#f79322;color:#fff;transition:all .3s ease;line-height:18px;border:none;display:inline-block;margin:10px 0}.moove-plugins-info-boxes .m-plugin-box .gdpr-review-bnt:hover{background-color:#262c33}.moove-plugins-info-boxes .m-plugin-box .box-header{padding:10px;border-bottom:1px solid #ccc}.moove-plugins-info-boxes .m-plugin-box .box-header h4{font-size:14px;font-weight:600;margin:0;font-family:Nunito}.moove-plugins-info-boxes .m-plugin-box .box-content{padding:10px}.moove-plugins-info-boxes .m-plugin-box .box-content p{margin-top:5px;margin-bottom:5px}.moove-plugins-info-boxes .m-plugin-box .box-content hr{margin:10px 0}.moove-plugins-info-boxes .m-plugin-box .plugin-rating{display:-ms-flexbox;display:flex;margin:10px 0 20px;-ms-flex-align:center;align-items:center;transform:scale(1.3);width:100%;padding-left:13%}.moove-plugins-info-boxes .m-plugin-box .plugin-rating .plugin-stars{display:inline-block;width:50%}.moove-plugins-info-boxes .m-plugin-box .gdpr-review-container{display:block;text-align:left;margin:0}.moove-plugins-info-boxes .m-plugin-box .plugin-stats{display:-ms-flexbox;display:flex}.moove-plugins-info-boxes .m-plugin-box .plugin-stats *{box-sizing:border-box}.moove-plugins-info-boxes .m-plugin-box .plugin-stats .plugin-download-ainstalls-cnt{display:inline-block;width:calc(100% - 130px);line-height:20px}.moove-plugins-info-boxes .m-plugin-box .plugin-stats .plugin-rating{width:125px;box-sizing:border-box;text-align:right;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:end;justify-content:flex-end;padding:0;margin:0}.moove-plugins-info-boxes .m-plugin-box .plugin-stats .plugin-rating .plugin-stars{width:100px;transform:scale(.8)}.moove-plugins-info-boxes .m-plugin-box .plugin-features{padding-left:20px;margin-top:5px}.moove-plugins-info-boxes .m-plugin-box .plugin-features li{list-style-type:square}.moove-plugins-info-boxes .m-plugin-box .plugin-buy-now-btn{display:block;text-decoration:none;outline:none;box-shadow:none;padding:7px 20px;background-color:#f79322;color:#fff;text-align:center;transition:all .3s ease;margin:15px 0;font-weight:600;font-size:12px}.moove-plugins-info-boxes .m-plugin-box .plugin-buy-now-btn:hover{background-color:#232323}.gdpr-tab-section-cnt{position:relative;overflow:hidden}.gdpr-tab-section-cnt .form-table th{width:250px;max-width:250px}@media (max-width:1280px){.gdpr-tab-section-cnt{max-width:100%;display:block;width:100%}.gdpr-tab-section-cnt .form-table th{width:200px}.moove-plugins-info-boxes{display:inline-block;float:none;width:100%;padding:0;margin:15px 0;background-color:#f1f1f1}}.gdpr-locked-section{padding:0 40px;background-color:#fff;border:1px solid #ccc;display:-ms-flexbox;display:flex;-ms-flex-item-align:center;align-self:center;margin-top:90px;border-radius:5px}.gdpr-locked-section span{display:block;width:100%;transform:translateY(-50px);text-align:center}.gdpr-locked-section h4{font-size:28px;line-height:32px;margin:60px 0 30px;text-align:center}.gdpr-locked-section *{box-sizing:border-box}.gdpr-locked-section i{font-size:30px;line-height:55px;color:#f79322;width:60px;height:50px;background-color:#fff;border:1px solid #ccc;border-bottom:1px solid #fff;border-top-left-radius:100px;border-top-right-radius:100px}.gdpr-locked-section .plugin-buy-now-btn{display:block;text-decoration:none;outline:none;box-shadow:none;padding:7px 20px;background-color:#f79322;color:#fff;text-align:center;transition:all .3s ease;margin:15px auto 0;font-weight:600;font-size:12px;max-width:200px}.gdpr-locked-section .plugin-buy-now-btn:hover{background-color:#232323}#moove_form_checker_wrap .nav-tab-wrapper a.nav-tab.gdpr-cc-addon.gdpr-cc-disabled{background-color:#fff;color:#f79322;line-height:20px}.moove-donation-box{position:relative;width:calc(100% - 20px);margin:16px 0;padding:0 15px 10px;box-shadow:0 1px 1px rgba(0,0,0,.04);background:#fff;font-size:13px}.moove-donation-box .notice-dismiss:before{float:left;margin:0 4px -2px 0}.moove-redirect-box{width:100%}.moove-not-visible{opacity:0;visibility:hidden;position:absolute}.moove-gdpr-form-container{min-height:45vh}.moove-gdpr-form-container input[type=radio].on-off{margin:0}.moove-gdpr-form-container input.iris-colorpicker{text-shadow:1px 0 0 #fff,-1px 0 0 #fff,0 1px 0 #fff,0 -1px 0 #fff,1px 1px #fff,-1px -1px 0 #fff,1px -1px 0 #fff,-1px 1px 0 #fff;text-transform:uppercase;outline:none!important;box-shadow:none!important;font-weight:700;font-size:14px;border:none;width:120px;height:30px;margin:0;border-top-left-radius:5px;border-bottom-left-radius:5px}.moove-gdpr-form-container .iris-selectbtn{position:relative;background-color:#fff;display:inline-block;padding:0 5px;text-transform:uppercase;font-size:11px;line-height:30px;font-weight:700;float:right;border-top-right-radius:5px;border-bottom-right-radius:5px;cursor:pointer}.moove-gdpr-form-container .iris-colorpicker-group-cnt{display:inline-block;border:1px solid #ddd;border-radius:5px}.moove-gdpr-form-container .iris-picker{position:absolute}.moove-gdpr-form-container .iris-picker:before{content:"";position:fixed;width:100%;height:100%;top:0;left:0}.moove-gdpr-form-container .iris-picker .iris-picker-inner{z-index:100}.moove-clearfix:after{content:"";clear:both;display:table}.moove_gdpr_company_logo_holder{display:inline-block;padding-bottom:50px;width:130px;height:0;background-position:0;background-repeat:no-repeat;background-size:contain}#wp-moove_gdpr_advanced_cookies_tab_content-wrap,#wp-moove_gdpr_cookies_policy_tab_content-wrap,#wp-moove_gdpr_ifb_content-wrap,#wp-moove_gdpr_info_bar_content-wrap,#wp-moove_gdpr_modal_strictly_secondary_notice-wrap,#wp-moove_gdpr_performance_cookies_tab_content-wrap,#wp-moove_gdpr_privacy_overview_tab_content-wrap,#wp-moove_gdpr_strict_necessary_cookies_tab_content-wrap,#wp-moove_gdpr_strictly_necessary_cookies_warning-wrap{max-width:100%}span.separator{display:inline-block;margin-left:10px}.gdpr-cookie-compliance-header-section{padding-left:100px;position:relative;margin:30px 0}.gdpr-cookie-compliance-header-section a{color:#f79322}.gdpr-cookie-compliance-header-section:before{content:"";position:absolute;left:0;top:0;width:100px;height:100px;background-image:url(../images/gdpr-cookie-compliance-icon.png);background-position:0;background-repeat:no-repeat;background-size:contain}.gdpr-cookie-compliance-header-section h2{font-family:Nunito,sans-serif;font-size:30px;font-weight:800;padding-top:25px;margin-bottom:10px}.gdpr-cookie-compliance-header-section h2 .gdpr-plugin-version{font-size:16px;font-weight:400;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;color:#565656;margin-left:5px}.gdpr-cookie-compliance-header-section h4{margin-top:10px}#moove_form_checker_wrap{position:relative}#moove_form_checker_wrap .button-primary{background-color:#f89e26;border:none;border-radius:0;text-shadow:none;box-shadow:none;outline:none;padding:8px 15px;font-size:12px;font-weight:500;color:#fff;transition:all .3s ease;height:auto;line-height:18px;border:1px solid #d28b21}#moove_form_checker_wrap .button-primary.button-inverse,#moove_form_checker_wrap .button-primary:hover{background-color:#262c33;border:1px solid #737373}#moove_form_checker_wrap .button-primary.button-inverse:hover{background-color:#f89e26;border:1px solid #d28b21}#moove_form_checker_wrap h1{margin:0;padding:0}#moove_form_checker_wrap h2,#moove_form_checker_wrap h3{font-family:Nunito,sans-serif;font-weight:800;font-size:20px}#moove_form_checker_wrap .gdpr-tab-section-cnt:after{content:"";clear:both;display:table}#moove_form_checker_wrap .nav-tab-wrapper{width:200px;display:inline-block;padding-right:17px;padding-top:0;position:relative}#moove_form_checker_wrap .nav-tab-wrapper a.nav-tab{font-size:12px;padding:10px 8px;width:100%;margin-left:0;outline:none;box-shadow:none;border-right:0;position:relative;white-space:normal;line-height:1.3}#moove_form_checker_wrap .nav-tab-wrapper .nav-tab-active,#moove_form_checker_wrap .nav-tab-wrapper .nav-tab-active:focus,#moove_form_checker_wrap .nav-tab-wrapper .nav-tab-active:focus:active,#moove_form_checker_wrap .nav-tab-wrapper .nav-tab-active:hover{border-bottom:1px solid #ccc;color:#f79322;outline:none;box-shadow:none;background-color:#fff}#moove_form_checker_wrap .nav-tab-wrapper .nav-tab-active:after{content:"";position:absolute;right:-1px;top:0;width:2px;bottom:0;background-color:#fff}#moove_form_checker_wrap .moove-gdpr-form-container{width:calc(100% - 279px);float:right;padding:5px 30px 30px;border:1px solid #ccc}#moove_gdpr_info_bar_content-html,#moove_gdpr_info_bar_content-tmce{display:none}#moove_form_checker_wrap .moove-gdpr-settings-branding{margin:25px 0;font-style:italic}#moove_form_checker_wrap .moove-gdpr-settings-branding hr{margin:0}#moove_form_checker_wrap .moove-gdpr-settings-branding p{margin:15px 0}#moove_form_checker_wrap .moove-gdpr-settings-branding p span{display:inline-block;background-image:url(../images/moove_logo_br.png);width:66px;height:15px;background-size:contain;background-repeat:no-repeat;background-position:0 100%}#moove_form_checker_wrap .moove-gdpr-settings-branding p a{text-decoration:none;color:inherit}#moove_form_checker_wrap .moove-gdpr-settings-branding p a:hover{text-decoration:underline}.moove-gdpr-form-error .alert.script-error{color:#fff;padding:10px;background-color:red;text-transform:uppercase}#moove_form_checker_wrap .CodeMirror{font-family:monospace;height:300px;color:#000;direction:ltr}#moove_form_checker_wrap .gdpr-faq-accordion-content .CodeMirror{max-height:300px;height:auto}#moove_form_checker_wrap .CodeMirror-lines{padding:4px 0}#moove_form_checker_wrap .CodeMirror pre{padding:0 4px}#moove_form_checker_wrap .CodeMirror-gutter-filler,#moove_form_checker_wrap .CodeMirror-scrollbar-filler{background-color:#fff}#moove_form_checker_wrap .CodeMirror-gutters{border-right:1px solid #ddd;background-color:#f7f7f7;white-space:nowrap}#moove_form_checker_wrap .CodeMirror-linenumber{padding:0 3px 0 5px;min-width:20px;text-align:right;color:#999;white-space:nowrap}#moove_form_checker_wrap .CodeMirror-guttermarker{color:#000}#moove_form_checker_wrap .CodeMirror-guttermarker-subtle{color:#999}#moove_form_checker_wrap .CodeMirror-cursor{border-left:1px solid #000;border-right:none;width:0}#moove_form_checker_wrap .CodeMirror div.CodeMirror-secondarycursor{border-left:1px solid silver}#moove_form_checker_wrap .cm-fat-cursor .CodeMirror-cursor{width:auto;border:0!important;background:#7e7}#moove_form_checker_wrap .cm-fat-cursor div.CodeMirror-cursors{z-index:1}#moove_form_checker_wrap .cm-fat-cursor-mark{background-color:rgba(20,255,20,.5);animation:blink 1.06s steps(1) infinite}#moove_form_checker_wrap .cm-animate-fat-cursor{width:auto;border:0;animation:blink 1.06s steps(1) infinite;background-color:#7e7}@keyframes blink{50%{background-color:transparent}}#moove_form_checker_wrap .cm-tab{display:inline-block;text-decoration:inherit}#moove_form_checker_wrap .CodeMirror-rulers{position:absolute;left:0;right:0;top:-50px;bottom:-20px;overflow:hidden}#moove_form_checker_wrap .CodeMirror-ruler{border-left:1px solid #ccc;top:0;bottom:0;position:absolute}#moove_form_checker_wrap .cm-s-default .cm-header{color:blue}#moove_form_checker_wrap .cm-s-default .cm-quote{color:#090}#moove_form_checker_wrap .cm-negative{color:#d44}#moove_form_checker_wrap .cm-positive{color:#292}#moove_form_checker_wrap .cm-header,.cm-strong{font-weight:700}#moove_form_checker_wrap .cm-em{font-style:italic}#moove_form_checker_wrap .cm-link{text-decoration:underline}#moove_form_checker_wrap .cm-strikethrough{text-decoration:line-through}#moove_form_checker_wrap .cm-s-default .cm-keyword{color:#708}#moove_form_checker_wrap .cm-s-default .cm-atom{color:#219}#moove_form_checker_wrap .cm-s-default .cm-number{color:#164}#moove_form_checker_wrap .cm-s-default .cm-def{color:#00f}#moove_form_checker_wrap .cm-s-default .cm-variable-2{color:#05a}#moove_form_checker_wrap .cm-s-default .cm-variable-3,.cm-s-default .cm-type{color:#085}#moove_form_checker_wrap .cm-s-default .cm-comment{color:#a50}#moove_form_checker_wrap .cm-s-default .cm-string{color:#a11}#moove_form_checker_wrap .cm-s-default .cm-string-2{color:#f50}#moove_form_checker_wrap .cm-s-default .cm-meta,#moove_form_checker_wrap .cm-s-default .cm-qualifier{color:#555}#moove_form_checker_wrap .cm-s-default .cm-builtin{color:#30a}#moove_form_checker_wrap .cm-s-default .cm-bracket{color:#997}#moove_form_checker_wrap .cm-s-default .cm-tag{color:#170}#moove_form_checker_wrap .cm-s-default .cm-attribute{color:#00c}#moove_form_checker_wrap .cm-s-default .cm-hr{color:#999}#moove_form_checker_wrap .cm-s-default .cm-link{color:#00c}#moove_form_checker_wrap .cm-invalidchar,#moove_form_checker_wrap .cm-s-default .cm-error{color:red}#moove_form_checker_wrap .CodeMirror-composing{border-bottom:2px solid}#moove_form_checker_wrap div.CodeMirror span.CodeMirror-matchingbracket{color:#0b0}#moove_form_checker_wrap div.CodeMirror span.CodeMirror-nonmatchingbracket{color:#a22}#moove_form_checker_wrap .CodeMirror-matchingtag{background:rgba(255,150,0,.3)}#moove_form_checker_wrap .CodeMirror-activeline-background{background:#e8f2ff}#moove_form_checker_wrap .CodeMirror{position:relative;overflow:hidden;background:#fff}#moove_form_checker_wrap .CodeMirror-scroll{overflow:scroll!important;margin-bottom:-30px;margin-right:-30px;padding-bottom:30px;height:100%;outline:none;position:relative}#moove_form_checker_wrap .CodeMirror-sizer{position:relative;border-right:30px solid transparent}#moove_form_checker_wrap .CodeMirror-gutter-filler,#moove_form_checker_wrap .CodeMirror-hscrollbar,#moove_form_checker_wrap .CodeMirror-scrollbar-filler,#moove_form_checker_wrap .CodeMirror-vscrollbar{position:absolute;z-index:6;display:none}#moove_form_checker_wrap .CodeMirror-vscrollbar{right:0;top:0;overflow-x:hidden;overflow-y:scroll}#moove_form_checker_wrap .CodeMirror-hscrollbar{bottom:0;left:0;overflow-y:hidden;overflow-x:scroll}#moove_form_checker_wrap .CodeMirror-scrollbar-filler{right:0;bottom:0}#moove_form_checker_wrap .CodeMirror-gutter-filler{left:0;bottom:0}#moove_form_checker_wrap .CodeMirror-gutters{position:absolute;left:0;top:0;min-height:100%;z-index:3}#moove_form_checker_wrap .CodeMirror-gutter{white-space:normal;height:100%;display:inline-block;vertical-align:top;margin-bottom:-30px}#moove_form_checker_wrap .CodeMirror-gutter-wrapper{position:absolute;z-index:4;background:none!important;border:none!important}#moove_form_checker_wrap .CodeMirror-gutter-background{position:absolute;top:0;bottom:0;z-index:4}#moove_form_checker_wrap .CodeMirror-gutter-elt{position:absolute;cursor:default;z-index:4}#moove_form_checker_wrap .CodeMirror-gutter-wrapper ::selection{background-color:transparent}#moove_form_checker_wrap .CodeMirror-gutter-wrapper ::-moz-selection{background-color:transparent}#moove_form_checker_wrap .CodeMirror-lines{cursor:text;min-height:1px}#moove_form_checker_wrap .CodeMirror pre{border-radius:0;border-width:0;background:transparent;font-family:inherit;font-size:inherit;margin:0;white-space:pre;word-wrap:normal;line-height:inherit;color:inherit;z-index:2;position:relative;overflow:visible;-webkit-tap-highlight-color:transparent;font-variant-ligatures:contextual}#moove_form_checker_wrap .CodeMirror-wrap pre{word-wrap:break-word;white-space:pre-wrap;word-break:normal}#moove_form_checker_wrap .CodeMirror-linebackground{position:absolute;left:0;right:0;top:0;bottom:0;z-index:0}#moove_form_checker_wrap .CodeMirror-linewidget{position:relative;z-index:2;padding:.1px}#moove_form_checker_wrap .CodeMirror-rtl pre{direction:rtl}#moove_form_checker_wrap .CodeMirror-code{outline:none}#moove_form_checker_wrap .CodeMirror-gutter,#moove_form_checker_wrap .CodeMirror-gutters,#moove_form_checker_wrap .CodeMirror-linenumber,#moove_form_checker_wrap .CodeMirror-scroll,#moove_form_checker_wrap .CodeMirror-sizer{box-sizing:content-box}#moove_form_checker_wrap .CodeMirror-measure{position:absolute;width:100%;height:0;overflow:hidden;visibility:hidden}#moove_form_checker_wrap .CodeMirror-cursor{position:absolute;pointer-events:none}#moove_form_checker_wrap .CodeMirror-measure pre{position:static}#moove_form_checker_wrap div.CodeMirror-cursors{visibility:hidden;position:relative;z-index:3}#moove_form_checker_wrap .CodeMirror-focused div.CodeMirror-cursors,#moove_form_checker_wrap div.CodeMirror-dragcursors{visibility:visible}#moove_form_checker_wrap .CodeMirror-selected{background:#d9d9d9}#moove_form_checker_wrap .CodeMirror-focused .CodeMirror-selected{background:#d7d4f0}#moove_form_checker_wrap .CodeMirror-crosshair{cursor:crosshair}#moove_form_checker_wrap .CodeMirror-line::selection,.CodeMirror-line>span::selection,.CodeMirror-line>span>span::selection{background:#d7d4f0}#moove_form_checker_wrap .CodeMirror-line::-moz-selection,.CodeMirror-line>span::-moz-selection,.CodeMirror-line>span>span::-moz-selection{background:#d7d4f0}#moove_form_checker_wrap .cm-searching{background-color:#ffa;background-color:rgba(255,255,0,.4)}#moove_form_checker_wrap .cm-force-border{padding-right:.1px}@media print{#moove_form_checker_wrap .CodeMirror div.CodeMirror-cursors{visibility:hidden}}#moove_form_checker_wrap .cm-tab-wrap-hack:after{content:""}#moove_form_checker_wrap span.CodeMirror-selectedtext{background:none}
|
gdpr-functions.php
ADDED
@@ -0,0 +1,400 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Moove_Functions File Doc Comment
|
4 |
+
*
|
5 |
+
* @category Moove_Functions
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
11 |
+
exit;
|
12 |
+
} // Exit if accessed directly
|
13 |
+
|
14 |
+
if ( ! function_exists( 'moove_gdpr_get_plugin_directory_url' ) ) :
|
15 |
+
/**
|
16 |
+
* Relative path of the GDPR cookie plugin
|
17 |
+
*/
|
18 |
+
function moove_gdpr_get_plugin_directory_url() {
|
19 |
+
return plugin_dir_url( __FILE__ );
|
20 |
+
}
|
21 |
+
endif;
|
22 |
+
|
23 |
+
|
24 |
+
add_filter( 'plugin_action_links', 'moove_gdpr_plugin_settings_link', 10, 2 );
|
25 |
+
/**
|
26 |
+
* Extension to display support, premium and settings links in the plugin listing page
|
27 |
+
*
|
28 |
+
* @param array $links Links.
|
29 |
+
* @param string $file File.
|
30 |
+
*/
|
31 |
+
function moove_gdpr_plugin_settings_link( $links, $file ) {
|
32 |
+
if ( plugin_basename( dirname( __FILE__ ) . '/moove-gdpr.php' ) === $file ) {
|
33 |
+
/*
|
34 |
+
* Insert the Settings page link at the beginning
|
35 |
+
*/
|
36 |
+
$in = '<a href="?page=moove-gdpr">' . __( 'Settings', 'gdpr-cookie-compliance' ) . '</a>';
|
37 |
+
array_unshift( $links, $in );
|
38 |
+
|
39 |
+
/*
|
40 |
+
* Insert the Support page link at the end
|
41 |
+
*/
|
42 |
+
$in = '<a href="https://support.mooveagency.com/forum/gdpr-cookie-compliance/" target="_blank">' . __( 'Support', 'gdpr-cookie-compliance' ) . '</a>';
|
43 |
+
array_push( $links, $in );
|
44 |
+
|
45 |
+
/*
|
46 |
+
* Insert the Premium Upgrade link at the end
|
47 |
+
*/
|
48 |
+
$in = '<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank">' . __( 'Premium Upgrade', 'gdpr-cookie-compliance' ) . '</a>';
|
49 |
+
array_push( $links, $in );
|
50 |
+
}
|
51 |
+
return $links;
|
52 |
+
}
|
53 |
+
|
54 |
+
/**
|
55 |
+
* Get an attachment ID given a URL.
|
56 |
+
*
|
57 |
+
* @param string $url URL.
|
58 |
+
* @return int Attachment ID on success, 0 on failure
|
59 |
+
*/
|
60 |
+
function gdpr_get_attachment_id( $url ) {
|
61 |
+
$attachment_id = 0;
|
62 |
+
$dir = wp_upload_dir();
|
63 |
+
if ( false !== strpos( $url, $dir['baseurl'] . '/' ) ) { // Is URL in uploads directory?
|
64 |
+
$file = basename( $url );
|
65 |
+
$query_args = array(
|
66 |
+
'post_type' => 'attachment',
|
67 |
+
'post_status' => 'inherit',
|
68 |
+
'fields' => 'ids',
|
69 |
+
'meta_query' => array(
|
70 |
+
array(
|
71 |
+
'value' => $file,
|
72 |
+
'compare' => 'LIKE',
|
73 |
+
'key' => '_wp_attachment_metadata',
|
74 |
+
),
|
75 |
+
),
|
76 |
+
);
|
77 |
+
$query = new WP_Query( $query_args );
|
78 |
+
if ( $query->have_posts() ) {
|
79 |
+
while ( $query->have_posts() ) :
|
80 |
+
$query->the_post();
|
81 |
+
$post_id = get_the_ID();
|
82 |
+
$meta = wp_get_attachment_metadata( $post_id );
|
83 |
+
if ( $meta && isset( $meta['file'] ) && isset( $meta['sizes'] ) ) :
|
84 |
+
$original_file = basename( $meta['file'] );
|
85 |
+
$cropped_image_files = wp_list_pluck( $meta['sizes'], 'file' );
|
86 |
+
if ( $original_file === $file || in_array( $file, $cropped_image_files, false ) ) {
|
87 |
+
$attachment_id = $post_id;
|
88 |
+
break;
|
89 |
+
}
|
90 |
+
endif;
|
91 |
+
endwhile;
|
92 |
+
wp_reset_postdata();
|
93 |
+
}
|
94 |
+
}
|
95 |
+
return $attachment_id;
|
96 |
+
}
|
97 |
+
|
98 |
+
/**
|
99 |
+
* Get image alt text by image URL
|
100 |
+
*
|
101 |
+
* @param String $image_url Image URL.
|
102 |
+
*
|
103 |
+
* @return Bool | String
|
104 |
+
*/
|
105 |
+
function gdpr_get_logo_alt( $image_url ) {
|
106 |
+
|
107 |
+
global $wpdb;
|
108 |
+
|
109 |
+
if ( empty( $image_url ) ) {
|
110 |
+
return get_bloginfo( 'name' );
|
111 |
+
}
|
112 |
+
$image_id = gdpr_get_attachment_id( $image_url );
|
113 |
+
if ( $image_id ) :
|
114 |
+
$image_alt = get_post_meta( $image_id, '_wp_attachment_image_alt', true );
|
115 |
+
return $image_alt;
|
116 |
+
else :
|
117 |
+
return get_bloginfo( 'name' );
|
118 |
+
endif;
|
119 |
+
|
120 |
+
}
|
121 |
+
|
122 |
+
/**
|
123 |
+
* GDPR Module manager, introduced in version 1.1.5
|
124 |
+
*
|
125 |
+
* @param string $module Module.
|
126 |
+
*/
|
127 |
+
function gdpr_get_module( $module = '' ) {
|
128 |
+
if ( $module ) :
|
129 |
+
$module_controller = new GDPR_Modules();
|
130 |
+
$response = false;
|
131 |
+
switch ( $module ) :
|
132 |
+
case 'floating-button':
|
133 |
+
$response = apply_filters( 'gdpr_floating_button_module', $module_controller->get_floating_button() );
|
134 |
+
break;
|
135 |
+
case 'infobar-base':
|
136 |
+
$response = apply_filters( 'gdpr_infobar_base_module', $module_controller->get_infobar_base() );
|
137 |
+
break;
|
138 |
+
case 'infobar-content':
|
139 |
+
$response = apply_filters( 'gdpr_infobar_content_module', $module_controller->get_infobar_content() );
|
140 |
+
break;
|
141 |
+
case 'infobar-buttons':
|
142 |
+
$response = apply_filters( 'gdpr_infobar_buttons_module', $module_controller->get_infobar_buttons() );
|
143 |
+
break;
|
144 |
+
case 'company-logo':
|
145 |
+
$response = apply_filters( 'gdpr_company_logo_module', $module_controller->get_company_logo() );
|
146 |
+
break;
|
147 |
+
case 'gdpr-branding':
|
148 |
+
$response = apply_filters( 'gdpr_branding_module', $module_controller->get_gdpr_branding() );
|
149 |
+
break;
|
150 |
+
case 'modal-base':
|
151 |
+
$response = apply_filters( 'gdpr_modal_base_module', $module_controller->get_modal_base() );
|
152 |
+
break;
|
153 |
+
case 'tab-navigation':
|
154 |
+
$response = apply_filters( 'gdpr_tab_navigation_module', $module_controller->get_tab_navigation() );
|
155 |
+
break;
|
156 |
+
case 'modal-footer-buttons':
|
157 |
+
$response = apply_filters( 'gdpr_modal_footer_buttons_module', $module_controller->get_tab_footer_buttons() );
|
158 |
+
break;
|
159 |
+
case 'section-overview':
|
160 |
+
$response = apply_filters( 'gdpr_section_overview_module', $module_controller->get_section_overview() );
|
161 |
+
break;
|
162 |
+
case 'section-strictly':
|
163 |
+
$response = apply_filters( 'gdpr_section_strictly_module', $module_controller->get_section_strictly() );
|
164 |
+
break;
|
165 |
+
case 'section-advanced':
|
166 |
+
$response = apply_filters( 'gdpr_section_advanced_module', $module_controller->get_section_advanced() );
|
167 |
+
break;
|
168 |
+
case 'section-third_party':
|
169 |
+
$response = apply_filters( 'gdpr_section_third_party_module', $module_controller->get_section_third_party() );
|
170 |
+
break;
|
171 |
+
case 'section-cookiepolicy':
|
172 |
+
$response = apply_filters( 'gdpr_section_cookiepolicy_module', $module_controller->get_section_cookiepolicy() );
|
173 |
+
break;
|
174 |
+
case 'branding-styles':
|
175 |
+
$response = apply_filters( 'gdpr_branding_styles_module', $module_controller->get_branding_styles() );
|
176 |
+
break;
|
177 |
+
default:
|
178 |
+
endswitch;
|
179 |
+
endif;
|
180 |
+
return $response;
|
181 |
+
}
|
182 |
+
|
183 |
+
|
184 |
+
if ( ! function_exists( 'gdpr_cookie_is_accepted' ) ) :
|
185 |
+
/**
|
186 |
+
* Checking accepted cookie values by type
|
187 |
+
*
|
188 |
+
* @param string $type Type.
|
189 |
+
*/
|
190 |
+
function gdpr_cookie_is_accepted( $type = '' ) {
|
191 |
+
$response = false;
|
192 |
+
$type = sanitize_text_field( $type );
|
193 |
+
$accepted_types = array( 'strict', 'thirdparty', 'advanced' );
|
194 |
+
if ( $type && in_array( $type, $accepted_types ) ) :
|
195 |
+
$gdpr_content = new Moove_GDPR_Content();
|
196 |
+
$php_cookies = $gdpr_content->gdpr_get_php_cookies();
|
197 |
+
$response = $php_cookies && isset( $php_cookies[ $type ] ) && $php_cookies[ $type ] ? true : false;
|
198 |
+
endif;
|
199 |
+
return $response;
|
200 |
+
}
|
201 |
+
endif;
|
202 |
+
|
203 |
+
if ( ! function_exists( 'gdpr_get_display_language_by_locale' ) ) :
|
204 |
+
/**
|
205 |
+
* Language locale
|
206 |
+
*
|
207 |
+
* @param string $locale Locale.
|
208 |
+
*/
|
209 |
+
function gdpr_get_display_language_by_locale( $locale ) {
|
210 |
+
$locale_lang = explode( '-', $locale );
|
211 |
+
$_locale = isset( $locale_lang[0] ) ? $locale_lang[0] : $locale;
|
212 |
+
$language_codes = array(
|
213 |
+
'aa' => 'Afar',
|
214 |
+
'ab' => 'Abkhazian',
|
215 |
+
'ae' => 'Avestan',
|
216 |
+
'af' => 'Afrikaans',
|
217 |
+
'ak' => 'Akan',
|
218 |
+
'am' => 'Amharic',
|
219 |
+
'an' => 'Aragonese',
|
220 |
+
'ar' => 'Arabic',
|
221 |
+
'as' => 'Assamese',
|
222 |
+
'av' => 'Avaric',
|
223 |
+
'ay' => 'Aymara',
|
224 |
+
'az' => 'Azerbaijani',
|
225 |
+
'ba' => 'Bashkir',
|
226 |
+
'be' => 'Belarusian',
|
227 |
+
'bg' => 'Bulgarian',
|
228 |
+
'bh' => 'Bihari',
|
229 |
+
'bi' => 'Bislama',
|
230 |
+
'bm' => 'Bambara',
|
231 |
+
'bn' => 'Bengali',
|
232 |
+
'bo' => 'Tibetan',
|
233 |
+
'br' => 'Breton',
|
234 |
+
'bs' => 'Bosnian',
|
235 |
+
'ca' => 'Catalan',
|
236 |
+
'ce' => 'Chechen',
|
237 |
+
'ch' => 'Chamorro',
|
238 |
+
'co' => 'Corsican',
|
239 |
+
'cr' => 'Cree',
|
240 |
+
'cs' => 'Czech',
|
241 |
+
'cu' => 'Church Slavic',
|
242 |
+
'cv' => 'Chuvash',
|
243 |
+
'cy' => 'Welsh',
|
244 |
+
'da' => 'Danish',
|
245 |
+
'de' => 'German',
|
246 |
+
'dv' => 'Divehi',
|
247 |
+
'dz' => 'Dzongkha',
|
248 |
+
'ee' => 'Ewe',
|
249 |
+
'el' => 'Greek',
|
250 |
+
'en' => 'English',
|
251 |
+
'eo' => 'Esperanto',
|
252 |
+
'es' => 'Spanish',
|
253 |
+
'et' => 'Estonian',
|
254 |
+
'eu' => 'Basque',
|
255 |
+
'fa' => 'Persian',
|
256 |
+
'ff' => 'Fulah',
|
257 |
+
'fi' => 'Finnish',
|
258 |
+
'fj' => 'Fijian',
|
259 |
+
'fo' => 'Faroese',
|
260 |
+
'fr' => 'French',
|
261 |
+
'fy' => 'Western Frisian',
|
262 |
+
'ga' => 'Irish',
|
263 |
+
'gd' => 'Scottish Gaelic',
|
264 |
+
'gl' => 'Galician',
|
265 |
+
'gn' => 'Guarani',
|
266 |
+
'gu' => 'Gujarati',
|
267 |
+
'gv' => 'Manx',
|
268 |
+
'ha' => 'Hausa',
|
269 |
+
'he' => 'Hebrew',
|
270 |
+
'hi' => 'Hindi',
|
271 |
+
'ho' => 'Hiri Motu',
|
272 |
+
'hr' => 'Croatian',
|
273 |
+
'ht' => 'Haitian',
|
274 |
+
'hu' => 'Hungarian',
|
275 |
+
'hy' => 'Armenian',
|
276 |
+
'hz' => 'Herero',
|
277 |
+
'ia' => 'Interlingua (International Auxiliary Language Association)',
|
278 |
+
'id' => 'Indonesian',
|
279 |
+
'ie' => 'Interlingue',
|
280 |
+
'ig' => 'Igbo',
|
281 |
+
'ii' => 'Sichuan Yi',
|
282 |
+
'ik' => 'Inupiaq',
|
283 |
+
'io' => 'Ido',
|
284 |
+
'is' => 'Icelandic',
|
285 |
+
'it' => 'Italian',
|
286 |
+
'iu' => 'Inuktitut',
|
287 |
+
'ja' => 'Japanese',
|
288 |
+
'jv' => 'Javanese',
|
289 |
+
'ka' => 'Georgian',
|
290 |
+
'kg' => 'Kongo',
|
291 |
+
'ki' => 'Kikuyu',
|
292 |
+
'kj' => 'Kwanyama',
|
293 |
+
'kk' => 'Kazakh',
|
294 |
+
'kl' => 'Kalaallisut',
|
295 |
+
'km' => 'Khmer',
|
296 |
+
'kn' => 'Kannada',
|
297 |
+
'ko' => 'Korean',
|
298 |
+
'kr' => 'Kanuri',
|
299 |
+
'ks' => 'Kashmiri',
|
300 |
+
'ku' => 'Kurdish',
|
301 |
+
'kv' => 'Komi',
|
302 |
+
'kw' => 'Cornish',
|
303 |
+
'ky' => 'Kirghiz',
|
304 |
+
'la' => 'Latin',
|
305 |
+
'lb' => 'Luxembourgish',
|
306 |
+
'lg' => 'Ganda',
|
307 |
+
'li' => 'Limburgish',
|
308 |
+
'ln' => 'Lingala',
|
309 |
+
'lo' => 'Lao',
|
310 |
+
'lt' => 'Lithuanian',
|
311 |
+
'lu' => 'Luba-Katanga',
|
312 |
+
'lv' => 'Latvian',
|
313 |
+
'mg' => 'Malagasy',
|
314 |
+
'mh' => 'Marshallese',
|
315 |
+
'mi' => 'Maori',
|
316 |
+
'mk' => 'Macedonian',
|
317 |
+
'ml' => 'Malayalam',
|
318 |
+
'mn' => 'Mongolian',
|
319 |
+
'mr' => 'Marathi',
|
320 |
+
'ms' => 'Malay',
|
321 |
+
'mt' => 'Maltese',
|
322 |
+
'my' => 'Burmese',
|
323 |
+
'na' => 'Nauru',
|
324 |
+
'nb' => 'Norwegian Bokmal',
|
325 |
+
'nd' => 'North Ndebele',
|
326 |
+
'ne' => 'Nepali',
|
327 |
+
'ng' => 'Ndonga',
|
328 |
+
'nl' => 'Dutch',
|
329 |
+
'nn' => 'Norwegian Nynorsk',
|
330 |
+
'no' => 'Norwegian',
|
331 |
+
'nr' => 'South Ndebele',
|
332 |
+
'nv' => 'Navajo',
|
333 |
+
'ny' => 'Chichewa',
|
334 |
+
'oc' => 'Occitan',
|
335 |
+
'oj' => 'Ojibwa',
|
336 |
+
'om' => 'Oromo',
|
337 |
+
'or' => 'Oriya',
|
338 |
+
'os' => 'Ossetian',
|
339 |
+
'pa' => 'Panjabi',
|
340 |
+
'pi' => 'Pali',
|
341 |
+
'pl' => 'Polish',
|
342 |
+
'ps' => 'Pashto',
|
343 |
+
'pt' => 'Portuguese',
|
344 |
+
'qu' => 'Quechua',
|
345 |
+
'rm' => 'Raeto-Romance',
|
346 |
+
'rn' => 'Kirundi',
|
347 |
+
'ro' => 'Romanian',
|
348 |
+
'ru' => 'Russian',
|
349 |
+
'rw' => 'Kinyarwanda',
|
350 |
+
'sa' => 'Sanskrit',
|
351 |
+
'sc' => 'Sardinian',
|
352 |
+
'sd' => 'Sindhi',
|
353 |
+
'se' => 'Northern Sami',
|
354 |
+
'sg' => 'Sango',
|
355 |
+
'si' => 'Sinhala',
|
356 |
+
'sk' => 'Slovak',
|
357 |
+
'sl' => 'Slovenian',
|
358 |
+
'sm' => 'Samoan',
|
359 |
+
'sn' => 'Shona',
|
360 |
+
'so' => 'Somali',
|
361 |
+
'sq' => 'Albanian',
|
362 |
+
'sr' => 'Serbian',
|
363 |
+
'ss' => 'Swati',
|
364 |
+
'st' => 'Southern Sotho',
|
365 |
+
'su' => 'Sundanese',
|
366 |
+
'sv' => 'Swedish',
|
367 |
+
'sw' => 'Swahili',
|
368 |
+
'ta' => 'Tamil',
|
369 |
+
'te' => 'Telugu',
|
370 |
+
'tg' => 'Tajik',
|
371 |
+
'th' => 'Thai',
|
372 |
+
'ti' => 'Tigrinya',
|
373 |
+
'tk' => 'Turkmen',
|
374 |
+
'tl' => 'Tagalog',
|
375 |
+
'tn' => 'Tswana',
|
376 |
+
'to' => 'Tonga',
|
377 |
+
'tr' => 'Turkish',
|
378 |
+
'ts' => 'Tsonga',
|
379 |
+
'tt' => 'Tatar',
|
380 |
+
'tw' => 'Twi',
|
381 |
+
'ty' => 'Tahitian',
|
382 |
+
'ug' => 'Uighur',
|
383 |
+
'uk' => 'Ukrainian',
|
384 |
+
'ur' => 'Urdu',
|
385 |
+
'uz' => 'Uzbek',
|
386 |
+
've' => 'Venda',
|
387 |
+
'vi' => 'Vietnamese',
|
388 |
+
'vo' => 'Volapuk',
|
389 |
+
'wa' => 'Walloon',
|
390 |
+
'wo' => 'Wolof',
|
391 |
+
'xh' => 'Xhosa',
|
392 |
+
'yi' => 'Yiddish',
|
393 |
+
'yo' => 'Yoruba',
|
394 |
+
'za' => 'Zhuang',
|
395 |
+
'zh' => 'Chinese',
|
396 |
+
'zu' => 'Zulu',
|
397 |
+
);
|
398 |
+
return isset( $language_codes[ $_locale ] ) ? $language_codes[ $_locale ] . ' [' . $locale . ']' : $locale;
|
399 |
+
}
|
400 |
+
endif;
|
gdpr-modules/branding-styles.php
CHANGED
@@ -1,13 +1,13 @@
|
|
1 |
<style>
|
2 |
-
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
</style>
|
1 |
<style>
|
2 |
+
<?php
|
3 |
+
$primary_colour = $content->primary_colour;
|
4 |
+
$secondary_colour = $content->secondary_colour;
|
5 |
+
$button_bg = $content->button_bg;
|
6 |
+
$button_hover_bg = $content->button_hover_bg;
|
7 |
+
$button_font = $content->button_font;
|
8 |
+
$font_family = $content->font_family;
|
9 |
|
10 |
+
$moove_gdpr_cnt = new Moove_GDPR_Controller();
|
11 |
+
echo $moove_gdpr_cnt->get_minified_styles( $primary_colour, $secondary_colour, $button_bg, $button_hover_bg, $button_font, $font_family );
|
12 |
+
?>
|
13 |
</style>
|
gdpr-modules/modal/company-logo.php
CHANGED
@@ -1,4 +1,4 @@
|
|
1 |
<div class="moove-gdpr-company-logo-holder">
|
2 |
-
<img src="<?php echo $content->logo_url; ?>" alt="<?php echo $content->logo_alt; ?>" class="img-responsive" />
|
3 |
</div>
|
4 |
<!-- .moove-gdpr-company-logo-holder -->
|
1 |
<div class="moove-gdpr-company-logo-holder">
|
2 |
+
<img src="<?php echo esc_url( $content->logo_url ); ?>" alt="<?php echo esc_attr( $content->logo_alt ); ?>" class="img-responsive" />
|
3 |
</div>
|
4 |
<!-- .moove-gdpr-company-logo-holder -->
|
gdpr-modules/modal/modal-base-onepage.php
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
<!-- V2 -->
|
2 |
<div id="moove_gdpr_cookie_modal" class="lity-hide">
|
3 |
-
<div class="moove-gdpr-modal-content moove-clearfix logo-position-<?php echo $content->logo_position; ?> <?php echo $content->theme; ?>">
|
4 |
<a href="#" class="moove-gdpr-modal-close" rel="nofollow"><span class="gdpr-icon moovegdpr-arrow-close"></span></a>
|
5 |
<div class="moove-gdpr-modal-left-content">
|
6 |
<ul id="moove-gdpr-menu">
|
1 |
<!-- V2 -->
|
2 |
<div id="moove_gdpr_cookie_modal" class="lity-hide">
|
3 |
+
<div class="moove-gdpr-modal-content moove-clearfix logo-position-<?php echo esc_attr( $content->logo_position ); ?> <?php echo esc_attr( $content->theme ); ?>">
|
4 |
<a href="#" class="moove-gdpr-modal-close" rel="nofollow"><span class="gdpr-icon moovegdpr-arrow-close"></span></a>
|
5 |
<div class="moove-gdpr-modal-left-content">
|
6 |
<ul id="moove-gdpr-menu">
|
gdpr-modules/modal/modal-base-tabs.php
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
<!-- V1 -->
|
2 |
<div id="moove_gdpr_cookie_modal" class="lity-hide">
|
3 |
-
<div class="moove-gdpr-modal-content moove-clearfix logo-position-<?php echo $content->logo_position; ?> <?php echo $content->theme; ?>">
|
4 |
<a href="#" class="moove-gdpr-modal-close" rel="nofollow"><span class="gdpr-icon moovegdpr-arrow-close"></span></a>
|
5 |
<div class="moove-gdpr-modal-left-content">
|
6 |
<?php echo gdpr_get_module('company-logo'); ?>
|
1 |
<!-- V1 -->
|
2 |
<div id="moove_gdpr_cookie_modal" class="lity-hide">
|
3 |
+
<div class="moove-gdpr-modal-content moove-clearfix logo-position-<?php echo esc_attr( $content->logo_position ); ?> <?php echo esc_attr( $content->theme ); ?>">
|
4 |
<a href="#" class="moove-gdpr-modal-close" rel="nofollow"><span class="gdpr-icon moovegdpr-arrow-close"></span></a>
|
5 |
<div class="moove-gdpr-modal-left-content">
|
6 |
<?php echo gdpr_get_module('company-logo'); ?>
|
gdpr-modules/modal/tab-footer-buttons.php
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
<div class="moove-gdpr-button-holder">
|
2 |
-
<button class="mgbutton moove-gdpr-modal-allow-all button-visible"><?php echo $content->allow_label; ?></button>
|
3 |
-
<button class="mgbutton moove-gdpr-modal-save-settings button-visible"><?php echo $content->settings_label; ?></button>
|
4 |
</div>
|
5 |
<!-- .moove-gdpr-button-holder -->
|
1 |
<div class="moove-gdpr-button-holder">
|
2 |
+
<button class="mgbutton moove-gdpr-modal-allow-all button-visible"><?php echo esc_attr( $content->allow_label ); ?></button>
|
3 |
+
<button class="mgbutton moove-gdpr-modal-save-settings button-visible"><?php echo esc_attr( $content->settings_label ); ?></button>
|
4 |
</div>
|
5 |
<!-- .moove-gdpr-button-holder -->
|
gdpr-modules/modal/tab-navigation.php
CHANGED
@@ -1,28 +1,28 @@
|
|
1 |
<li class="menu-item-on menu-item-privacy_overview menu-item-selected">
|
2 |
-
<button data-href="#privacy_overview" class="moove-gdpr-tab-nav"><span class="gdpr-icon moovegdpr-privacy-overview"></span> <span class="gdpr-nav-tab-title"><?php echo $content->overview->nav_label; ?></span></button>
|
3 |
</li>
|
4 |
|
5 |
<?php if ( $content->strictly->show ) : ?>
|
6 |
<li class="menu-item-strict-necessary-cookies menu-item-off">
|
7 |
-
<button data-href="#strict-necessary-cookies" class="moove-gdpr-tab-nav"><span class="gdpr-icon moovegdpr-strict-necessary"></span> <span class="gdpr-nav-tab-title"><?php echo $content->strictly->nav_label; ?></span></button>
|
8 |
</li>
|
9 |
<?php endif; ?>
|
10 |
|
11 |
|
12 |
<?php if ( $content->third_party->show ) : ?>
|
13 |
<li class="menu-item-off menu-item-third_party_cookies">
|
14 |
-
<button data-href="#third_party_cookies" class="moove-gdpr-tab-nav"><span class="gdpr-icon moovegdpr-3rd-party"></span> <span class="gdpr-nav-tab-title"><?php echo $content->third_party->nav_label; ?></span></button>
|
15 |
</li>
|
16 |
<?php endif; ?>
|
17 |
|
18 |
<?php if ( $content->advanced->show ) : ?>
|
19 |
<li class="menu-item-advanced-cookies menu-item-off">
|
20 |
-
<button data-href="#advanced-cookies" class="moove-gdpr-tab-nav"><span class="gdpr-icon moovegdpr-advanced"></span> <span class="gdpr-nav-tab-title"><?php echo $content->advanced->nav_label; ?></span></button>
|
21 |
</li>
|
22 |
<?php endif; ?>
|
23 |
|
24 |
<?php if ( $content->cookiepolicy->show ) : ?>
|
25 |
<li class="menu-item-moreinfo menu-item-off">
|
26 |
-
<button data-href="#cookie_policy_modal" class="moove-gdpr-tab-nav"><span class="gdpr-icon moovegdpr-policy"></span> <span class="gdpr-nav-tab-title"><?php echo $content->cookiepolicy->nav_label; ?></span></button>
|
27 |
</li>
|
28 |
<?php endif; ?>
|
1 |
<li class="menu-item-on menu-item-privacy_overview menu-item-selected">
|
2 |
+
<button data-href="#privacy_overview" class="moove-gdpr-tab-nav"><span class="gdpr-icon moovegdpr-privacy-overview"></span> <span class="gdpr-nav-tab-title"><?php echo esc_attr( $content->overview->nav_label ); ?></span></button>
|
3 |
</li>
|
4 |
|
5 |
<?php if ( $content->strictly->show ) : ?>
|
6 |
<li class="menu-item-strict-necessary-cookies menu-item-off">
|
7 |
+
<button data-href="#strict-necessary-cookies" class="moove-gdpr-tab-nav"><span class="gdpr-icon moovegdpr-strict-necessary"></span> <span class="gdpr-nav-tab-title"><?php echo esc_attr( $content->strictly->nav_label ); ?></span></button>
|
8 |
</li>
|
9 |
<?php endif; ?>
|
10 |
|
11 |
|
12 |
<?php if ( $content->third_party->show ) : ?>
|
13 |
<li class="menu-item-off menu-item-third_party_cookies">
|
14 |
+
<button data-href="#third_party_cookies" class="moove-gdpr-tab-nav"><span class="gdpr-icon moovegdpr-3rd-party"></span> <span class="gdpr-nav-tab-title"><?php echo esc_attr( $content->third_party->nav_label ); ?></span></button>
|
15 |
</li>
|
16 |
<?php endif; ?>
|
17 |
|
18 |
<?php if ( $content->advanced->show ) : ?>
|
19 |
<li class="menu-item-advanced-cookies menu-item-off">
|
20 |
+
<button data-href="#advanced-cookies" class="moove-gdpr-tab-nav"><span class="gdpr-icon moovegdpr-advanced"></span> <span class="gdpr-nav-tab-title"><?php echo esc_attr( $content->advanced->nav_label ); ?></span></button>
|
21 |
</li>
|
22 |
<?php endif; ?>
|
23 |
|
24 |
<?php if ( $content->cookiepolicy->show ) : ?>
|
25 |
<li class="menu-item-moreinfo menu-item-off">
|
26 |
+
<button data-href="#cookie_policy_modal" class="moove-gdpr-tab-nav"><span class="gdpr-icon moovegdpr-policy"></span> <span class="gdpr-nav-tab-title"><?php echo esc_attr( $content->cookiepolicy->nav_label ); ?></span></button>
|
27 |
</li>
|
28 |
<?php endif; ?>
|
moove-content.php
DELETED
@@ -1,442 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
3 |
-
|
4 |
-
/**
|
5 |
-
* Moove_GDPR_Content File Doc Comment
|
6 |
-
*
|
7 |
-
* @category Moove_GDPR_Content
|
8 |
-
* @package gdpr-cookie-compliance
|
9 |
-
* @author Gaspar Nemes
|
10 |
-
*/
|
11 |
-
|
12 |
-
/**
|
13 |
-
* Moove_GDPR_Content Class Doc Comment
|
14 |
-
*
|
15 |
-
* @category Class
|
16 |
-
* @package Moove_Controller
|
17 |
-
* @author Gaspar Nemes
|
18 |
-
*/
|
19 |
-
class Moove_GDPR_Content {
|
20 |
-
|
21 |
-
/**
|
22 |
-
* Construct
|
23 |
-
*/
|
24 |
-
function __construct() {
|
25 |
-
|
26 |
-
}
|
27 |
-
|
28 |
-
/**
|
29 |
-
* Privacy Overview Tab Content
|
30 |
-
*
|
31 |
-
* @return string Filtered Content
|
32 |
-
*/
|
33 |
-
public function moove_gdpr_get_privacy_overview_content() {
|
34 |
-
$_content = '<p>' . __( 'This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.','gdpr-cookie-compliance' ) . '</p>';
|
35 |
-
return $_content;
|
36 |
-
}
|
37 |
-
|
38 |
-
public static function moove_gdpr_get_localize_scripts() {
|
39 |
-
$loc_data = array();
|
40 |
-
$gdpr_loc_data = apply_filters( 'gdpr_extend_loc_data', $loc_data );
|
41 |
-
return $gdpr_loc_data;
|
42 |
-
}
|
43 |
-
|
44 |
-
/**
|
45 |
-
* Strict Necessary Tab Content
|
46 |
-
*
|
47 |
-
* @return string Filtered Content
|
48 |
-
*/
|
49 |
-
public function moove_gdpr_get_strict_necessary_content() {
|
50 |
-
$_content = '<p>' . __( 'Strictly Necessary Cookie should be enabled at all times so that we can save your preferences for cookie settings.','gdpr-cookie-compliance' ) . '</p>';
|
51 |
-
return $_content;
|
52 |
-
}
|
53 |
-
|
54 |
-
/**
|
55 |
-
* Strict Necessary Warning Message
|
56 |
-
*
|
57 |
-
* @return string Filtered Content
|
58 |
-
*/
|
59 |
-
public function moove_gdpr_get_strict_necessary_warning() {
|
60 |
-
$_content = '';
|
61 |
-
$options_name = $this->moove_gdpr_get_option_name();
|
62 |
-
$gdpr_options = get_option( $options_name );
|
63 |
-
$wpml_lang_options = $this->moove_gdpr_get_wpml_lang();
|
64 |
-
|
65 |
-
if ( ! isset( $gdpr_options[ 'moove_gdpr_strictly_necessary_cookies_warning'. $wpml_lang_options ] ) ) :
|
66 |
-
$_content = __( 'If you disable this cookie, we will not be able to save your preferences. This means that every time you visit this website you will need to enable or disable cookies again.','gdpr-cookie-compliance' );
|
67 |
-
endif;
|
68 |
-
return $_content;
|
69 |
-
}
|
70 |
-
|
71 |
-
/**
|
72 |
-
* Advanced Cookies Tab Content
|
73 |
-
*
|
74 |
-
* @return string Filtered Content
|
75 |
-
*/
|
76 |
-
public function moove_gdpr_get_advanced_cookies_content() {
|
77 |
-
$_content = '<p>' . __( 'This website uses the following additional cookies:</p><p>(List the cookies that you are using on the website here.)','gdpr-cookie-compliance' ) . '</p>';
|
78 |
-
return $_content;
|
79 |
-
}
|
80 |
-
|
81 |
-
/**
|
82 |
-
* Third Party Cookies Tab Content
|
83 |
-
*
|
84 |
-
* @return string Filtered Content
|
85 |
-
*/
|
86 |
-
public function moove_gdpr_get_third_party_content() {
|
87 |
-
$_content = '<p>' . __( 'This website uses Google Analytics to collect anonymous information such as the number of visitors to the site, and the most popular pages.','gdpr-cookie-compliance');
|
88 |
-
$_content .= '<p>' . __('Keeping this cookie enabled helps us to improve our website.','gdpr-cookie-compliance' ) . '</p>';
|
89 |
-
return $_content;
|
90 |
-
}
|
91 |
-
|
92 |
-
/**
|
93 |
-
* Cookie Policy Tab Content
|
94 |
-
*
|
95 |
-
* @return string Filtered Content
|
96 |
-
*/
|
97 |
-
public function moove_gdpr_get_cookie_policy_content() {
|
98 |
-
$privacy_policy_page = get_option( 'wp_page_for_privacy_policy' );
|
99 |
-
$privacy_policy_link = $privacy_policy_page ? esc_url( get_permalink( $privacy_policy_page ) ) : false;
|
100 |
-
$privacy_policy_link = $privacy_policy_link ? $privacy_policy_link : '#';
|
101 |
-
$_content = '<p>' . sprintf( __( 'More information about our <a href="%s" target="_blank">Cookie Policy</a>', 'gdpr-cookie-compliance' ), $privacy_policy_link ) . '</p>';
|
102 |
-
return $_content;
|
103 |
-
}
|
104 |
-
|
105 |
-
/**
|
106 |
-
* Cookie Policy Tab Content
|
107 |
-
*
|
108 |
-
* @return string Filtered Content
|
109 |
-
*/
|
110 |
-
public function moove_gdpr_ifb_content() {
|
111 |
-
$_content = '<h2>' . __( 'Sorry,<br /> the content is blocked!','gdpr-cookie-compliance');
|
112 |
-
$_content .= '<p>' . __('To unlock, please enable the cookies!','gdpr-cookie-compliance');
|
113 |
-
$_content .= '<br><br>';
|
114 |
-
$_content .= __('[accept]Accept[/accept] [setting]Adjust your settings[/setting]','gdpr-cookie-compliance' );
|
115 |
-
return $_content;
|
116 |
-
}
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
/**
|
121 |
-
* Get option name
|
122 |
-
*/
|
123 |
-
public function moove_gdpr_get_option_name() {
|
124 |
-
return 'moove_gdpr_plugin_settings';
|
125 |
-
}
|
126 |
-
|
127 |
-
public function moove_gdpr_get_key_name() {
|
128 |
-
return 'moove_gdpr_plugin_key';
|
129 |
-
}
|
130 |
-
|
131 |
-
/**
|
132 |
-
* Get strict secondary notice
|
133 |
-
*/
|
134 |
-
public function moove_gdpr_get_secondary_notice() {
|
135 |
-
$_content = '';
|
136 |
-
$options_name = $this->moove_gdpr_get_option_name();
|
137 |
-
$gdpr_options = get_option( $options_name );
|
138 |
-
$wpml_lang_options = $this->moove_gdpr_get_wpml_lang();
|
139 |
-
if ( ! isset( $gdpr_options[ 'moove_gdpr_modal_strictly_secondary_notice'. $wpml_lang_options ] ) ) :
|
140 |
-
$_content = __( 'Please enable Strictly Necessary Cookies first so that we can save your preferences!','gdpr-cookie-compliance' );
|
141 |
-
endif;
|
142 |
-
return $_content;
|
143 |
-
}
|
144 |
-
|
145 |
-
/**
|
146 |
-
* Get WMPL language code
|
147 |
-
*/
|
148 |
-
public function moove_gdpr_get_wpml_lang() {
|
149 |
-
if ( defined( 'ICL_LANGUAGE_CODE' ) ) {
|
150 |
-
$language_code = ICL_LANGUAGE_CODE;
|
151 |
-
if ( ICL_LANGUAGE_CODE === 'all' ) :
|
152 |
-
if ( function_exists('pll_default_language') ) :
|
153 |
-
$language_code = pll_default_language();
|
154 |
-
elseif ( class_exists('SitePress') ) :
|
155 |
-
global $sitepress;
|
156 |
-
$language_code = $sitepress->get_default_language();
|
157 |
-
endif;
|
158 |
-
endif;
|
159 |
-
return '_'.$language_code;
|
160 |
-
} elseif ( isset( $GLOBALS['q_config']['language'] ) ) {
|
161 |
-
return $GLOBALS['q_config']['language'];
|
162 |
-
} elseif ( function_exists( 'wpm_get_user_language' ) ) {
|
163 |
-
return wpm_get_user_language();
|
164 |
-
}
|
165 |
-
return '';
|
166 |
-
}
|
167 |
-
|
168 |
-
public function get_license_token() {
|
169 |
-
$license_token = function_exists('network_site_url') ? network_site_url('/') : home_url('/');
|
170 |
-
return $license_token;
|
171 |
-
}
|
172 |
-
|
173 |
-
/**
|
174 |
-
* PHP Cookie Checker, available from version 1.3.0
|
175 |
-
*/
|
176 |
-
public function gdpr_get_php_cookies() {
|
177 |
-
$cookies_accepted = array(
|
178 |
-
'strict' => false,
|
179 |
-
'thirdparty' => false,
|
180 |
-
'advanced' => false
|
181 |
-
);
|
182 |
-
if( isset( $_COOKIE['moove_gdpr_popup'] ) ) :
|
183 |
-
$cookies = $_COOKIE['moove_gdpr_popup'];
|
184 |
-
$cookies_decoded = json_decode( wp_unslash( $cookies ), true );
|
185 |
-
if ( $cookies_decoded && is_array( $cookies_decoded ) && ! empty( $cookies_decoded ) ) :
|
186 |
-
$cookies_accepted = array(
|
187 |
-
'strict' => isset( $cookies_decoded['strict'] ) && intval( $cookies_decoded['strict'] ) === 1 ? true : false,
|
188 |
-
'thirdparty' => isset( $cookies_decoded['thirdparty'] ) && intval( $cookies_decoded['thirdparty'] ) === 1 ? true : false,
|
189 |
-
'advanced' => isset( $cookies_decoded['advanced'] ) && intval( $cookies_decoded['advanced'] ) === 1 ? true : false,
|
190 |
-
);
|
191 |
-
endif;
|
192 |
-
else :
|
193 |
-
$options_name = $this->moove_gdpr_get_option_name();
|
194 |
-
$gdpr_options = get_option( $options_name );
|
195 |
-
$wpml_lang_options = $this->moove_gdpr_get_wpml_lang();
|
196 |
-
|
197 |
-
$strictly_functionality = isset( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? intval( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) : 1;
|
198 |
-
$thirdparty_default = isset( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) && intval( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) ? intval( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) : 0;
|
199 |
-
$advanced_default = isset( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) && intval( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) ? intval( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) : 0;
|
200 |
-
|
201 |
-
if ( $strictly_functionality === 1 ) :
|
202 |
-
if ( $thirdparty_default === 1 || $advanced_default === 1 ) :
|
203 |
-
$strict_default = 1;
|
204 |
-
else :
|
205 |
-
$strict_default = 0;
|
206 |
-
endif;
|
207 |
-
else :
|
208 |
-
$strict_default = 1;
|
209 |
-
endif;
|
210 |
-
|
211 |
-
$cookies_accepted = array(
|
212 |
-
'strict' => $strict_default,
|
213 |
-
'thirdparty' => $thirdparty_default,
|
214 |
-
'advanced' => $advanced_default
|
215 |
-
);
|
216 |
-
|
217 |
-
|
218 |
-
endif;
|
219 |
-
return $cookies_accepted;
|
220 |
-
}
|
221 |
-
|
222 |
-
public static function gdpr_licence_action_button( $response, $gdpr_key ) {
|
223 |
-
$type = isset( $response['type'] ) ? $response['type'] : false;
|
224 |
-
if ( $type === 'expired' || $type === 'activated' || $type === 'max_activation_reached' ) : ?>
|
225 |
-
<button type="submit" name="gdpr_activate_license" class="button button-primary button-inverse">
|
226 |
-
<?php _e('Activate','gdpr-cookie-compliance'); ?>
|
227 |
-
</button>
|
228 |
-
<?php
|
229 |
-
elseif ( $type === 'invalid' ) :
|
230 |
-
?>
|
231 |
-
<button type="submit" name="gdpr_activate_license" class="button button-primary button-inverse">
|
232 |
-
<?php _e('Activate','gdpr-cookie-compliance'); ?>
|
233 |
-
</button>
|
234 |
-
<?php
|
235 |
-
else :
|
236 |
-
?>
|
237 |
-
<button type="submit" name="gdpr_activate_license" class="button button-primary button-inverse">
|
238 |
-
<?php _e('Activate','gdpr-cookie-compliance'); ?>
|
239 |
-
</button>
|
240 |
-
<br /><br />
|
241 |
-
<hr />
|
242 |
-
<h4 style="margin-bottom: 0;"><?php _e('Buy licence','gdpr-cookie-compliance'); ?></h4>
|
243 |
-
<p>
|
244 |
-
<?php
|
245 |
-
$store_link = __('You can buy licences from our [store_link]online store[/store_link].','gdpr-cookie-compliance');
|
246 |
-
$store_link = str_replace('[store_link]', '<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="gdpr_admin_link">', $store_link );
|
247 |
-
$store_link = str_replace('[/store_link]', '</a>', $store_link );
|
248 |
-
echo $store_link;
|
249 |
-
?>
|
250 |
-
</p>
|
251 |
-
<p>
|
252 |
-
<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="button button-primary">Buy Now</a>
|
253 |
-
</p>
|
254 |
-
<br />
|
255 |
-
<hr />
|
256 |
-
|
257 |
-
<?php
|
258 |
-
endif;
|
259 |
-
}
|
260 |
-
|
261 |
-
public static function gdpr_licence_input_field( $response, $gdpr_key ) {
|
262 |
-
$type = isset( $response['type'] ) ? $response['type'] : false;
|
263 |
-
if ( $type === 'expired' ) :
|
264 |
-
// LICENSE EXPIRED
|
265 |
-
?>
|
266 |
-
<tr>
|
267 |
-
<th scope="row" style="padding: 0 0 10px 0;">
|
268 |
-
<hr />
|
269 |
-
<h4 style="margin-bottom: 0;"><?php _e('Renew your licence','gdpr-cookie-compliance'); ?></h4>
|
270 |
-
<p><?php _e('Your licence has expired. You will not receive the latest updates and features unless you renew your licence.','gdpr-cookie-compliance'); ?></p>
|
271 |
-
<a href="<?php echo MOOVE_SHOP_URL; ?>?renew=<?php echo $response['key']; ?>" class="button button-primary">Renew Licence</a>
|
272 |
-
<br /><br />
|
273 |
-
<hr />
|
274 |
-
|
275 |
-
<h4 style="margin-bottom: 0;"><?php _e('Enter new licence key','gdpr-cookie-compliance'); ?></h4>
|
276 |
-
</th>
|
277 |
-
</tr>
|
278 |
-
|
279 |
-
<tr>
|
280 |
-
<td style="padding: 0;">
|
281 |
-
<input name="moove_gdpr_license_key" required min="35" type="text" id="moove_gdpr_license_key" value="" class="regular-text">
|
282 |
-
</td>
|
283 |
-
</tr>
|
284 |
-
<?php
|
285 |
-
elseif ( $type === 'activated' || $type === 'max_activation_reached' ) :
|
286 |
-
// LICENSE ACTIVATED
|
287 |
-
?>
|
288 |
-
<tr>
|
289 |
-
<th scope="row" style="padding: 0 0 10px 0;">
|
290 |
-
<hr />
|
291 |
-
<h4 style="margin-bottom: 0;"><?php _e('Buy more licences','gdpr-cookie-compliance'); ?></h4>
|
292 |
-
<p>
|
293 |
-
<?php
|
294 |
-
$store_link = __('You can buy more licences from our [store_link]online store[/store_link].','gdpr-cookie-compliance');
|
295 |
-
$store_link = str_replace('[store_link]', '<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="gdpr_admin_link">', $store_link );
|
296 |
-
$store_link = str_replace('[/store_link]', '</a>', $store_link );
|
297 |
-
echo $store_link;
|
298 |
-
?>
|
299 |
-
</p>
|
300 |
-
<p>
|
301 |
-
<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="button button-primary">Buy Now</a>
|
302 |
-
</p>
|
303 |
-
<br />
|
304 |
-
<hr />
|
305 |
-
|
306 |
-
<h4 style="margin-bottom: 0;"><?php _e('Enter new licence key','gdpr-cookie-compliance'); ?></h4>
|
307 |
-
</th>
|
308 |
-
</tr>
|
309 |
-
|
310 |
-
<tr>
|
311 |
-
<td style="padding: 0;">
|
312 |
-
<input name="moove_gdpr_license_key" required min="35" type="text" id="moove_gdpr_license_key" value="" class="regular-text">
|
313 |
-
</td>
|
314 |
-
</tr>
|
315 |
-
<?php
|
316 |
-
elseif ( $type === 'invalid' ) :
|
317 |
-
?>
|
318 |
-
<tr>
|
319 |
-
<th scope="row" style="padding: 0 0 10px 0;">
|
320 |
-
<hr />
|
321 |
-
<h4 style="margin-bottom: 0;"><?php _e('Buy licence','gdpr-cookie-compliance'); ?></h4>
|
322 |
-
<p>
|
323 |
-
<?php
|
324 |
-
$store_link = __('You can buy licences from our [store_link]online store[/store_link].','gdpr-cookie-compliance');
|
325 |
-
$store_link = str_replace('[store_link]', '<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="gdpr_admin_link">', $store_link );
|
326 |
-
$store_link = str_replace('[/store_link]', '</a>', $store_link );
|
327 |
-
echo $store_link;
|
328 |
-
?>
|
329 |
-
</p>
|
330 |
-
<p>
|
331 |
-
<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="button button-primary">Buy Now</a>
|
332 |
-
</p>
|
333 |
-
<br />
|
334 |
-
<hr />
|
335 |
-
</th>
|
336 |
-
</tr>
|
337 |
-
<tr>
|
338 |
-
<th scope="row" style="padding: 0 0 10px 0;">
|
339 |
-
<label><?php _e('Enter your licence key:','gdpr-cookie-compliance'); ?></label>
|
340 |
-
</th>
|
341 |
-
</tr>
|
342 |
-
|
343 |
-
<tr>
|
344 |
-
<td style="padding: 0;">
|
345 |
-
<input name="moove_gdpr_license_key" required min="35" type="text" id="moove_gdpr_license_key" value="" class="regular-text">
|
346 |
-
</td>
|
347 |
-
</tr>
|
348 |
-
<?php
|
349 |
-
else :
|
350 |
-
?>
|
351 |
-
|
352 |
-
<tr>
|
353 |
-
<th scope="row" style="padding: 0 0 10px 0;">
|
354 |
-
<label><?php _e('Enter licence key:','gdpr-cookie-compliance'); ?></label>
|
355 |
-
</th>
|
356 |
-
</tr>
|
357 |
-
|
358 |
-
<tr>
|
359 |
-
<td style="padding: 0;">
|
360 |
-
<input name="moove_gdpr_license_key" required min="35" type="text" id="moove_gdpr_license_key" value="" class="regular-text">
|
361 |
-
</td>
|
362 |
-
</tr>
|
363 |
-
|
364 |
-
|
365 |
-
<?php
|
366 |
-
endif;
|
367 |
-
}
|
368 |
-
|
369 |
-
public static function gdpr_get_alertbox( $type, $response, $gdpr_key ) {
|
370 |
-
if ( $type === 'error' ) :
|
371 |
-
$messages = isset( $response['message'] ) && is_array( $response['message'] ) ? implode( '</p><p>', $response['message'] ) : '';
|
372 |
-
?>
|
373 |
-
<div class="gdpr-admin-alert gdpr-admin-alert-error">
|
374 |
-
<div class="gdpr-alert-content">
|
375 |
-
<p>License key: <strong><?php echo isset( $response['key'] ) ? $response['key'] : $gdpr_key['key'] ; ?></strong></p>
|
376 |
-
<p><?php echo $messages; ?></p>
|
377 |
-
</div>
|
378 |
-
<span class="dashicons dashicons-dismiss"></span>
|
379 |
-
</div>
|
380 |
-
<!-- .gdpr-admin-alert gdpr-admin-alert-success -->
|
381 |
-
<?php
|
382 |
-
else :
|
383 |
-
$messages = isset( $response['message'] ) && is_array( $response['message'] ) ? implode( '</p><p>', $response['message'] ) : '';
|
384 |
-
?>
|
385 |
-
<div class="gdpr-admin-alert gdpr-admin-alert-success">
|
386 |
-
<div class="gdpr-alert-content">
|
387 |
-
<p>License key: <strong><?php echo isset( $response['key'] ) ? $response['key'] : $gdpr_key['key'] ; ?></strong></p>
|
388 |
-
<p><?php echo $messages; ?></p>
|
389 |
-
</div>
|
390 |
-
<span class="dashicons dashicons-yes-alt"></span>
|
391 |
-
</div>
|
392 |
-
<!-- .gdpr-admin-alert gdpr-admin-alert-success -->
|
393 |
-
<?php
|
394 |
-
endif;
|
395 |
-
do_action('gdpr_plugin_updater_notice');
|
396 |
-
}
|
397 |
-
|
398 |
-
public static function gdpr_premium_update_alert() {
|
399 |
-
|
400 |
-
$plugins = get_site_transient( 'update_plugins' );
|
401 |
-
$lm = new Moove_GDPR_License_Manager();
|
402 |
-
$plugin_slug = $lm->get_add_on_plugin_slug();
|
403 |
-
|
404 |
-
if ( isset( $plugins->response[$plugin_slug] ) && is_plugin_active( $plugin_slug ) ) :
|
405 |
-
$version = $plugins->response[$plugin_slug]->new_version;
|
406 |
-
|
407 |
-
$current_user = wp_get_current_user();
|
408 |
-
$user_id = isset( $current_user->ID ) ? $current_user->ID : 0;
|
409 |
-
$dismiss = get_option( 'gdpr_hide_update_notice_' . $user_id );
|
410 |
-
|
411 |
-
|
412 |
-
if ( isset( $plugins->response[$plugin_slug]->package ) && ! $plugins->response[$plugin_slug]->package ) :
|
413 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
414 |
-
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
415 |
-
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
416 |
-
$license_key = isset( $gdpr_key['key'] ) ? sanitize_text_field( $gdpr_key['key'] ) : false;
|
417 |
-
$renew_link = MOOVE_SHOP_URL . '?renew='.$license_key;
|
418 |
-
$license_manager = admin_url('admin.php') . '?page=moove-gdpr&tab=licence';
|
419 |
-
$purchase_link = 'https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/';
|
420 |
-
$notice_text = '';
|
421 |
-
if ( $license_key && isset( $gdpr_key['activation'] ) ) :
|
422 |
-
// Expired
|
423 |
-
$notice_text = 'Update is not available until you <a href="'.$renew_link.'" target="_blank">renew your licence</a>. You can also update your licence key in the <a href="'.$license_manager.'">Licence Manager</a>.';
|
424 |
-
elseif ( $license_key && isset( $gdpr_key['deactivation'] ) ) :
|
425 |
-
// Deactivated
|
426 |
-
$notice_text = 'Update is not available until you <a href="'.$purchase_link.'" target="_blank">purchase a licence</a>. You can also update your licence key in the <a href="'.$license_manager.'">Licence Manager</a>.';
|
427 |
-
elseif ( ! $license_key ) :
|
428 |
-
// No license key installed
|
429 |
-
$notice_text = 'Update is not available until you <a href="'.$purchase_link.'" target="_blank">purchase a licence</a>. You can also update your licence key in the <a href="'.$license_manager.'">Licence Manager</a>.';
|
430 |
-
endif;
|
431 |
-
?>
|
432 |
-
<div class="gdpr-cookie-alert gdpr-cookie-update-alert" style="display: inline-block;">
|
433 |
-
<h4><?php _e('There is a new version of GDPR Cookie Compliance - Premium Add-On.','gdpr-cookie-compliance'); ?></h4>
|
434 |
-
<p><?php echo $notice_text; ?></p>
|
435 |
-
</div>
|
436 |
-
<!-- .gdpr-cookie-alert -->
|
437 |
-
<?php
|
438 |
-
endif;
|
439 |
-
endif;
|
440 |
-
}
|
441 |
-
}
|
442 |
-
new Moove_GDPR_Content();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
moove-controller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) { exit; }
|
3 |
-
/**
|
4 |
-
* Registering CONTROLLERS
|
5 |
-
*/
|
6 |
-
require_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'controllers' . DIRECTORY_SEPARATOR . 'moove-controller.php';
|
7 |
-
require_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'controllers' . DIRECTORY_SEPARATOR . 'moove-license-manager.php';
|
8 |
-
require_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'controllers' . DIRECTORY_SEPARATOR . 'moove-plugin-updater.php';
|
9 |
-
?>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
moove-functions.php
DELETED
@@ -1,381 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
3 |
-
|
4 |
-
/**
|
5 |
-
* Moove_Functions File Doc Comment
|
6 |
-
*
|
7 |
-
* @category Moove_Functions
|
8 |
-
* @package gdpr-cookie-compliance
|
9 |
-
* @author Gaspar Nemes
|
10 |
-
*/
|
11 |
-
|
12 |
-
/**
|
13 |
-
* Relative path of the GDPR cookie plugin
|
14 |
-
*/
|
15 |
-
function moove_gdpr_get_plugin_directory_url() {
|
16 |
-
return plugin_dir_url( __FILE__ );
|
17 |
-
}
|
18 |
-
|
19 |
-
/**
|
20 |
-
* Extension to display support, premium and settings links in the plugin listing page
|
21 |
-
*/
|
22 |
-
add_filter( 'plugin_action_links', 'moove_gdpr_plugin_settings_link', 10, 2 );
|
23 |
-
function moove_gdpr_plugin_settings_link( $links, $file ) {
|
24 |
-
if ( plugin_basename( dirname( __FILE__ ) . '/moove-gdpr.php' ) === $file ) {
|
25 |
-
/*
|
26 |
-
* Insert the Settings page link at the beginning
|
27 |
-
*/
|
28 |
-
$in = '<a href="?page=moove-gdpr">' . __( 'Settings','gdpr-cookie-compliance' ) . '</a>';
|
29 |
-
array_unshift( $links, $in );
|
30 |
-
|
31 |
-
/*
|
32 |
-
* Insert the Support page link at the end
|
33 |
-
*/
|
34 |
-
$in = '<a href="https://support.mooveagency.com/forum/gdpr-cookie-compliance/" target="_blank">' . __( 'Support','gdpr-cookie-compliance' ) . '</a>';
|
35 |
-
array_push( $links, $in );
|
36 |
-
/*
|
37 |
-
* Insert the Premium Upgrade link at the end
|
38 |
-
*/
|
39 |
-
$in = '<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank">' . __( 'Premium Upgrade','gdpr-cookie-compliance' ) . '</a>';
|
40 |
-
array_push( $links, $in );
|
41 |
-
}
|
42 |
-
return $links;
|
43 |
-
}
|
44 |
-
|
45 |
-
/**
|
46 |
-
* Get an attachment ID given a URL.
|
47 |
-
*
|
48 |
-
* @param string $url
|
49 |
-
*
|
50 |
-
* @return int Attachment ID on success, 0 on failure
|
51 |
-
*/
|
52 |
-
function gdpr_get_attachment_id( $url ) {
|
53 |
-
$attachment_id = 0;
|
54 |
-
$dir = wp_upload_dir();
|
55 |
-
if ( false !== strpos( $url, $dir['baseurl'] . '/' ) ) { // Is URL in uploads directory?
|
56 |
-
$file = basename( $url );
|
57 |
-
$query_args = array(
|
58 |
-
'post_type' => 'attachment',
|
59 |
-
'post_status' => 'inherit',
|
60 |
-
'fields' => 'ids',
|
61 |
-
'meta_query' => array(
|
62 |
-
array(
|
63 |
-
'value' => $file,
|
64 |
-
'compare' => 'LIKE',
|
65 |
-
'key' => '_wp_attachment_metadata',
|
66 |
-
),
|
67 |
-
)
|
68 |
-
);
|
69 |
-
$query = new WP_Query( $query_args );
|
70 |
-
if ( $query->have_posts() ) {
|
71 |
-
while ( $query->have_posts() ) : $query->the_post();
|
72 |
-
$post_id = get_the_ID();
|
73 |
-
$meta = wp_get_attachment_metadata( $post_id );
|
74 |
-
if ( $meta && isset( $meta['file'] ) && isset( $meta['sizes'] ) ) :
|
75 |
-
$original_file = basename( $meta['file'] );
|
76 |
-
$cropped_image_files = wp_list_pluck( $meta['sizes'], 'file' );
|
77 |
-
if ( $original_file === $file || in_array( $file, $cropped_image_files ) ) {
|
78 |
-
$attachment_id = $post_id;
|
79 |
-
break;
|
80 |
-
}
|
81 |
-
endif;
|
82 |
-
endwhile;
|
83 |
-
wp_reset_query();
|
84 |
-
wp_reset_postdata();
|
85 |
-
}
|
86 |
-
}
|
87 |
-
return $attachment_id;
|
88 |
-
}
|
89 |
-
|
90 |
-
/**
|
91 |
-
* Get image alt text by image URL
|
92 |
-
*
|
93 |
-
* @param String $image_url
|
94 |
-
*
|
95 |
-
* @return Bool | String
|
96 |
-
*/
|
97 |
-
function gdpr_get_logo_alt( $image_url ) {
|
98 |
-
|
99 |
-
global $wpdb;
|
100 |
-
|
101 |
-
if ( empty( $image_url ) ) {
|
102 |
-
return get_bloginfo('name');
|
103 |
-
}
|
104 |
-
$image_id = gdpr_get_attachment_id( $image_url );
|
105 |
-
if ( $image_id ) :
|
106 |
-
$image_alt = get_post_meta( $image_id, '_wp_attachment_image_alt', true );
|
107 |
-
return $image_alt;
|
108 |
-
else :
|
109 |
-
return get_bloginfo('name');
|
110 |
-
endif;
|
111 |
-
|
112 |
-
}
|
113 |
-
|
114 |
-
/**
|
115 |
-
* GDPR Module manager, introduced in version 1.1.5
|
116 |
-
*/
|
117 |
-
function gdpr_get_module( $module = '' ) {
|
118 |
-
if ( $module ) :
|
119 |
-
$module_controller = new GDPR_Modules();
|
120 |
-
switch ( $module ) :
|
121 |
-
case 'floating-button':
|
122 |
-
return apply_filters( 'gdpr_floating_button_module', $module_controller->get_floating_button() );
|
123 |
-
break;
|
124 |
-
case 'infobar-base':
|
125 |
-
return apply_filters( 'gdpr_infobar_base_module', $module_controller->get_infobar_base() );
|
126 |
-
break;
|
127 |
-
case 'infobar-content':
|
128 |
-
return apply_filters( 'gdpr_infobar_content_module', $module_controller->get_infobar_content() );
|
129 |
-
break;
|
130 |
-
case 'infobar-buttons':
|
131 |
-
return apply_filters( 'gdpr_infobar_buttons_module', $module_controller->get_infobar_buttons() );
|
132 |
-
break;
|
133 |
-
case 'company-logo':
|
134 |
-
return apply_filters( 'gdpr_company_logo_module', $module_controller->get_company_logo() );
|
135 |
-
break;
|
136 |
-
case 'gdpr-branding':
|
137 |
-
return apply_filters( 'gdpr_branding_module', $module_controller->get_gdpr_branding() );
|
138 |
-
break;
|
139 |
-
case 'modal-base' :
|
140 |
-
return apply_filters( 'gdpr_modal_base_module', $module_controller->get_modal_base() );
|
141 |
-
break;
|
142 |
-
case 'tab-navigation' :
|
143 |
-
return apply_filters( 'gdpr_tab_navigation_module', $module_controller->get_tab_navigation() );
|
144 |
-
break;
|
145 |
-
case 'modal-footer-buttons' :
|
146 |
-
return apply_filters( 'gdpr_modal_footer_buttons_module', $module_controller->get_tab_footer_buttons() );
|
147 |
-
break;
|
148 |
-
case 'section-overview' :
|
149 |
-
return apply_filters( 'gdpr_section_overview_module', $module_controller->get_section_overview() );
|
150 |
-
break;
|
151 |
-
case 'section-strictly' :
|
152 |
-
return apply_filters( 'gdpr_section_strictly_module', $module_controller->get_section_strictly() );
|
153 |
-
break;
|
154 |
-
case 'section-advanced' :
|
155 |
-
return apply_filters( 'gdpr_section_advanced_module', $module_controller->get_section_advanced() );
|
156 |
-
break;
|
157 |
-
case 'section-third_party' :
|
158 |
-
return apply_filters( 'gdpr_section_third_party_module', $module_controller->get_section_third_party() );
|
159 |
-
break;
|
160 |
-
case 'section-cookiepolicy' :
|
161 |
-
return apply_filters( 'gdpr_section_cookiepolicy_module', $module_controller->get_section_cookiepolicy() );
|
162 |
-
break;
|
163 |
-
case 'branding-styles' :
|
164 |
-
return apply_filters( 'gdpr_branding_styles_module', $module_controller->get_branding_styles() );
|
165 |
-
break;
|
166 |
-
endswitch;
|
167 |
-
endif;
|
168 |
-
return false;
|
169 |
-
}
|
170 |
-
|
171 |
-
/**
|
172 |
-
* Checking accepted cookie values by type
|
173 |
-
*/
|
174 |
-
|
175 |
-
if ( ! function_exists( 'gdpr_cookie_is_accepted' ) ) :
|
176 |
-
function gdpr_cookie_is_accepted( $type = '' ) {
|
177 |
-
$response = false;
|
178 |
-
$type = sanitize_text_field( $type );
|
179 |
-
$accepted_types = array( 'strict', 'thirdparty', 'advanced' );
|
180 |
-
if ( $type && in_array( $type, $accepted_types ) ) :
|
181 |
-
$gdpr_content = new Moove_GDPR_Content();
|
182 |
-
$php_cookies = $gdpr_content->gdpr_get_php_cookies();
|
183 |
-
$response = $php_cookies && isset( $php_cookies[ $type ] ) && $php_cookies[ $type ] ? true : false;
|
184 |
-
endif;
|
185 |
-
return $response;
|
186 |
-
}
|
187 |
-
endif;
|
188 |
-
|
189 |
-
if ( ! function_exists( 'gdpr_get_display_language_by_locale' ) ) :
|
190 |
-
function gdpr_get_display_language_by_locale( $locale ) {
|
191 |
-
$locale_lang = explode( '-', $locale );
|
192 |
-
$_locale = isset( $locale_lang[0] ) ? $locale_lang[0] : $locale;
|
193 |
-
$language_codes = array(
|
194 |
-
"aa" => "Afar",
|
195 |
-
"ab" => "Abkhazian",
|
196 |
-
"ae" => "Avestan",
|
197 |
-
"af" => "Afrikaans",
|
198 |
-
"ak" => "Akan",
|
199 |
-
"am" => "Amharic",
|
200 |
-
"an" => "Aragonese",
|
201 |
-
"ar" => "Arabic",
|
202 |
-
"as" => "Assamese",
|
203 |
-
"av" => "Avaric",
|
204 |
-
"ay" => "Aymara",
|
205 |
-
"az" => "Azerbaijani",
|
206 |
-
"ba" => "Bashkir",
|
207 |
-
"be" => "Belarusian",
|
208 |
-
"bg" => "Bulgarian",
|
209 |
-
"bh" => "Bihari",
|
210 |
-
"bi" => "Bislama",
|
211 |
-
"bm" => "Bambara",
|
212 |
-
"bn" => "Bengali",
|
213 |
-
"bo" => "Tibetan",
|
214 |
-
"br" => "Breton",
|
215 |
-
"bs" => "Bosnian",
|
216 |
-
"ca" => "Catalan",
|
217 |
-
"ce" => "Chechen",
|
218 |
-
"ch" => "Chamorro",
|
219 |
-
"co" => "Corsican",
|
220 |
-
"cr" => "Cree",
|
221 |
-
"cs" => "Czech",
|
222 |
-
"cu" => "Church Slavic",
|
223 |
-
"cv" => "Chuvash",
|
224 |
-
"cy" => "Welsh",
|
225 |
-
"da" => "Danish",
|
226 |
-
"de" => "German",
|
227 |
-
"dv" => "Divehi",
|
228 |
-
"dz" => "Dzongkha",
|
229 |
-
"ee" => "Ewe",
|
230 |
-
"el" => "Greek",
|
231 |
-
"en" => "English",
|
232 |
-
"eo" => "Esperanto",
|
233 |
-
"es" => "Spanish",
|
234 |
-
"et" => "Estonian",
|
235 |
-
"eu" => "Basque",
|
236 |
-
"fa" => "Persian",
|
237 |
-
"ff" => "Fulah",
|
238 |
-
"fi" => "Finnish",
|
239 |
-
"fj" => "Fijian",
|
240 |
-
"fo" => "Faroese",
|
241 |
-
"fr" => "French",
|
242 |
-
"fy" => "Western Frisian",
|
243 |
-
"ga" => "Irish",
|
244 |
-
"gd" => "Scottish Gaelic",
|
245 |
-
"gl" => "Galician",
|
246 |
-
"gn" => "Guarani",
|
247 |
-
"gu" => "Gujarati",
|
248 |
-
"gv" => "Manx",
|
249 |
-
"ha" => "Hausa",
|
250 |
-
"he" => "Hebrew",
|
251 |
-
"hi" => "Hindi",
|
252 |
-
"ho" => "Hiri Motu",
|
253 |
-
"hr" => "Croatian",
|
254 |
-
"ht" => "Haitian",
|
255 |
-
"hu" => "Hungarian",
|
256 |
-
"hy" => "Armenian",
|
257 |
-
"hz" => "Herero",
|
258 |
-
"ia" => "Interlingua (International Auxiliary Language Association)",
|
259 |
-
"id" => "Indonesian",
|
260 |
-
"ie" => "Interlingue",
|
261 |
-
"ig" => "Igbo",
|
262 |
-
"ii" => "Sichuan Yi",
|
263 |
-
"ik" => "Inupiaq",
|
264 |
-
"io" => "Ido",
|
265 |
-
"is" => "Icelandic",
|
266 |
-
"it" => "Italian",
|
267 |
-
"iu" => "Inuktitut",
|
268 |
-
"ja" => "Japanese",
|
269 |
-
"jv" => "Javanese",
|
270 |
-
"ka" => "Georgian",
|
271 |
-
"kg" => "Kongo",
|
272 |
-
"ki" => "Kikuyu",
|
273 |
-
"kj" => "Kwanyama",
|
274 |
-
"kk" => "Kazakh",
|
275 |
-
"kl" => "Kalaallisut",
|
276 |
-
"km" => "Khmer",
|
277 |
-
"kn" => "Kannada",
|
278 |
-
"ko" => "Korean",
|
279 |
-
"kr" => "Kanuri",
|
280 |
-
"ks" => "Kashmiri",
|
281 |
-
"ku" => "Kurdish",
|
282 |
-
"kv" => "Komi",
|
283 |
-
"kw" => "Cornish",
|
284 |
-
"ky" => "Kirghiz",
|
285 |
-
"la" => "Latin",
|
286 |
-
"lb" => "Luxembourgish",
|
287 |
-
"lg" => "Ganda",
|
288 |
-
"li" => "Limburgish",
|
289 |
-
"ln" => "Lingala",
|
290 |
-
"lo" => "Lao",
|
291 |
-
"lt" => "Lithuanian",
|
292 |
-
"lu" => "Luba-Katanga",
|
293 |
-
"lv" => "Latvian",
|
294 |
-
"mg" => "Malagasy",
|
295 |
-
"mh" => "Marshallese",
|
296 |
-
"mi" => "Maori",
|
297 |
-
"mk" => "Macedonian",
|
298 |
-
"ml" => "Malayalam",
|
299 |
-
"mn" => "Mongolian",
|
300 |
-
"mr" => "Marathi",
|
301 |
-
"ms" => "Malay",
|
302 |
-
"mt" => "Maltese",
|
303 |
-
"my" => "Burmese",
|
304 |
-
"na" => "Nauru",
|
305 |
-
"nb" => "Norwegian Bokmal",
|
306 |
-
"nd" => "North Ndebele",
|
307 |
-
"ne" => "Nepali",
|
308 |
-
"ng" => "Ndonga",
|
309 |
-
"nl" => "Dutch",
|
310 |
-
"nn" => "Norwegian Nynorsk",
|
311 |
-
"no" => "Norwegian",
|
312 |
-
"nr" => "South Ndebele",
|
313 |
-
"nv" => "Navajo",
|
314 |
-
"ny" => "Chichewa",
|
315 |
-
"oc" => "Occitan",
|
316 |
-
"oj" => "Ojibwa",
|
317 |
-
"om" => "Oromo",
|
318 |
-
"or" => "Oriya",
|
319 |
-
"os" => "Ossetian",
|
320 |
-
"pa" => "Panjabi",
|
321 |
-
"pi" => "Pali",
|
322 |
-
"pl" => "Polish",
|
323 |
-
"ps" => "Pashto",
|
324 |
-
"pt" => "Portuguese",
|
325 |
-
"qu" => "Quechua",
|
326 |
-
"rm" => "Raeto-Romance",
|
327 |
-
"rn" => "Kirundi",
|
328 |
-
"ro" => "Romanian",
|
329 |
-
"ru" => "Russian",
|
330 |
-
"rw" => "Kinyarwanda",
|
331 |
-
"sa" => "Sanskrit",
|
332 |
-
"sc" => "Sardinian",
|
333 |
-
"sd" => "Sindhi",
|
334 |
-
"se" => "Northern Sami",
|
335 |
-
"sg" => "Sango",
|
336 |
-
"si" => "Sinhala",
|
337 |
-
"sk" => "Slovak",
|
338 |
-
"sl" => "Slovenian",
|
339 |
-
"sm" => "Samoan",
|
340 |
-
"sn" => "Shona",
|
341 |
-
"so" => "Somali",
|
342 |
-
"sq" => "Albanian",
|
343 |
-
"sr" => "Serbian",
|
344 |
-
"ss" => "Swati",
|
345 |
-
"st" => "Southern Sotho",
|
346 |
-
"su" => "Sundanese",
|
347 |
-
"sv" => "Swedish",
|
348 |
-
"sw" => "Swahili",
|
349 |
-
"ta" => "Tamil",
|
350 |
-
"te" => "Telugu",
|
351 |
-
"tg" => "Tajik",
|
352 |
-
"th" => "Thai",
|
353 |
-
"ti" => "Tigrinya",
|
354 |
-
"tk" => "Turkmen",
|
355 |
-
"tl" => "Tagalog",
|
356 |
-
"tn" => "Tswana",
|
357 |
-
"to" => "Tonga",
|
358 |
-
"tr" => "Turkish",
|
359 |
-
"ts" => "Tsonga",
|
360 |
-
"tt" => "Tatar",
|
361 |
-
"tw" => "Twi",
|
362 |
-
"ty" => "Tahitian",
|
363 |
-
"ug" => "Uighur",
|
364 |
-
"uk" => "Ukrainian",
|
365 |
-
"ur" => "Urdu",
|
366 |
-
"uz" => "Uzbek",
|
367 |
-
"ve" => "Venda",
|
368 |
-
"vi" => "Vietnamese",
|
369 |
-
"vo" => "Volapuk",
|
370 |
-
"wa" => "Walloon",
|
371 |
-
"wo" => "Wolof",
|
372 |
-
"xh" => "Xhosa",
|
373 |
-
"yi" => "Yiddish",
|
374 |
-
"yo" => "Yoruba",
|
375 |
-
"za" => "Zhuang",
|
376 |
-
"zh" => "Chinese",
|
377 |
-
"zu" => "Zulu"
|
378 |
-
);
|
379 |
-
return isset( $language_codes[$_locale] ) ? $language_codes[$_locale] . ' ['.$locale.']' : $locale;
|
380 |
-
}
|
381 |
-
endif;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
moove-gdpr.php
CHANGED
@@ -1,27 +1,30 @@
|
|
1 |
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
3 |
-
|
4 |
/**
|
5 |
-
*
|
6 |
* Plugin Name: GDPR Cookie Compliance
|
7 |
* Plugin URI: https://wordpress.org/plugins/gdpr-cookie-compliance/
|
8 |
* Description: GDPR is an EU wide legislation that specifies how user data should be handled. This plugin has settings that can assist you with GDPR cookie compliance requirements.
|
9 |
-
* Version: 3.
|
10 |
* Author: Moove Agency
|
11 |
-
*
|
12 |
* Author URI: https://www.mooveagency.com
|
13 |
* License: GPLv2
|
14 |
* Text Domain: gdpr-cookie-compliance
|
|
|
|
|
15 |
*/
|
16 |
|
|
|
|
|
|
|
17 |
|
18 |
-
define( 'MOOVE_GDPR_VERSION', '3.
|
19 |
if ( ! defined( 'MOOVE_SHOP_URL' ) ) :
|
20 |
define( 'MOOVE_SHOP_URL', 'https://shop.mooveagency.com' );
|
21 |
endif;
|
22 |
|
23 |
-
register_activation_hook( __FILE__
|
24 |
-
register_deactivation_hook( __FILE__
|
25 |
|
26 |
/**
|
27 |
* Functions on plugin activation, create relevant pages and defaults for settings page.
|
@@ -34,7 +37,8 @@ function moove_gdpr_activate() {
|
|
34 |
* Function on plugin deactivation. It removes the pages created before.
|
35 |
*/
|
36 |
function moove_gdpr_deactivate() {
|
37 |
-
// $
|
|
|
38 |
// update_option( $option_name, array() );
|
39 |
}
|
40 |
|
@@ -42,7 +46,9 @@ function moove_gdpr_deactivate() {
|
|
42 |
* Loading Text Domain - for translations & localizations
|
43 |
*/
|
44 |
add_action( 'plugins_loaded', 'moove_gdpr_load_textdomain' );
|
45 |
-
|
|
|
|
|
46 |
function moove_gdpr_load_textdomain() {
|
47 |
load_plugin_textdomain( 'gdpr-cookie-compliance', false, basename( dirname( __FILE__ ) ) . '/languages' );
|
48 |
}
|
@@ -50,41 +56,77 @@ function moove_gdpr_load_textdomain() {
|
|
50 |
/**
|
51 |
* Loading Core files after all the plugins are loaded!
|
52 |
*/
|
53 |
-
add_action('plugins_loaded', 'gdpr_cookie_compliance_load_libs');
|
54 |
|
55 |
/**
|
56 |
* Star rating on the plugin listing page
|
57 |
*/
|
58 |
-
if ( ! function_exists('gdpr_cookie_add_plugin_meta_links') ) {
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
63 |
<i class='gdpr-plugin-star-rating'>"
|
64 |
. "<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' class='feather feather-star'><polygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/></svg>"
|
65 |
. "<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' class='feather feather-star'><polygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/></svg>"
|
66 |
. "<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' class='feather feather-star'><polygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/></svg>"
|
67 |
. "<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' class='feather feather-star'><polygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/></svg>"
|
68 |
. "<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' class='feather feather-star'><polygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/></svg>"
|
69 |
-
.
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
}
|
74 |
}
|
75 |
-
add_filter('plugin_row_meta'
|
76 |
-
|
|
|
|
|
77 |
function gdpr_cookie_compliance_load_libs() {
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
include_once
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
87 |
|
88 |
-
|
89 |
-
|
|
|
|
|
90 |
}
|
1 |
<?php
|
|
|
|
|
2 |
/**
|
3 |
+
* Contributors: MooveAgency
|
4 |
* Plugin Name: GDPR Cookie Compliance
|
5 |
* Plugin URI: https://wordpress.org/plugins/gdpr-cookie-compliance/
|
6 |
* Description: GDPR is an EU wide legislation that specifies how user data should be handled. This plugin has settings that can assist you with GDPR cookie compliance requirements.
|
7 |
+
* Version: 3.2.0
|
8 |
* Author: Moove Agency
|
9 |
+
* Domain Path: /languages
|
10 |
* Author URI: https://www.mooveagency.com
|
11 |
* License: GPLv2
|
12 |
* Text Domain: gdpr-cookie-compliance
|
13 |
+
*
|
14 |
+
* @package gdpr-cookie-compliance
|
15 |
*/
|
16 |
|
17 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
18 |
+
exit;
|
19 |
+
} // Exit if accessed directly
|
20 |
|
21 |
+
define( 'MOOVE_GDPR_VERSION', '3.2.0' );
|
22 |
if ( ! defined( 'MOOVE_SHOP_URL' ) ) :
|
23 |
define( 'MOOVE_SHOP_URL', 'https://shop.mooveagency.com' );
|
24 |
endif;
|
25 |
|
26 |
+
register_activation_hook( __FILE__, 'moove_gdpr_activate' );
|
27 |
+
register_deactivation_hook( __FILE__, 'moove_gdpr_deactivate' );
|
28 |
|
29 |
/**
|
30 |
* Functions on plugin activation, create relevant pages and defaults for settings page.
|
37 |
* Function on plugin deactivation. It removes the pages created before.
|
38 |
*/
|
39 |
function moove_gdpr_deactivate() {
|
40 |
+
// $gdpr_content = new Moove_GDPR_Content();
|
41 |
+
// $option_name = $gdpr_content->moove_gdpr_get_option_name();
|
42 |
// update_option( $option_name, array() );
|
43 |
}
|
44 |
|
46 |
* Loading Text Domain - for translations & localizations
|
47 |
*/
|
48 |
add_action( 'plugins_loaded', 'moove_gdpr_load_textdomain' );
|
49 |
+
/**
|
50 |
+
* Loading text domain
|
51 |
+
*/
|
52 |
function moove_gdpr_load_textdomain() {
|
53 |
load_plugin_textdomain( 'gdpr-cookie-compliance', false, basename( dirname( __FILE__ ) ) . '/languages' );
|
54 |
}
|
56 |
/**
|
57 |
* Loading Core files after all the plugins are loaded!
|
58 |
*/
|
59 |
+
add_action( 'plugins_loaded', 'gdpr_cookie_compliance_load_libs' );
|
60 |
|
61 |
/**
|
62 |
* Star rating on the plugin listing page
|
63 |
*/
|
64 |
+
if ( ! function_exists( 'gdpr_cookie_add_plugin_meta_links' ) ) {
|
65 |
+
/**
|
66 |
+
* Meta links visible in plugins page
|
67 |
+
*
|
68 |
+
* @param array $meta_fields Meta fields.
|
69 |
+
* @param string $file Plugin path.
|
70 |
+
*/
|
71 |
+
function gdpr_cookie_add_plugin_meta_links( $meta_fields, $file ) {
|
72 |
+
if ( plugin_basename( __FILE__ ) === $file ) :
|
73 |
+
$plugin_url = 'https://wordpress.org/support/plugin/gdpr-cookie-compliance/reviews/?rate=5#new-post';
|
74 |
+
$meta_fields[] = "<a href='" . esc_url( $plugin_url ) . "' target='_blank' title='" . esc_html__( 'Rate', 'gdpr-cookie-compliance' ) . "'>
|
75 |
<i class='gdpr-plugin-star-rating'>"
|
76 |
. "<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' class='feather feather-star'><polygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/></svg>"
|
77 |
. "<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' class='feather feather-star'><polygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/></svg>"
|
78 |
. "<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' class='feather feather-star'><polygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/></svg>"
|
79 |
. "<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' class='feather feather-star'><polygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/></svg>"
|
80 |
. "<svg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' class='feather feather-star'><polygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/></svg>"
|
81 |
+
. '</i></a>';
|
82 |
+
|
83 |
+
endif;
|
84 |
+
return $meta_fields;
|
85 |
}
|
86 |
}
|
87 |
+
add_filter( 'plugin_row_meta', 'gdpr_cookie_add_plugin_meta_links', 10, 2 );
|
88 |
+
/**
|
89 |
+
* Loading assets
|
90 |
+
*/
|
91 |
function gdpr_cookie_compliance_load_libs() {
|
92 |
+
/**
|
93 |
+
* View
|
94 |
+
*/
|
95 |
+
include_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'class-gdpr-view.php';
|
96 |
+
|
97 |
+
/**
|
98 |
+
* Modules View
|
99 |
+
*/
|
100 |
+
include_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'class-gdpr-modules-view.php';
|
101 |
+
/**
|
102 |
+
* Modules
|
103 |
+
*/
|
104 |
+
include_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'class-gdpr-modules.php';
|
105 |
+
|
106 |
+
/**
|
107 |
+
* Content
|
108 |
+
*/
|
109 |
+
include_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'class-moove-gdpr-content.php';
|
110 |
+
|
111 |
+
/**
|
112 |
+
* Options page
|
113 |
+
*/
|
114 |
+
include_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'class-moove-gdpr-options.php';
|
115 |
+
|
116 |
+
/**
|
117 |
+
* Controllers
|
118 |
+
*/
|
119 |
+
include_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'controllers' . DIRECTORY_SEPARATOR . 'class-moove-gdpr-controller.php';
|
120 |
+
include_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'controllers' . DIRECTORY_SEPARATOR . 'class-moove-gdpr-license-manager.php';
|
121 |
+
include_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'controllers' . DIRECTORY_SEPARATOR . 'class-moove-gdpr-updater.php';
|
122 |
+
|
123 |
+
/**
|
124 |
+
* Actions
|
125 |
+
*/
|
126 |
+
include_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'class-moove-gdpr-actions.php';
|
127 |
|
128 |
+
/**
|
129 |
+
* Custom Functions
|
130 |
+
*/
|
131 |
+
include_once dirname( __FILE__ ) . DIRECTORY_SEPARATOR . 'gdpr-functions.php';
|
132 |
}
|
moove-modules.php
DELETED
@@ -1,378 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
|
3 |
-
|
4 |
-
/**
|
5 |
-
* GDPR_Modules File Doc Comment
|
6 |
-
*
|
7 |
-
* @category GDPR_Modules
|
8 |
-
* @package gdpr-cookie-compliance
|
9 |
-
* @author Gaspar Nemes
|
10 |
-
*/
|
11 |
-
|
12 |
-
/**
|
13 |
-
* GDPR_Modules Class Doc Comment
|
14 |
-
*
|
15 |
-
* @category Class
|
16 |
-
* @package Moove_Modules
|
17 |
-
* @author Gaspar Nemes
|
18 |
-
*/
|
19 |
-
class GDPR_Modules {
|
20 |
-
|
21 |
-
protected $gdpr_options;
|
22 |
-
protected $wpml_lang;
|
23 |
-
|
24 |
-
/**
|
25 |
-
* Construct function
|
26 |
-
*/
|
27 |
-
public function __construct() {
|
28 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
29 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
30 |
-
$modal_options = get_option( $option_name );
|
31 |
-
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
32 |
-
$this->gdpr_options = $modal_options;
|
33 |
-
$this->wpml_lang = $wpml_lang;
|
34 |
-
}
|
35 |
-
|
36 |
-
/**
|
37 |
-
* GDPR Module - Floating Button view & content
|
38 |
-
*/
|
39 |
-
public function get_floating_button() {
|
40 |
-
$view_controller = new GDPR_Modules_View();
|
41 |
-
$modal_options = $this->gdpr_options;
|
42 |
-
$wpml_lang = $this->wpml_lang;
|
43 |
-
$floating_button_visibility = 'display: block;';
|
44 |
-
$floating_button_class = '';
|
45 |
-
$infobar_hidden = isset( $modal_options['moove_gdpr_infobar_visibility'] ) && $modal_options['moove_gdpr_infobar_visibility'] === 'hidden' ? true : false;
|
46 |
-
if ( $infobar_hidden ) :
|
47 |
-
$floating_button_class = 'button-visible';
|
48 |
-
endif;
|
49 |
-
$floating_button_position = isset( $modal_options['moove_gdpr_floating_button_position'] ) ? $modal_options['moove_gdpr_floating_button_position'] : '';
|
50 |
-
$data = new stdClass();
|
51 |
-
$data->options = $modal_options;
|
52 |
-
$data->wpml_lang = $wpml_lang;
|
53 |
-
$data->is_enabled = ( isset( $modal_options['moove_gdpr_floating_button_enable'] ) && intval( $modal_options['moove_gdpr_floating_button_enable'] ) === 1 ) ? true : false;
|
54 |
-
$data->styles = $floating_button_visibility . $floating_button_position;
|
55 |
-
$data->class = $floating_button_class;
|
56 |
-
if ( $floating_button_position ) :
|
57 |
-
$data->class = $floating_button_class .= ' gdpr-floating-button-custom-position';
|
58 |
-
endif;
|
59 |
-
$data->label = ( isset( $modal_options['moove_gdpr_floating_button_label'.$wpml_lang] ) && $modal_options['moove_gdpr_floating_button_label'.$wpml_lang] ) ? $modal_options['moove_gdpr_floating_button_label'.$wpml_lang] : __('Change cookie settings','gdpr-cookie-compliance');
|
60 |
-
return $view_controller->load( 'infobar.floating-button', $data );
|
61 |
-
}
|
62 |
-
|
63 |
-
/**
|
64 |
-
* GDPR Module - Base structure
|
65 |
-
*/
|
66 |
-
public function get_modal_base() {
|
67 |
-
$view_controller = new GDPR_Modules_View();
|
68 |
-
$modal_options = $this->gdpr_options;
|
69 |
-
$wpml_lang = $this->wpml_lang;
|
70 |
-
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
71 |
-
$tab_title = isset( $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] : __('Privacy Overview','gdpr-cookie-compliance');
|
72 |
-
$data = new stdClass();
|
73 |
-
$data->logo_position = isset( $modal_options['moove_gdpr_logo_position'] ) ? $modal_options['moove_gdpr_logo_position'] : 'left';
|
74 |
-
$data->theme = $modal_theme = 'moove_gdpr_modal_theme_' . $layout;
|
75 |
-
$data->modal_title = $layout === 'v1' ? false : $tab_title;
|
76 |
-
$view_type = $layout === 'v1' ? 'tabs' : 'onepage';
|
77 |
-
return $view_controller->load( 'modal.modal-base-' . $view_type, $data );
|
78 |
-
}
|
79 |
-
|
80 |
-
/**
|
81 |
-
* GDPR Module - Infobar structure
|
82 |
-
*/
|
83 |
-
public function get_infobar_base() {
|
84 |
-
$view_controller = new GDPR_Modules_View();
|
85 |
-
$modal_options = $this->gdpr_options;
|
86 |
-
$wpml_lang = $this->wpml_lang;
|
87 |
-
$data = new stdClass();
|
88 |
-
$infobar_classes = array(
|
89 |
-
'moove-gdpr-info-bar-hidden',
|
90 |
-
'moove-gdpr-align-center',
|
91 |
-
);
|
92 |
-
$modal_scheme = isset( $modal_options['moove_gdpr_colour_scheme'] ) ? ( ( intval( $modal_options['moove_gdpr_colour_scheme'] ) === 1 || intval( $modal_options['moove_gdpr_colour_scheme'] ) === 2 ) ? intval( $modal_options['moove_gdpr_colour_scheme'] ) : 1 ) : 1;
|
93 |
-
$scheme_class = $modal_scheme === 2 ? 'moove-gdpr-light-scheme' : 'moove-gdpr-dark-scheme';
|
94 |
-
$infobar_position = isset( $modal_options['moove_gdpr_infobar_position'] ) ? $modal_options['moove_gdpr_infobar_position'] : 'bottom';
|
95 |
-
$infobar_classes[] = $scheme_class;
|
96 |
-
$infobar_classes[] = 'gdpr_infobar_postion_' . $infobar_position;
|
97 |
-
$infobar_classes = apply_filters( 'gdpr_info_bar_class_extension', $infobar_classes );
|
98 |
-
$infobar_hidden = isset( $modal_options['moove_gdpr_infobar_visibility'] ) && $modal_options['moove_gdpr_infobar_visibility'] === 'hidden' ? true : false;
|
99 |
-
$data->show = $infobar_hidden ? false : true;
|
100 |
-
$data->class = implode( ' ', $infobar_classes );
|
101 |
-
$infobar_content = apply_filters( 'gdpr_info_bar_popup_content', $view_controller->load( 'infobar.infobar-base', $data ) );
|
102 |
-
return $infobar_content;
|
103 |
-
|
104 |
-
}
|
105 |
-
|
106 |
-
/**
|
107 |
-
* GDPR Module - Infobar Main Content
|
108 |
-
*/
|
109 |
-
public function get_infobar_content() {
|
110 |
-
$view_controller = new GDPR_Modules_View();
|
111 |
-
$modal_options = $this->gdpr_options;
|
112 |
-
$wpml_lang = $this->wpml_lang;
|
113 |
-
$_content = '<p>'.__('This website uses cookies to provide you with the best browsing experience.','gdpr-cookie-compliance').'</p>'.
|
114 |
-
'<p>'.__('Find out more or adjust your [setting]settings[/setting].','gdpr-cookie-compliance').'</p>';
|
115 |
-
$content = isset( $modal_options['moove_gdpr_info_bar_content'.$wpml_lang] ) && $modal_options['moove_gdpr_info_bar_content'.$wpml_lang] ? $modal_options['moove_gdpr_info_bar_content'.$wpml_lang] : $_content;
|
116 |
-
$content = str_replace('[setting]', '<span data-href="#moove_gdpr_cookie_modal" class="change-settings-button">', $content);
|
117 |
-
$content = str_replace('[/setting]', '</span>', $content);
|
118 |
-
$content = apply_filters( 'gdpr_info_bar_notice_content', $content );
|
119 |
-
$data = new stdClass();
|
120 |
-
$data->text_content = $content;
|
121 |
-
return $view_controller->load( 'infobar.infobar-content', $data );
|
122 |
-
}
|
123 |
-
|
124 |
-
/**
|
125 |
-
* GDPR Module - Infobar button & extensions
|
126 |
-
*/
|
127 |
-
public function get_infobar_buttons() {
|
128 |
-
$view_controller = new GDPR_Modules_View();
|
129 |
-
$modal_options = $this->gdpr_options;
|
130 |
-
$wpml_lang = $this->wpml_lang;
|
131 |
-
$data = new stdClass();
|
132 |
-
$data->button_label = isset( $modal_options['moove_gdpr_infobar_accept_button_label'.$wpml_lang] ) && $modal_options['moove_gdpr_infobar_accept_button_label'.$wpml_lang] ? $modal_options['moove_gdpr_infobar_accept_button_label'.$wpml_lang] : __('Accept','gdpr-cookie-compliance');
|
133 |
-
return $view_controller->load( 'infobar.infobar-buttons', $data );
|
134 |
-
|
135 |
-
}
|
136 |
-
|
137 |
-
/**
|
138 |
-
* GDPR Module - Company Logo
|
139 |
-
*/
|
140 |
-
public function get_company_logo() {
|
141 |
-
$view_controller = new GDPR_Modules_View();
|
142 |
-
$modal_options = $this->gdpr_options;
|
143 |
-
$wpml_lang = $this->wpml_lang;
|
144 |
-
$data = new stdClass();
|
145 |
-
$data->options = $modal_options;
|
146 |
-
$data->wpml_lang = $wpml_lang;
|
147 |
-
$data->logo_url = isset( $modal_options['moove_gdpr_company_logo'] ) && $modal_options['moove_gdpr_company_logo'] ? $modal_options['moove_gdpr_company_logo'] : plugin_dir_url( __FILE__ ) . 'dist/images/gdpr-logo.png';
|
148 |
-
$data->logo_url = str_replace( plugin_dir_url( __FILE__ ) . 'dist/images/moove-logo.png', plugin_dir_url( __FILE__ ) . 'dist/images/gdpr-logo.png', $data->logo_url );
|
149 |
-
$data->logo_alt = gdpr_get_logo_alt( $data->logo_url );
|
150 |
-
return $view_controller->load( 'modal.company-logo', $data );
|
151 |
-
}
|
152 |
-
|
153 |
-
/**
|
154 |
-
* GDPR Module - Branding Options
|
155 |
-
*/
|
156 |
-
public function get_gdpr_branding() {
|
157 |
-
$view_controller = new GDPR_Modules_View();
|
158 |
-
$moove_actions_cnt = new Moove_GDPR_Actions();
|
159 |
-
$modal_options = $this->gdpr_options;
|
160 |
-
$wpml_lang = $this->wpml_lang;
|
161 |
-
$data = new stdClass();
|
162 |
-
$data->options = $modal_options;
|
163 |
-
$data->wpml_lang = $wpml_lang;
|
164 |
-
$data->text = $moove_actions_cnt->moove_gdpr_footer_branding_content();
|
165 |
-
$data->is_enabled = isset( $modal_options['moove_gdpr_modal_powered_by_disable'] ) && intval( $modal_options['moove_gdpr_modal_powered_by_disable'] === 1 ) ? false : true;
|
166 |
-
return $view_controller->load( 'modal.gdpr-branding', $data );
|
167 |
-
}
|
168 |
-
|
169 |
-
/**
|
170 |
-
* GDPR Module - Privacy Overview Content
|
171 |
-
*/
|
172 |
-
public function get_section_overview() {
|
173 |
-
$view_controller = new GDPR_Modules_View();
|
174 |
-
$modal_options = $this->gdpr_options;
|
175 |
-
$wpml_lang = $this->wpml_lang;
|
176 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
177 |
-
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
178 |
-
$tab_title = isset( $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] : __('Privacy Overview','gdpr-cookie-compliance');
|
179 |
-
$tab_content = isset( $modal_options['moove_gdpr_privacy_overview_tab_content'.$wpml_lang] ) && $modal_options['moove_gdpr_privacy_overview_tab_content'.$wpml_lang] ? $modal_options['moove_gdpr_privacy_overview_tab_content'.$wpml_lang] : $gdpr_default_content->moove_gdpr_get_privacy_overview_content();
|
180 |
-
$data = new stdClass();
|
181 |
-
$data->options = $modal_options;
|
182 |
-
$data->wpml_lang = $wpml_lang;
|
183 |
-
$data->tab_title = $layout === 'v1' ? $tab_title : false;
|
184 |
-
$data->tab_content = wpautop( $tab_content );
|
185 |
-
$data->visibility = $layout === 'v1' ? 'style="display:none"' : '';
|
186 |
-
|
187 |
-
return $view_controller->load( 'modal.content-sections.overview', $data );
|
188 |
-
|
189 |
-
}
|
190 |
-
|
191 |
-
/**
|
192 |
-
* GPDR Module - Strictly Necessary Cookies
|
193 |
-
*/
|
194 |
-
public function get_section_strictly() {
|
195 |
-
$view_controller = new GDPR_Modules_View();
|
196 |
-
$modal_options = $this->gdpr_options;
|
197 |
-
$wpml_lang = $this->wpml_lang;
|
198 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
199 |
-
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
200 |
-
$tab_title = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] : __('Strictly Necessary Cookies','gdpr-cookie-compliance');
|
201 |
-
$tab_content = isset( $modal_options['moove_gdpr_strict_necessary_cookies_tab_content'.$wpml_lang] ) && $modal_options['moove_gdpr_strict_necessary_cookies_tab_content'.$wpml_lang] ? $modal_options['moove_gdpr_strict_necessary_cookies_tab_content'.$wpml_lang] : $gdpr_default_content->moove_gdpr_get_strict_necessary_content();
|
202 |
-
$strictly = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) : 1;
|
203 |
-
$warning_msg = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_warning'.$wpml_lang] ) && $modal_options['moove_gdpr_strictly_necessary_cookies_warning'.$wpml_lang] ? $modal_options['moove_gdpr_strictly_necessary_cookies_warning'.$wpml_lang] : $gdpr_default_content->moove_gdpr_get_strict_necessary_warning();
|
204 |
-
$data = new stdClass();
|
205 |
-
$data->options = $modal_options;
|
206 |
-
$data->wpml_lang = $wpml_lang;
|
207 |
-
$data->tab_title = $tab_title;
|
208 |
-
$data->tab_content = wpautop( $tab_content );
|
209 |
-
$data->show = $strictly !== 3;
|
210 |
-
$data->is_checked = $strictly !== 1 ? 'disabled checked="checked" ' : '';
|
211 |
-
$data->text_enable = isset( $modal_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] ) && $modal_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] ? $modal_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] : __('Enabled','gdpr-cookie-compliance');
|
212 |
-
$data->text_disable = isset( $modal_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] ) && $modal_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] ? $modal_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] : __('Disabled','gdpr-cookie-compliance');
|
213 |
-
$data->warning_message_top = $layout === 'v2' ? wpautop( $warning_msg ) : false;
|
214 |
-
$data->warning_message_bottom = $layout === 'v1' ? wpautop( $warning_msg ) : false;
|
215 |
-
$data->checkbox_state = $strictly !== 1 ? 'gdpr-checkbox-disabled checkbox-selected' : '';
|
216 |
-
$data->visibility = $layout === 'v1' ? 'style="display:none"' : '';
|
217 |
-
return $view_controller->load( 'modal.content-sections.strictly', $data );
|
218 |
-
}
|
219 |
-
|
220 |
-
/**
|
221 |
-
* GDPR Module - Advanced Cookies
|
222 |
-
*/
|
223 |
-
public function get_section_advanced() {
|
224 |
-
$view_controller = new GDPR_Modules_View();
|
225 |
-
$modal_options = $this->gdpr_options;
|
226 |
-
$wpml_lang = $this->wpml_lang;
|
227 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
228 |
-
|
229 |
-
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
230 |
-
$tab_title = isset( $modal_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] : __('Additional Cookies'.$wpml_lang,'gdpr-cookie-compliance');
|
231 |
-
$tab_content = isset( $modal_options['moove_gdpr_advanced_cookies_tab_content'.$wpml_lang] ) && $modal_options['moove_gdpr_advanced_cookies_tab_content'.$wpml_lang] ? $modal_options['moove_gdpr_advanced_cookies_tab_content'.$wpml_lang] : $gdpr_default_content->moove_gdpr_get_advanced_cookies_content();
|
232 |
-
$strictly = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) : 1;
|
233 |
-
$data = new stdClass();
|
234 |
-
$data->options = $modal_options;
|
235 |
-
$data->wpml_lang = $wpml_lang;
|
236 |
-
$data->tab_title = $tab_title;
|
237 |
-
$data->tab_content = wpautop( $tab_content );
|
238 |
-
$data->show = isset( $modal_options['moove_gdpr_advanced_cookies_enable'] ) && intval( $modal_options['moove_gdpr_advanced_cookies_enable'] ) === 1 ? true : false;
|
239 |
-
$data->is_checked = $strictly !== 1 ? '' : 'disabled';
|
240 |
-
$data->fieldset = $strictly !== 1 ? 'fl-strenabled' : 'fl-disabled';
|
241 |
-
$data->text_enable = isset( $modal_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] ) && $modal_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] ? $modal_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] : __('Enabled','gdpr-cookie-compliance');
|
242 |
-
$data->text_disable = isset( $modal_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] ) && $modal_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] ? $modal_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] : __('Disabled','gdpr-cookie-compliance');
|
243 |
-
$data->warning_message = isset( $modal_options['moove_gdpr_modal_strictly_secondary_notice'.$wpml_lang] ) && $modal_options['moove_gdpr_modal_strictly_secondary_notice'.$wpml_lang] ? $modal_options['moove_gdpr_modal_strictly_secondary_notice'.$wpml_lang] : $gdpr_default_content->moove_gdpr_get_secondary_notice();
|
244 |
-
$data->warning_message = wpautop( $data->warning_message );
|
245 |
-
$data->visibility = $layout === 'v1' ? 'style="display:none"' : '';
|
246 |
-
return $view_controller->load( 'modal.content-sections.advanced', $data );
|
247 |
-
}
|
248 |
-
|
249 |
-
/**
|
250 |
-
* GDPR Module - Third Party Cookies
|
251 |
-
*/
|
252 |
-
public function get_section_third_party() {
|
253 |
-
$view_controller = new GDPR_Modules_View();
|
254 |
-
$modal_options = $this->gdpr_options;
|
255 |
-
$wpml_lang = $this->wpml_lang;
|
256 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
257 |
-
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
258 |
-
$tab_title = isset( $modal_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] : __('3rd Party Cookies','gdpr-cookie-compliance');
|
259 |
-
$tab_content = isset( $modal_options['moove_gdpr_performance_cookies_tab_content'.$wpml_lang] ) && $modal_options['moove_gdpr_performance_cookies_tab_content'.$wpml_lang] ? $modal_options['moove_gdpr_performance_cookies_tab_content'.$wpml_lang] : $gdpr_default_content->moove_gdpr_get_third_party_content();
|
260 |
-
$strictly = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) : 1;
|
261 |
-
$data = new stdClass();
|
262 |
-
$data->options = $modal_options;
|
263 |
-
$data->wpml_lang = $wpml_lang;
|
264 |
-
$data->tab_title = $tab_title;
|
265 |
-
$data->tab_content = wpautop( $tab_content );
|
266 |
-
$data->show = isset( $modal_options['moove_gdpr_third_party_cookies_enable'] ) && intval( $modal_options['moove_gdpr_third_party_cookies_enable'] ) === 1 ? true : false;
|
267 |
-
$data->is_checked = $strictly !== 1 ? '' : 'disabled';
|
268 |
-
$data->fieldset = $strictly !== 1 ? 'fl-strenabled' : 'fl-disabled';
|
269 |
-
$data->text_enable = isset( $modal_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] ) && $modal_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] ? $modal_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] : __('Enabled','gdpr-cookie-compliance');
|
270 |
-
$data->text_disable = isset( $modal_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] ) && $modal_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] ? $modal_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] : __('Disabled','gdpr-cookie-compliance');
|
271 |
-
$data->warning_message = isset( $modal_options['moove_gdpr_modal_strictly_secondary_notice'.$wpml_lang] ) && $modal_options['moove_gdpr_modal_strictly_secondary_notice'.$wpml_lang] ? $modal_options['moove_gdpr_modal_strictly_secondary_notice'.$wpml_lang] : $gdpr_default_content->moove_gdpr_get_secondary_notice();
|
272 |
-
$data->warning_message = wpautop( $data->warning_message );
|
273 |
-
$data->visibility = $layout === 'v1' ? 'style="display:none"' : '';
|
274 |
-
return $view_controller->load( 'modal.content-sections.third_party', $data );
|
275 |
-
}
|
276 |
-
|
277 |
-
/**
|
278 |
-
* GDPR Module - Custom CSS for branding
|
279 |
-
*/
|
280 |
-
public function get_branding_styles() {
|
281 |
-
$view_controller = new GDPR_Modules_View();
|
282 |
-
$modal_options = $this->gdpr_options;
|
283 |
-
$wpml_lang = $this->wpml_lang;
|
284 |
-
$font_family = false;
|
285 |
-
if ( isset( $modal_options['moove_gdpr_plugin_font_type'] ) ) :
|
286 |
-
if ( $modal_options['moove_gdpr_plugin_font_type'] === '1' ) :
|
287 |
-
$font_family = "'Nunito', sans-serif";
|
288 |
-
elseif ( $modal_options['moove_gdpr_plugin_font_type'] === '2' ) :
|
289 |
-
$font_family = "inherit";
|
290 |
-
else :
|
291 |
-
$font_family = isset( $modal_options['moove_gdpr_plugin_font_family'] ) && $modal_options['moove_gdpr_plugin_font_family'] ? $modal_options['moove_gdpr_plugin_font_family'] : "'Nunito', sans-serif";
|
292 |
-
endif;
|
293 |
-
endif;
|
294 |
-
$font_family = $font_family ? $font_family : ( isset( $modal_options['moove_gdpr_plugin_font_family'] ) && $modal_options['moove_gdpr_plugin_font_family'] ? $modal_options['moove_gdpr_plugin_font_family'] : "'Nunito', sans-serif" );
|
295 |
-
$data = new stdClass();
|
296 |
-
$data->primary_colour = isset( $modal_options['moove_gdpr_brand_colour'] ) && $modal_options['moove_gdpr_brand_colour'] ? $modal_options['moove_gdpr_brand_colour'] : '#0C4DA2';
|
297 |
-
$data->secondary_colour = isset( $modal_options['moove_gdpr_brand_secondary_colour'] ) && $modal_options['moove_gdpr_brand_secondary_colour'] ? $modal_options['moove_gdpr_brand_secondary_colour'] : '#000000';
|
298 |
-
$data->button_bg = isset( $modal_options['moove_gdpr_floating_button_background_colour'] ) && $modal_options['moove_gdpr_floating_button_background_colour'] ? $modal_options['moove_gdpr_floating_button_background_colour'] : '#373737';
|
299 |
-
$data->button_hover_bg = isset( $modal_options['moove_gdpr_floating_button_hover_background_colour'] ) && $modal_options['moove_gdpr_floating_button_hover_background_colour'] ? $modal_options['moove_gdpr_floating_button_hover_background_colour'] : '#000000';
|
300 |
-
$data->button_font = isset( $modal_options['moove_gdpr_floating_button_font_colour'] ) && $modal_options['moove_gdpr_floating_button_font_colour'] ? $modal_options['moove_gdpr_floating_button_font_colour'] : '#ffffff';
|
301 |
-
$data->font_family = $font_family;
|
302 |
-
return $view_controller->load( 'branding-styles', $data );
|
303 |
-
|
304 |
-
}
|
305 |
-
|
306 |
-
/**
|
307 |
-
* GDPR Module - Cookie Policy Page
|
308 |
-
*/
|
309 |
-
public function get_section_cookiepolicy() {
|
310 |
-
$view_controller = new GDPR_Modules_View();
|
311 |
-
$modal_options = $this->gdpr_options;
|
312 |
-
$wpml_lang = $this->wpml_lang;
|
313 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
314 |
-
$layout = isset( $modal_options['moove_gdpr_plugin_layout'] ) ? $modal_options['moove_gdpr_plugin_layout'] : 'v1';
|
315 |
-
$tab_title = isset( $modal_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] ) && $modal_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] ? $modal_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] : __('3rd Party Cookies','gdpr-cookie-compliance');
|
316 |
-
$tab_content = isset( $modal_options['moove_gdpr_cookies_policy_tab_content'.$wpml_lang] ) && $modal_options['moove_gdpr_cookies_policy_tab_content'.$wpml_lang] ? $modal_options['moove_gdpr_cookies_policy_tab_content'.$wpml_lang] : $gdpr_default_content->moove_gdpr_get_cookie_policy_content();
|
317 |
-
$data = new stdClass();
|
318 |
-
$data->options = $modal_options;
|
319 |
-
$data->wpml_lang = $wpml_lang;
|
320 |
-
$data->tab_title = $tab_title;
|
321 |
-
$data->tab_content = wpautop( $tab_content );
|
322 |
-
$data->show = isset( $modal_options['moove_gdpr_cookie_policy_enable'] ) && intval( $modal_options['moove_gdpr_cookie_policy_enable'] ) === 1 ? true : false;
|
323 |
-
$data->visibility = $layout === 'v1' ? 'style="display:none"' : '';
|
324 |
-
return $view_controller->load( 'modal.content-sections.cookiepolicy', $data );
|
325 |
-
}
|
326 |
-
|
327 |
-
/**
|
328 |
-
* GDPR Module - Footer Button inside the Modal
|
329 |
-
*/
|
330 |
-
public function get_tab_footer_buttons() {
|
331 |
-
$view_controller = new GDPR_Modules_View();
|
332 |
-
$modal_options = $this->gdpr_options;
|
333 |
-
$wpml_lang = $this->wpml_lang;
|
334 |
-
$data = new stdClass();
|
335 |
-
$data->allow_label = isset( $modal_options['moove_gdpr_modal_allow_button_label'.$wpml_lang] ) && $modal_options['moove_gdpr_modal_allow_button_label'.$wpml_lang] ? $modal_options['moove_gdpr_modal_allow_button_label'.$wpml_lang] : __('Enable All','gdpr-cookie-compliance');
|
336 |
-
$data->settings_label = isset( $modal_options['moove_gdpr_modal_save_button_label'.$wpml_lang] ) && $modal_options['moove_gdpr_modal_save_button_label'.$wpml_lang] ? $modal_options['moove_gdpr_modal_save_button_label'.$wpml_lang] : __('Save Settings','gdpr-cookie-compliance');
|
337 |
-
|
338 |
-
return $view_controller->load( 'modal.tab-footer-buttons', $data );
|
339 |
-
}
|
340 |
-
|
341 |
-
/**
|
342 |
-
* GDPR Module - Navigation inside the modal
|
343 |
-
*/
|
344 |
-
public function get_tab_navigation() {
|
345 |
-
$view_controller = new GDPR_Modules_View();
|
346 |
-
$modal_options = $this->gdpr_options;
|
347 |
-
$wpml_lang = $this->wpml_lang;
|
348 |
-
$strictly = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? intval( $modal_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) : 1;
|
349 |
-
$data = new stdClass();
|
350 |
-
$data->overview = new stdClass();
|
351 |
-
$data->strictly = new stdClass();
|
352 |
-
$data->advanced = new stdClass();
|
353 |
-
$data->third_party = new stdClass();
|
354 |
-
$data->cookiepolicy = new stdClass();
|
355 |
-
|
356 |
-
// OVERVIEW
|
357 |
-
$data->overview->nav_label = isset( $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] : __('Privacy Overview','gdpr-cookie-compliance');
|
358 |
-
|
359 |
-
// STRICTLY
|
360 |
-
$data->strictly->show = $strictly !== 3;
|
361 |
-
$data->strictly->nav_label = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] : __('Strictly Necessary Cookies','gdpr-cookie-compliance');
|
362 |
-
|
363 |
-
// THIRD PARTY
|
364 |
-
$data->third_party->show = isset( $modal_options['moove_gdpr_third_party_cookies_enable'] ) && intval( $modal_options['moove_gdpr_third_party_cookies_enable'] ) === 1 ? true : false;
|
365 |
-
$data->third_party->nav_label = isset( $modal_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] : __('3rd Party Cookies','gdpr-cookie-compliance');
|
366 |
-
|
367 |
-
// ADVANCED
|
368 |
-
$data->advanced->show = isset( $modal_options['moove_gdpr_advanced_cookies_enable'] ) && intval( $modal_options['moove_gdpr_advanced_cookies_enable'] ) === 1 ? true : false;
|
369 |
-
$data->advanced->nav_label = isset( $modal_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] : __('Additional Cookies','gdpr-cookie-compliance');
|
370 |
-
|
371 |
-
// COOKIEPOLICY
|
372 |
-
$data->cookiepolicy->show = isset( $modal_options['moove_gdpr_cookie_policy_enable'] ) && intval( $modal_options['moove_gdpr_cookie_policy_enable'] ) === 1 ? true : false;
|
373 |
-
$data->cookiepolicy->nav_label = isset( $modal_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] ) && $modal_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] ? $modal_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] : __('Cookie Policy','gdpr-cookie-compliance');
|
374 |
-
|
375 |
-
return $view_controller->load( 'modal.tab-navigation', $data );
|
376 |
-
}
|
377 |
-
|
378 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_i
|
|
4 |
Stable tag: trunk
|
5 |
Tags: gdpr, compliance, cookie, consent, notice
|
6 |
Requires at least: 4.5
|
7 |
-
Tested up to: 5.
|
8 |
Requires PHP: 5.6 or higher
|
9 |
License: GPLv2
|
10 |
|
@@ -181,6 +181,12 @@ THIS PLUGIN DOES NOT MAKE YOUR WEBSITE COMPLIANT. YOU ARE RESPONSIBLE FOR ENSURI
|
|
181 |
32. GDPR Cookie Compliance - Admin - Language Specific Scripts [Premium]
|
182 |
|
183 |
== Changelog ==
|
|
|
|
|
|
|
|
|
|
|
|
|
184 |
= 3.1.1 =
|
185 |
* Minor CSS fixes
|
186 |
* Forum links updated
|
4 |
Stable tag: trunk
|
5 |
Tags: gdpr, compliance, cookie, consent, notice
|
6 |
Requires at least: 4.5
|
7 |
+
Tested up to: 5.3
|
8 |
Requires PHP: 5.6 or higher
|
9 |
License: GPLv2
|
10 |
|
181 |
32. GDPR Cookie Compliance - Admin - Language Specific Scripts [Premium]
|
182 |
|
183 |
== Changelog ==
|
184 |
+
= 3.2.0 =
|
185 |
+
* Improved code quality
|
186 |
+
* Security & Sanitize functions extended
|
187 |
+
* Added reset settings button
|
188 |
+
* Bugfixes
|
189 |
+
|
190 |
= 3.1.1 =
|
191 |
* Minor CSS fixes
|
192 |
* Forum links updated
|
views/moove/admin/settings/accept-on-scroll.php
CHANGED
@@ -1,4 +1,12 @@
|
|
1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
<hr />
|
3 |
-
|
4 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Accept Cookies on Scroll File Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
?>
|
10 |
+
<h2><?php esc_html_e('Accept Cookies on Scroll','gdpr-cookie-compliance'); ?></h2>
|
11 |
<hr />
|
|
|
12 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
views/moove/admin/settings/advanced-cookies.php
ADDED
@@ -0,0 +1,253 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Advanced Cookies File Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
11 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
12 |
+
$gdpr_options = get_option( $option_name );
|
13 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
14 |
+
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
15 |
+
$empty_scripts = false;
|
16 |
+
if ( isset( $_POST['moove_gdpr_nonce'] ) && wp_verify_nonce( sanitize_key( wp_unslash( $_POST['moove_gdpr_nonce'] ) ), 'moove_gdpr_nonce_field' ) && isset( $_POST ) && is_array( $_POST ) ) :
|
17 |
+
if ( isset( $_POST['moove_gdpr_advanced_cookies_enable'] ) ) :
|
18 |
+
$value = 1;
|
19 |
+
else :
|
20 |
+
$value = 0;
|
21 |
+
endif;
|
22 |
+
|
23 |
+
$gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] = 0;
|
24 |
+
if ( isset( $_POST['moove_gdpr_advanced_cookies_enable_first_visit'] ) ) :
|
25 |
+
$gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] = 1;
|
26 |
+
endif;
|
27 |
+
update_option( $option_name, $gdpr_options );
|
28 |
+
|
29 |
+
$gdpr_options = get_option( $option_name );
|
30 |
+
$gdpr_options['moove_gdpr_advanced_cookies_enable'] = $value;
|
31 |
+
update_option( $option_name, $gdpr_options );
|
32 |
+
$gdpr_options = get_option( $option_name );
|
33 |
+
foreach ( $_POST as $form_key => $form_value ) :
|
34 |
+
if ( 'moove_gdpr_advanced_cookies_tab_content' === $form_key ) :
|
35 |
+
$value = wp_unslash( $form_value );
|
36 |
+
$gdpr_options[ $form_key . $wpml_lang ] = $value;
|
37 |
+
update_option( $option_name, $gdpr_options );
|
38 |
+
$gdpr_options = get_option( $option_name );
|
39 |
+
elseif ( 'moove_gdpr_advanced_cookies_header_scripts' === $form_key || 'moove_gdpr_advanced_cookies_body_scripts' === $form_key || 'moove_gdpr_advanced_cookies_footer_scripts' === $form_key ) :
|
40 |
+
$value = wp_unslash( $form_value );
|
41 |
+
$gdpr_options[ $form_key ] = maybe_serialize( $value );
|
42 |
+
update_option( $option_name, $gdpr_options );
|
43 |
+
$gdpr_options = get_option( $option_name );
|
44 |
+
elseif ( 'moove_gdpr_advanced_cookies_enable' !== $form_key && 'moove_gdpr_advanced_cookies_enable_first_visit' !== $form_key ) :
|
45 |
+
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
46 |
+
$gdpr_options[ $form_key ] = $value;
|
47 |
+
update_option( $option_name, $gdpr_options );
|
48 |
+
$gdpr_options = get_option( $option_name );
|
49 |
+
endif;
|
50 |
+
endforeach;
|
51 |
+
|
52 |
+
do_action( 'gdpr_ps_check_language_extensions', $empty_scripts, $_POST, 'advanced' );
|
53 |
+
do_action( 'gdpr_cookie_filter_settings' );
|
54 |
+
$gdpr_options = get_option( $option_name );
|
55 |
+
endif;
|
56 |
+
?>
|
57 |
+
<script>
|
58 |
+
jQuery('#moove-gdpr-setting-error-settings_scripts_empty').hide();
|
59 |
+
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
60 |
+
</script>
|
61 |
+
<?php
|
62 |
+
$nav_label = isset( $gdpr_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] ? $gdpr_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] : __( 'Additional Cookies', 'gdpr-cookie-compliance' );
|
63 |
+
?>
|
64 |
+
<h2><?php echo esc_attr( $nav_label ); ?></h2>
|
65 |
+
<hr />
|
66 |
+
<form action="?page=moove-gdpr&tab=advanced-cookies" method="post" id="moove_gdpr_tab_advanced_cookies">
|
67 |
+
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
68 |
+
<table class="form-table <?php echo $empty_scripts ? 'moove-gdpr-form-error' : ''; ?>">
|
69 |
+
<tbody>
|
70 |
+
<tr>
|
71 |
+
<th scope="row">
|
72 |
+
<label for="moove_gdpr_advanced_cookies_enable"><?php esc_html_e( 'Turn', 'gdpr-cookie-compliance' ); ?></label>
|
73 |
+
</th>
|
74 |
+
<td>
|
75 |
+
<!-- GDPR Rounded switch -->
|
76 |
+
<label class="gdpr-checkbox-toggle">
|
77 |
+
<input type="checkbox" name="moove_gdpr_advanced_cookies_enable" id="moove_gdpr_advanced_cookies_enable" <?php echo isset( $gdpr_options['moove_gdpr_advanced_cookies_enable'] ) ? ( intval( $gdpr_options['moove_gdpr_advanced_cookies_enable'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_advanced_cookies_enable'] ) ? 'checked' : '' ) ) : ''; ?> >
|
78 |
+
<span class="gdpr-checkbox-slider" data-enable="<?php esc_html_e( 'On', 'gdpr-cookie-compliance' ); ?>" data-disable="<?php esc_html_e( 'Off', 'gdpr-cookie-compliance' ); ?>"></span>
|
79 |
+
</label>
|
80 |
+
</td>
|
81 |
+
</tr>
|
82 |
+
|
83 |
+
<tr>
|
84 |
+
<th scope="row">
|
85 |
+
<label for="moove_gdpr_advanced_cookies_enable_first_visit"><?php esc_html_e( 'Default status', 'gdpr-cookie-compliance' ); ?></label>
|
86 |
+
<p class="description"><?php esc_html_e( 'by default cookies should be', 'gdpr-cookie-compliance' ); ?>:</p>
|
87 |
+
<!-- .description -->
|
88 |
+
</th>
|
89 |
+
<td style="vertical-align: top; padding-top: 20px">
|
90 |
+
<!-- GDPR Rounded switch -->
|
91 |
+
<label class="gdpr-checkbox-toggle">
|
92 |
+
<input type="checkbox" name="moove_gdpr_advanced_cookies_enable_first_visit" id="moove_gdpr_advanced_cookies_enable_first_visit" <?php echo isset( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) ? ( intval( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) ? 'checked' : '' ) ) : ''; ?> >
|
93 |
+
<span class="gdpr-checkbox-slider" data-enable="<?php esc_html_e( 'Enabled', 'gdpr-cookie-compliance' ); ?>" data-disable="<?php esc_html_e( 'Disabled', 'gdpr-cookie-compliance' ); ?>"></span>
|
94 |
+
</label>
|
95 |
+
|
96 |
+
</td>
|
97 |
+
</tr>
|
98 |
+
|
99 |
+
<tr>
|
100 |
+
<th scope="row">
|
101 |
+
<label for="moove_gdpr_advanced_cookies_tab_title"><?php esc_html_e( 'Tab Title', 'gdpr-cookie-compliance' ); ?></label>
|
102 |
+
</th>
|
103 |
+
<td>
|
104 |
+
<input name="moove_gdpr_advanced_cookies_tab_title<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_advanced_cookies_tab_title" value="<?php echo esc_attr( $nav_label ); ?>" class="regular-text">
|
105 |
+
</td>
|
106 |
+
</tr>
|
107 |
+
|
108 |
+
<tr>
|
109 |
+
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
110 |
+
<label for="moove_gdpr_advanced_cookies_tab_content"><?php esc_html_e( 'Tab Content', 'gdpr-cookie-compliance' ); ?></label>
|
111 |
+
</th>
|
112 |
+
</tr>
|
113 |
+
<tr class="moove_gdpr_table_form_holder">
|
114 |
+
<th colspan="2" scope="row">
|
115 |
+
<?php
|
116 |
+
$content = isset( $gdpr_options[ 'moove_gdpr_advanced_cookies_tab_content' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_advanced_cookies_tab_content' . $wpml_lang ] ? maybe_unserialize( $gdpr_options[ 'moove_gdpr_advanced_cookies_tab_content' . $wpml_lang ] ) : false;
|
117 |
+
if ( ! $content ) :
|
118 |
+
$content = $gdpr_default_content->moove_gdpr_get_advanced_cookies_content();
|
119 |
+
endif;
|
120 |
+
?>
|
121 |
+
<?php
|
122 |
+
$settings = array(
|
123 |
+
'media_buttons' => false,
|
124 |
+
'editor_height' => 150,
|
125 |
+
);
|
126 |
+
wp_editor( $content, 'moove_gdpr_advanced_cookies_tab_content', $settings );
|
127 |
+
?>
|
128 |
+
</th>
|
129 |
+
</tr>
|
130 |
+
</tbody>
|
131 |
+
</table>
|
132 |
+
|
133 |
+
<div class="gdpr-script-tab-content">
|
134 |
+
<hr />
|
135 |
+
<h3><?php esc_html_e( 'Paste your codes and snippets below. They will be added to all pages if user enables these cookies.', 'gdpr-cookie-compliance' ); ?></h3>
|
136 |
+
<div class="alert script-error" style="display: none;"><?php esc_html_e( 'Please fill out at least one of these fields:', 'gdpr-cookie-compliance' ); ?></div>
|
137 |
+
<div class="gdpr-tab-code-section-nav">
|
138 |
+
<ul>
|
139 |
+
<li>
|
140 |
+
<a href="#advnaced_cookies_head" class="gdpr-active"><?php esc_html_e( 'Head Section', 'gdpr-cookie-compliance' ); ?></a>
|
141 |
+
</li>
|
142 |
+
<li>
|
143 |
+
<a href="#advnaced_cookies_body"><?php esc_html_e( 'Body Section', 'gdpr-cookie-compliance' ); ?></a>
|
144 |
+
</li>
|
145 |
+
<li>
|
146 |
+
<a href="#advnaced_cookies_footer"><?php esc_html_e( 'Footer Section', 'gdpr-cookie-compliance' ); ?></a>
|
147 |
+
</li>
|
148 |
+
<?php do_action( 'gdpr_tab_code_section_nav_extension', 'advanced' ); ?>
|
149 |
+
</ul>
|
150 |
+
</div>
|
151 |
+
<!-- .gdpr-tab-code-section-nav -->
|
152 |
+
<div class="gdpr-script-tabs-main-cnt">
|
153 |
+
|
154 |
+
<div class="gdpr-tab-code-section gdpr-active" id="advnaced_cookies_head">
|
155 |
+
<h4 for="moove_gdpr_advnaced_cookies_header_scripts"><?php esc_html_e( 'Add scripts that you would like to be inserted to the HEAD section of your pages when user accepts these cookies', 'gdpr-cookie-compliance' ); ?></h4>
|
156 |
+
<table>
|
157 |
+
<tbody>
|
158 |
+
<tr class="moove_gdpr_advanced_cookies_header_scripts">
|
159 |
+
<td scope="row" colspan="2" style="padding: 20px 0;">
|
160 |
+
<?php
|
161 |
+
$content = isset( $gdpr_options['moove_gdpr_advanced_cookies_header_scripts'] ) && $gdpr_options['moove_gdpr_advanced_cookies_header_scripts'] ? maybe_unserialize( $gdpr_options['moove_gdpr_advanced_cookies_header_scripts'] ) : '';
|
162 |
+
?>
|
163 |
+
<textarea name="moove_gdpr_advanced_cookies_header_scripts" id="moove_gdpr_advanced_cookies_header_scripts" class="large-text code" rows="13"><?php apply_filters( 'gdpr_cc_keephtml', $content, true ); ?></textarea>
|
164 |
+
<div class="gdpr-code"></div>
|
165 |
+
<!-- .gdpr-code -->
|
166 |
+
<p class="description" id="moove_gdpr_advanced_cookies_header_scripts-description"><?php esc_html_e( 'For example, you can use it for Google Tag Manager script or any other 3rd party code snippets.', 'gdpr-cookie-compliance' ); ?></p>
|
167 |
+
</td>
|
168 |
+
</tr>
|
169 |
+
</tbody>
|
170 |
+
</table>
|
171 |
+
</div>
|
172 |
+
<!-- .gdpr-tab-code-section -->
|
173 |
+
|
174 |
+
<div class="gdpr-tab-code-section" id="advnaced_cookies_body">
|
175 |
+
<h4 for="moove_gdpr_advnaced_cookies_header_scripts"><?php esc_html_e( 'Add scripts that you would like to be inserted to the BODY section of your pages when user accepts these cookies', 'gdpr-cookie-compliance' ); ?></h4>
|
176 |
+
<table>
|
177 |
+
<tbody>
|
178 |
+
<tr class="moove_gdpr_advanced_cookies_body_scripts">
|
179 |
+
<td scope="row" colspan="2" style="padding: 20px 0;">
|
180 |
+
<?php
|
181 |
+
$content = isset( $gdpr_options['moove_gdpr_advanced_cookies_body_scripts'] ) && $gdpr_options['moove_gdpr_advanced_cookies_body_scripts'] ? maybe_unserialize( $gdpr_options['moove_gdpr_advanced_cookies_body_scripts'] ) : '';
|
182 |
+
?>
|
183 |
+
<textarea name="moove_gdpr_advanced_cookies_body_scripts" id="moove_gdpr_advanced_cookies_body_scripts" class="large-text code" rows="13"><?php apply_filters( 'gdpr_cc_keephtml', $content, true ); ?></textarea>
|
184 |
+
<div class="gdpr-code"></div>
|
185 |
+
<!-- .gdpr-code -->
|
186 |
+
<p class="description" id="moove_gdpr_advanced_cookies_body_scripts-description"><?php esc_html_e( 'For example, you can use it for Google Tag Manager script or any other 3rd party code snippets.', 'gdpr-cookie-compliance' ); ?></p>
|
187 |
+
</td>
|
188 |
+
</tr>
|
189 |
+
</tbody>
|
190 |
+
</table>
|
191 |
+
</div>
|
192 |
+
<!-- .gdpr-tab-code-section -->
|
193 |
+
|
194 |
+
<div class="gdpr-tab-code-section" id="advnaced_cookies_footer">
|
195 |
+
<h4 for="moove_gdpr_advnaced_cookies_header_scripts"><?php esc_html_e( 'Add scripts that you would like to be inserted to the FOOTER section of your pages when user accepts these cookies', 'gdpr-cookie-compliance' ); ?></h4>
|
196 |
+
<table>
|
197 |
+
<tbody>
|
198 |
+
<tr class="moove_gdpr_advanced_cookies_footer_scripts">
|
199 |
+
<td scope="row" colspan="2" style="padding: 20px 0;">
|
200 |
+
<?php
|
201 |
+
$content = isset( $gdpr_options['moove_gdpr_advanced_cookies_footer_scripts'] ) && $gdpr_options['moove_gdpr_advanced_cookies_footer_scripts'] ? wp_unslash( $gdpr_options['moove_gdpr_advanced_cookies_footer_scripts'] ) : '';
|
202 |
+
?>
|
203 |
+
<textarea name="moove_gdpr_advanced_cookies_footer_scripts" id="moove_gdpr_advanced_cookies_footer_scripts" class="large-text code" rows="13"><?php apply_filters( 'gdpr_cc_keephtml', $content, true ); ?></textarea>
|
204 |
+
<div class="gdpr-code"></div>
|
205 |
+
<!-- .gdpr-code -->
|
206 |
+
<p class="description" id="moove_gdpr_advanced_cookies_footer_scripts-description"><?php esc_html_e( 'For example, you can use it for Google Analytics script or any other 3rd party code snippets.', 'gdpr-cookie-compliance' ); ?></p>
|
207 |
+
</td>
|
208 |
+
</tr>
|
209 |
+
</tbody>
|
210 |
+
</table>
|
211 |
+
</div>
|
212 |
+
<!-- .gdpr-tab-code-section -->
|
213 |
+
|
214 |
+
<?php do_action( 'gdpr_tab_code_section_content_extension', 'advanced' ); ?>
|
215 |
+
</div>
|
216 |
+
<!-- .gdpr-script-tabs-main-cnt -->
|
217 |
+
</div>
|
218 |
+
<!-- .gdpr-script-tab-content -->
|
219 |
+
|
220 |
+
<hr />
|
221 |
+
<br />
|
222 |
+
<button type="submit" class="button button-primary">
|
223 |
+
<?php esc_html_e( 'Save changes', 'gdpr-cookie-compliance' ); ?>
|
224 |
+
</button>
|
225 |
+
|
226 |
+
<script type="text/javascript" src="<?php echo esc_url( moove_gdpr_get_plugin_directory_url() ); ?>/dist/scripts/codemirror.js"></script>
|
227 |
+
<script type="text/javascript">
|
228 |
+
window.onload = function() {
|
229 |
+
jQuery('.gdpr-tab-section-cnt textarea.code').each(function(){
|
230 |
+
if (typeof CodeMirror === "function") {
|
231 |
+
var element = jQuery(this).closest('tr').find('.gdpr-code')[0];
|
232 |
+
var id = jQuery(this).attr('id');
|
233 |
+
jQuery(this).css({
|
234 |
+
'opacity' : '0',
|
235 |
+
'height' : '0',
|
236 |
+
});
|
237 |
+
var editor = CodeMirror( element, {
|
238 |
+
mode: "text/html",
|
239 |
+
lineWrapping: true,
|
240 |
+
lineNumbers: true,
|
241 |
+
value: document.getElementById(id).value
|
242 |
+
});
|
243 |
+
editor.on('change',function(cMirror){
|
244 |
+
// get value right from instance
|
245 |
+
document.getElementById(id).innerHTML = cMirror.getValue();
|
246 |
+
});
|
247 |
+
} else {
|
248 |
+
jQuery('.gdpr-code').hide();
|
249 |
+
}
|
250 |
+
});
|
251 |
+
};
|
252 |
+
</script>
|
253 |
+
</form>
|
views/moove/admin/settings/advanced_cookies.php
DELETED
@@ -1,254 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
3 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
4 |
-
$gdpr_options = get_option( $option_name );
|
5 |
-
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
6 |
-
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
7 |
-
$empty_scripts = false;
|
8 |
-
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
9 |
-
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
10 |
-
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
11 |
-
die( 'Security check' );
|
12 |
-
else :
|
13 |
-
if ( is_array( $_POST ) ) :
|
14 |
-
if ( isset( $_POST['moove_gdpr_advanced_cookies_enable'] ) ) :
|
15 |
-
$value = 1;
|
16 |
-
else :
|
17 |
-
$value = 0;
|
18 |
-
endif;
|
19 |
-
|
20 |
-
$gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] = 0;
|
21 |
-
if ( isset( $_POST['moove_gdpr_advanced_cookies_enable_first_visit'] ) ) :
|
22 |
-
$gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] = 1;
|
23 |
-
endif;
|
24 |
-
update_option( $option_name, $gdpr_options );
|
25 |
-
|
26 |
-
$gdpr_options = get_option( $option_name );
|
27 |
-
$gdpr_options['moove_gdpr_advanced_cookies_enable'] = $value;
|
28 |
-
update_option( $option_name, $gdpr_options );
|
29 |
-
$gdpr_options = get_option( $option_name );
|
30 |
-
foreach ( $_POST as $form_key => $form_value ) :
|
31 |
-
if ( $form_key === 'moove_gdpr_advanced_cookies_tab_content' ) :
|
32 |
-
$value = wp_unslash( $form_value );
|
33 |
-
$gdpr_options[$form_key.$wpml_lang] = $value;
|
34 |
-
update_option( $option_name, $gdpr_options );
|
35 |
-
$gdpr_options = get_option( $option_name );
|
36 |
-
elseif ( $form_key === 'moove_gdpr_advanced_cookies_header_scripts' || $form_key === 'moove_gdpr_advanced_cookies_body_scripts' || $form_key === 'moove_gdpr_advanced_cookies_footer_scripts' ) :
|
37 |
-
$value = wp_unslash( $form_value );
|
38 |
-
$gdpr_options[$form_key] = maybe_serialize( $value );
|
39 |
-
update_option( $option_name, $gdpr_options );
|
40 |
-
$gdpr_options = get_option( $option_name );
|
41 |
-
|
42 |
-
elseif ( $form_key !== 'moove_gdpr_advanced_cookies_enable' && $form_key !== 'moove_gdpr_advanced_cookies_enable_first_visit' ) :
|
43 |
-
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
44 |
-
$gdpr_options[$form_key] = $value;
|
45 |
-
update_option( $option_name, $gdpr_options );
|
46 |
-
$gdpr_options = get_option( $option_name );
|
47 |
-
endif;
|
48 |
-
endforeach;
|
49 |
-
|
50 |
-
do_action( 'gdpr_ps_check_language_extensions', $empty_scripts, $_POST, 'advanced' );
|
51 |
-
do_action( 'gdpr_cookie_filter_settings' );
|
52 |
-
$gdpr_options = get_option( $option_name );
|
53 |
-
endif;
|
54 |
-
?>
|
55 |
-
|
56 |
-
<script>
|
57 |
-
jQuery('#moove-gdpr-setting-error-settings_scripts_empty').hide();
|
58 |
-
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
59 |
-
</script>
|
60 |
-
<?php
|
61 |
-
endif;
|
62 |
-
endif;
|
63 |
-
|
64 |
-
?>
|
65 |
-
<?php
|
66 |
-
$nav_label = isset( $gdpr_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] ) && $gdpr_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] ? $gdpr_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] : __('Additional Cookies','gdpr-cookie-compliance');
|
67 |
-
?>
|
68 |
-
<h2><?php echo $nav_label; ?></h2>
|
69 |
-
<hr />
|
70 |
-
<form action="?page=moove-gdpr&tab=advanced_cookies" method="post" id="moove_gdpr_tab_advanced_cookies">
|
71 |
-
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
72 |
-
<table class="form-table <?php echo $empty_scripts ? 'moove-gdpr-form-error' : ''; ?>">
|
73 |
-
<tbody>
|
74 |
-
<tr>
|
75 |
-
<th scope="row">
|
76 |
-
<label for="moove_gdpr_advanced_cookies_enable"><?php _e('Turn','gdpr-cookie-compliance'); ?></label>
|
77 |
-
</th>
|
78 |
-
<td>
|
79 |
-
<!-- GDPR Rounded switch -->
|
80 |
-
<label class="gdpr-checkbox-toggle">
|
81 |
-
<input type="checkbox" name="moove_gdpr_advanced_cookies_enable" id="moove_gdpr_advanced_cookies_enable" <?php echo isset( $gdpr_options['moove_gdpr_advanced_cookies_enable'] ) ? ( intval( $gdpr_options['moove_gdpr_advanced_cookies_enable'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_advanced_cookies_enable'] ) ? 'checked' : '' ) ) : ''; ?> >
|
82 |
-
<span class="gdpr-checkbox-slider" data-enable="<?php _e('On','gdpr-cookie-compliance'); ?>" data-disable="<?php _e('Off','gdpr-cookie-compliance'); ?>"></span>
|
83 |
-
</label>
|
84 |
-
</td>
|
85 |
-
</tr>
|
86 |
-
|
87 |
-
<tr>
|
88 |
-
<th scope="row">
|
89 |
-
<label for="moove_gdpr_advanced_cookies_enable_first_visit"><?php _e('Default status','gdpr-cookie-compliance'); ?></label>
|
90 |
-
<p class="description"><?php _e('by default cookies should be','gdpr-cookie-compliance'); ?>:</p>
|
91 |
-
<!-- .description -->
|
92 |
-
</th>
|
93 |
-
<td style="vertical-align: top; padding-top: 20px">
|
94 |
-
<!-- GDPR Rounded switch -->
|
95 |
-
<label class="gdpr-checkbox-toggle">
|
96 |
-
<input type="checkbox" name="moove_gdpr_advanced_cookies_enable_first_visit" id="moove_gdpr_advanced_cookies_enable_first_visit" <?php echo isset( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) ? ( intval( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_advanced_cookies_enable_first_visit'] ) ? 'checked' : '' ) ) : ''; ?> >
|
97 |
-
<span class="gdpr-checkbox-slider" data-enable="<?php _e('Enabled','gdpr-cookie-compliance'); ?>" data-disable="<?php _e('Disabled','gdpr-cookie-compliance'); ?>"></span>
|
98 |
-
</label>
|
99 |
-
|
100 |
-
</td>
|
101 |
-
</tr>
|
102 |
-
|
103 |
-
<tr>
|
104 |
-
<th scope="row">
|
105 |
-
<label for="moove_gdpr_advanced_cookies_tab_title"><?php _e('Tab Title','gdpr-cookie-compliance'); ?></label>
|
106 |
-
</th>
|
107 |
-
<td>
|
108 |
-
<input name="moove_gdpr_advanced_cookies_tab_title<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_advanced_cookies_tab_title" value="<?php echo $nav_label; ?>" class="regular-text">
|
109 |
-
</td>
|
110 |
-
</tr>
|
111 |
-
|
112 |
-
<tr>
|
113 |
-
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
114 |
-
<label for="moove_gdpr_advanced_cookies_tab_content"><?php _e('Tab Content','gdpr-cookie-compliance'); ?></label>
|
115 |
-
</th>
|
116 |
-
</tr>
|
117 |
-
<tr class="moove_gdpr_table_form_holder">
|
118 |
-
<th colspan="2" scope="row">
|
119 |
-
<?php
|
120 |
-
$content = isset( $gdpr_options['moove_gdpr_advanced_cookies_tab_content'.$wpml_lang] ) && $gdpr_options['moove_gdpr_advanced_cookies_tab_content'.$wpml_lang] ? maybe_unserialize( $gdpr_options['moove_gdpr_advanced_cookies_tab_content'.$wpml_lang] ) : false;
|
121 |
-
if ( ! $content ) :
|
122 |
-
$content = $gdpr_default_content->moove_gdpr_get_advanced_cookies_content();
|
123 |
-
endif;
|
124 |
-
?>
|
125 |
-
<?php
|
126 |
-
$settings = array (
|
127 |
-
'media_buttons' => false,
|
128 |
-
'editor_height' => 150,
|
129 |
-
);
|
130 |
-
wp_editor( $content, 'moove_gdpr_advanced_cookies_tab_content', $settings );
|
131 |
-
?>
|
132 |
-
</th>
|
133 |
-
</tr>
|
134 |
-
</tbody>
|
135 |
-
</table>
|
136 |
-
|
137 |
-
<div class="gdpr-script-tab-content">
|
138 |
-
<hr />
|
139 |
-
<h3><?php _e('Paste your codes and snippets below. They will be added to all pages if user enables these cookies.','gdpr-cookie-compliance'); ?></h3>
|
140 |
-
<div class="alert script-error" style="display: none;"><?php _e('Please fill out at least one of these fields:','gdpr-cookie-compliance'); ?></div>
|
141 |
-
|
142 |
-
<div class="gdpr-tab-code-section-nav">
|
143 |
-
<ul>
|
144 |
-
<li>
|
145 |
-
<a href="#advnaced_cookies_head" class="gdpr-active"><?php _e('Head Section','gdpr-cookie-compliance'); ?></a>
|
146 |
-
</li>
|
147 |
-
<li>
|
148 |
-
<a href="#advnaced_cookies_body"><?php _e('Body Section','gdpr-cookie-compliance'); ?></a>
|
149 |
-
</li>
|
150 |
-
<li>
|
151 |
-
<a href="#advnaced_cookies_footer"><?php _e('Footer Section','gdpr-cookie-compliance'); ?></a>
|
152 |
-
</li>
|
153 |
-
<?php do_action('gdpr_tab_code_section_nav_extension', 'advanced'); ?>
|
154 |
-
</ul>
|
155 |
-
</div>
|
156 |
-
<!-- .gdpr-tab-code-section-nav -->
|
157 |
-
<div class="gdpr-script-tabs-main-cnt">
|
158 |
-
|
159 |
-
<div class="gdpr-tab-code-section gdpr-active" id="advnaced_cookies_head">
|
160 |
-
<h4 for="moove_gdpr_advnaced_cookies_header_scripts"><?php _e('Add scripts that you would like to be inserted to the HEAD section of your pages when user accepts these cookies','gdpr-cookie-compliance'); ?></h4>
|
161 |
-
<table>
|
162 |
-
<tbody>
|
163 |
-
<tr class="moove_gdpr_advanced_cookies_header_scripts">
|
164 |
-
<td scope="row" colspan="2" style="padding: 20px 0;">
|
165 |
-
<?php $content = isset( $gdpr_options['moove_gdpr_advanced_cookies_header_scripts'] ) && $gdpr_options['moove_gdpr_advanced_cookies_header_scripts'] ? maybe_unserialize( $gdpr_options['moove_gdpr_advanced_cookies_header_scripts'] ) : '';
|
166 |
-
?>
|
167 |
-
<textarea name="moove_gdpr_advanced_cookies_header_scripts" id="moove_gdpr_advanced_cookies_header_scripts" class="large-text code" rows="13"><?php echo $content; ?></textarea>
|
168 |
-
<div class="gdpr-code"></div>
|
169 |
-
<!-- .gdpr-code -->
|
170 |
-
<p class="description" id="moove_gdpr_advanced_cookies_header_scripts-description"><?php _e('For example, you can use it for Google Tag Manager script or any other 3rd party code snippets.','gdpr-cookie-compliance'); ?></p>
|
171 |
-
</td>
|
172 |
-
</tr>
|
173 |
-
</tbody>
|
174 |
-
</table>
|
175 |
-
</div>
|
176 |
-
<!-- .gdpr-tab-code-section -->
|
177 |
-
|
178 |
-
<div class="gdpr-tab-code-section" id="advnaced_cookies_body">
|
179 |
-
<h4 for="moove_gdpr_advnaced_cookies_header_scripts"><?php _e('Add scripts that you would like to be inserted to the BODY section of your pages when user accepts these cookies','gdpr-cookie-compliance'); ?></h4>
|
180 |
-
<table>
|
181 |
-
<tbody>
|
182 |
-
<tr class="moove_gdpr_advanced_cookies_body_scripts">
|
183 |
-
<td scope="row" colspan="2" style="padding: 20px 0;">
|
184 |
-
<?php $content = isset( $gdpr_options['moove_gdpr_advanced_cookies_body_scripts'] ) && $gdpr_options['moove_gdpr_advanced_cookies_body_scripts'] ? maybe_unserialize( $gdpr_options['moove_gdpr_advanced_cookies_body_scripts'] ) : '';
|
185 |
-
?>
|
186 |
-
<textarea name="moove_gdpr_advanced_cookies_body_scripts" id="moove_gdpr_advanced_cookies_body_scripts" class="large-text code" rows="13"><?php echo $content; ?></textarea>
|
187 |
-
<div class="gdpr-code"></div>
|
188 |
-
<!-- .gdpr-code -->
|
189 |
-
<p class="description" id="moove_gdpr_advanced_cookies_body_scripts-description"><?php _e('For example, you can use it for Google Tag Manager script or any other 3rd party code snippets.','gdpr-cookie-compliance'); ?></p>
|
190 |
-
</td>
|
191 |
-
</tr>
|
192 |
-
</tbody>
|
193 |
-
</table>
|
194 |
-
</div>
|
195 |
-
<!-- .gdpr-tab-code-section -->
|
196 |
-
|
197 |
-
<div class="gdpr-tab-code-section" id="advnaced_cookies_footer">
|
198 |
-
<h4 for="moove_gdpr_advnaced_cookies_header_scripts"><?php _e('Add scripts that you would like to be inserted to the FOOTER section of your pages when user accepts these cookies','gdpr-cookie-compliance'); ?></h4>
|
199 |
-
<table>
|
200 |
-
<tbody>
|
201 |
-
<tr class="moove_gdpr_advanced_cookies_footer_scripts">
|
202 |
-
<td scope="row" colspan="2" style="padding: 20px 0;">
|
203 |
-
<?php $content = isset( $gdpr_options['moove_gdpr_advanced_cookies_footer_scripts'] ) && $gdpr_options['moove_gdpr_advanced_cookies_footer_scripts'] ? wp_unslash( $gdpr_options['moove_gdpr_advanced_cookies_footer_scripts'] ) : '';
|
204 |
-
?>
|
205 |
-
<textarea name="moove_gdpr_advanced_cookies_footer_scripts" id="moove_gdpr_advanced_cookies_footer_scripts" class="large-text code" rows="13"><?php echo $content; ?></textarea>
|
206 |
-
<div class="gdpr-code"></div>
|
207 |
-
<!-- .gdpr-code -->
|
208 |
-
<p class="description" id="moove_gdpr_advanced_cookies_footer_scripts-description"><?php _e('For example, you can use it for Google Analytics script or any other 3rd party code snippets.','gdpr-cookie-compliance'); ?></p>
|
209 |
-
</td>
|
210 |
-
</tr>
|
211 |
-
</tbody>
|
212 |
-
</table>
|
213 |
-
</div>
|
214 |
-
<!-- .gdpr-tab-code-section -->
|
215 |
-
|
216 |
-
<?php do_action('gdpr_tab_code_section_content_extension', 'advanced'); ?>
|
217 |
-
</div>
|
218 |
-
<!-- .gdpr-script-tabs-main-cnt -->
|
219 |
-
</div>
|
220 |
-
<!-- .gdpr-script-tab-content -->
|
221 |
-
|
222 |
-
<hr />
|
223 |
-
<br />
|
224 |
-
<button type="submit" class="button button-primary"><?php _e('Save changes','gdpr-cookie-compliance'); ?></button>
|
225 |
-
|
226 |
-
<script type="text/javascript" src="<?php echo moove_gdpr_get_plugin_directory_url(); ?>/dist/scripts/codemirror.js"></script>
|
227 |
-
<script type="text/javascript">
|
228 |
-
window.onload = function() {
|
229 |
-
jQuery('.gdpr-tab-section-cnt textarea.code').each(function(){
|
230 |
-
if (typeof CodeMirror === "function") {
|
231 |
-
var element = jQuery(this).closest('tr').find('.gdpr-code')[0];
|
232 |
-
var id = jQuery(this).attr('id');
|
233 |
-
|
234 |
-
jQuery(this).css({
|
235 |
-
'opacity' : '0',
|
236 |
-
'height' : '0',
|
237 |
-
});
|
238 |
-
var editor = CodeMirror( element, {
|
239 |
-
mode: "text/html",
|
240 |
-
lineWrapping: true,
|
241 |
-
lineNumbers: true,
|
242 |
-
value: document.getElementById(id).value
|
243 |
-
});
|
244 |
-
editor.on('change',function(cMirror){
|
245 |
-
// get value right from instance
|
246 |
-
document.getElementById(id).innerHTML = cMirror.getValue();
|
247 |
-
});
|
248 |
-
} else {
|
249 |
-
jQuery('.gdpr-code').hide();
|
250 |
-
}
|
251 |
-
});
|
252 |
-
};
|
253 |
-
</script>
|
254 |
-
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
views/moove/admin/settings/banner-settings.php
ADDED
@@ -0,0 +1,198 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Banner Settings File Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
11 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
12 |
+
$gdpr_options = get_option( $option_name );
|
13 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
14 |
+
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
15 |
+
|
16 |
+
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
17 |
+
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
18 |
+
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
19 |
+
die( 'Security check' );
|
20 |
+
else :
|
21 |
+
if ( is_array( $_POST ) ) :
|
22 |
+
$restricted_keys = array(
|
23 |
+
'moove_gdpr_floating_button_enable',
|
24 |
+
'moove_gdpr_infobar_visibility',
|
25 |
+
'moove_gdpr_reject_button_enable',
|
26 |
+
'moove_gdpr_colour_scheme',
|
27 |
+
);
|
28 |
+
// Cookie Banner Visibility.
|
29 |
+
$moove_gdpr_infobar_visibility = 'hidden';
|
30 |
+
if ( isset( $_POST['moove_gdpr_infobar_visibility'] ) ) :
|
31 |
+
$moove_gdpr_infobar_visibility = 'visible';
|
32 |
+
endif;
|
33 |
+
$gdpr_options['moove_gdpr_infobar_visibility'] = $moove_gdpr_infobar_visibility;
|
34 |
+
|
35 |
+
// Cookie Banner Reject Button.
|
36 |
+
$moove_gdpr_reject_enable = '0';
|
37 |
+
if ( isset( $_POST['moove_gdpr_reject_button_enable'] ) ) :
|
38 |
+
$moove_gdpr_reject_enable = '1';
|
39 |
+
endif;
|
40 |
+
$gdpr_options['moove_gdpr_reject_button_enable'] = $moove_gdpr_reject_enable;
|
41 |
+
|
42 |
+
// Cookie Banner Colour Scheme.
|
43 |
+
$moove_gdpr_colour_scheme = '2';
|
44 |
+
|
45 |
+
if ( isset( $_POST['moove_gdpr_colour_scheme'] ) ) :
|
46 |
+
$moove_gdpr_colour_scheme = '1';
|
47 |
+
endif;
|
48 |
+
$gdpr_options['moove_gdpr_colour_scheme'] = $moove_gdpr_colour_scheme;
|
49 |
+
|
50 |
+
update_option( $option_name, $gdpr_options );
|
51 |
+
|
52 |
+
foreach ( $_POST as $form_key => $form_value ) :
|
53 |
+
if ( 'moove_gdpr_info_bar_content' === $form_key ) :
|
54 |
+
$value = wpautop( wp_unslash( $form_value ) );
|
55 |
+
$gdpr_options[ $form_key . $wpml_lang ] = $value;
|
56 |
+
update_option( $option_name, $gdpr_options );
|
57 |
+
$gdpr_options = get_option( $option_name );
|
58 |
+
elseif ( 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang === $form_key ) :
|
59 |
+
$value = wpautop( wp_unslash( $form_value ) );
|
60 |
+
$gdpr_options[ $form_key ] = $value;
|
61 |
+
update_option( $option_name, $gdpr_options );
|
62 |
+
$gdpr_options = get_option( $option_name );
|
63 |
+
elseif ( ! in_array( $form_key, $restricted_keys ) ) :
|
64 |
+
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
65 |
+
$gdpr_options[ $form_key ] = $value;
|
66 |
+
update_option( $option_name, $gdpr_options );
|
67 |
+
$gdpr_options = get_option( $option_name );
|
68 |
+
endif;
|
69 |
+
endforeach;
|
70 |
+
endif;
|
71 |
+
do_action( 'gdpr_cookie_filter_settings' );
|
72 |
+
?>
|
73 |
+
<script>
|
74 |
+
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
75 |
+
</script>
|
76 |
+
<?php
|
77 |
+
endif;
|
78 |
+
endif;
|
79 |
+
?>
|
80 |
+
<form action="<?php echo esc_url( admin_url( '?page=moove-gdpr&tab=banner-settings' ) ); ?>" method="post" id="moove_gdpr_tab_banner_settings">
|
81 |
+
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
82 |
+
<h2><?php esc_html_e( 'Cookie Banner Settings', 'gdpr-cookie-compliance' ); ?></h2>
|
83 |
+
<hr />
|
84 |
+
|
85 |
+
<table class="form-table">
|
86 |
+
<tbody>
|
87 |
+
<tr>
|
88 |
+
<th scope="row">
|
89 |
+
<label for="moove_gdpr_infobar_visibility"><?php esc_html_e( 'Turn', 'gdpr-cookie-compliance' ); ?></label>
|
90 |
+
</th>
|
91 |
+
<td>
|
92 |
+
<!-- GDPR Rounded switch -->
|
93 |
+
<label class="gdpr-checkbox-toggle">
|
94 |
+
<input type="checkbox" name="moove_gdpr_infobar_visibility" <?php echo isset( $gdpr_options['moove_gdpr_infobar_visibility'] ) ? ( 'visible' === $gdpr_options['moove_gdpr_infobar_visibility'] ? 'checked' : '' ) : 'checked'; ?> >
|
95 |
+
<span class="gdpr-checkbox-slider" data-enable="<?php esc_html_e( 'On', 'gdpr-cookie-compliance' ); ?>" data-disable="<?php esc_html_e( 'Off', 'gdpr-cookie-compliance' ); ?>"></span>
|
96 |
+
</label>
|
97 |
+
<?php do_action( 'gdpr_cc_moove_gdpr_infobar_visibility_settings' ); ?>
|
98 |
+
</td>
|
99 |
+
</tr>
|
100 |
+
<tr>
|
101 |
+
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
102 |
+
<label for="moove_gdpr_info_bar_content"><?php esc_html_e( 'Cookie Banner Content', 'gdpr-cookie-compliance' ); ?></label>
|
103 |
+
</th>
|
104 |
+
</tr>
|
105 |
+
<tr class="moove_gdpr_table_form_holder">
|
106 |
+
<th colspan="2" scope="row">
|
107 |
+
<?php
|
108 |
+
$content = isset( $gdpr_options[ 'moove_gdpr_info_bar_content' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_info_bar_content' . $wpml_lang ] ? maybe_unserialize( $gdpr_options[ 'moove_gdpr_info_bar_content' . $wpml_lang ] ) : false;
|
109 |
+
if ( ! $content ) :
|
110 |
+
$_content = __( '<p>We are using cookies to give you the best experience on our website.</p><p>You can find out more about which cookies we are using or switch them off in [setting]settings[/setting].</p>', 'gdpr-cookie-compliance' );
|
111 |
+
$content = $_content;
|
112 |
+
endif;
|
113 |
+
?>
|
114 |
+
<?php
|
115 |
+
$settings = array(
|
116 |
+
'media_buttons' => false,
|
117 |
+
'editor_height' => 150,
|
118 |
+
'teeny' => false,
|
119 |
+
);
|
120 |
+
wp_editor( $content, 'moove_gdpr_info_bar_content', $settings );
|
121 |
+
?>
|
122 |
+
<p class="description">
|
123 |
+
<?php
|
124 |
+
$content = __( 'You can use the following shortcut to link the Cookie Settings Screen:<br><span><strong>[setting]</strong>settings<strong>[/setting]</strong></span>', 'gdpr-cookie-compliance' );
|
125 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
126 |
+
?>
|
127 |
+
</p>
|
128 |
+
</th>
|
129 |
+
</tr>
|
130 |
+
|
131 |
+
<tr>
|
132 |
+
<th scope="row">
|
133 |
+
<label for="moove_gdpr_infobar_accept_button_label"><?php esc_html_e( 'Accept - Button Label', 'gdpr-cookie-compliance' ); ?></label>
|
134 |
+
</th>
|
135 |
+
<td>
|
136 |
+
<input name="moove_gdpr_infobar_accept_button_label<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_infobar_accept_button_label" value="<?php echo isset( $gdpr_options[ 'moove_gdpr_infobar_accept_button_label' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_infobar_accept_button_label' . $wpml_lang ] ? esc_attr( $gdpr_options[ 'moove_gdpr_infobar_accept_button_label' . $wpml_lang ] ) : esc_attr__( 'Accept', 'gdpr-cookie-compliance' ); ?>" class="regular-text">
|
137 |
+
</td>
|
138 |
+
</tr>
|
139 |
+
<tr>
|
140 |
+
<th scope="row">
|
141 |
+
<label for="moove_gdpr_reject_button_enable"><?php esc_html_e( 'Reject button', 'gdpr-cookie-compliance-addon' ); ?></label>
|
142 |
+
</th>
|
143 |
+
<td>
|
144 |
+
|
145 |
+
<!-- GDPR Rounded switch -->
|
146 |
+
<label class="gdpr-checkbox-toggle">
|
147 |
+
<input type="checkbox" name="moove_gdpr_reject_button_enable" id="moove_gdpr_reject_button_enable" <?php echo isset( $gdpr_options['moove_gdpr_reject_button_enable'] ) ? ( intval( $gdpr_options['moove_gdpr_reject_button_enable'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_reject_button_enable'] ) ? 'checked' : '' ) ) : ''; ?> >
|
148 |
+
<span class="gdpr-checkbox-slider" data-enable="<?php esc_html_e( 'Enabled', 'gdpr-cookie-compliance' ); ?>" data-disable="<?php esc_html_e( 'Disabled', 'gdpr-cookie-compliance' ); ?>"></span>
|
149 |
+
</label>
|
150 |
+
<p class="description" id="moove_gdpr_reject_button_enable-description" ><?php esc_html_e( "If it's enabled, the Cookie Banner will be extended with a button that allows users to reject all cookies.", 'gdpr-cookie-compliance-addon' ); ?></p>
|
151 |
+
<!-- .description -->
|
152 |
+
</td>
|
153 |
+
</tr>
|
154 |
+
<tr class="gdpr-conditional-field" data-dependency="#moove_gdpr_reject_button_enable">
|
155 |
+
<th scope="row">
|
156 |
+
<label for="moove_gdpr_infobar_reject_button_label"><?php esc_html_e( 'Reject - Button Label', 'gdpr-cookie-compliance' ); ?></label>
|
157 |
+
</th>
|
158 |
+
<td>
|
159 |
+
<input name="moove_gdpr_infobar_reject_button_label<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_infobar_reject_button_label" value="<?php echo isset( $gdpr_options[ 'moove_gdpr_infobar_reject_button_label' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_infobar_reject_button_label' . $wpml_lang ] ? esc_attr( $gdpr_options[ 'moove_gdpr_infobar_reject_button_label' . $wpml_lang ] ) : esc_attr__( 'Reject', 'gdpr-cookie-compliance' ); ?>" class="regular-text">
|
160 |
+
</td>
|
161 |
+
</tr>
|
162 |
+
<tr>
|
163 |
+
<th scope="row">
|
164 |
+
<label for="moove_gdpr_infobar_position"><?php esc_html_e( 'Cookie Banner position', 'gdpr-cookie-compliance' ); ?></label>
|
165 |
+
</th>
|
166 |
+
<td>
|
167 |
+
<input name="moove_gdpr_infobar_position" type="radio" value="top" id="moove_gdpr_infobar_position_top" <?php echo isset( $gdpr_options['moove_gdpr_infobar_position'] ) ? ( 'top' === $gdpr_options['moove_gdpr_infobar_position'] ? 'checked' : '' ) : ''; ?> class="on-top"> <label for="moove_gdpr_infobar_position_top"><?php esc_html_e( 'Top', 'gdpr-cookie-compliance' ); ?></label>
|
168 |
+
<span class="separator"></span>
|
169 |
+
|
170 |
+
<input name="moove_gdpr_infobar_position" type="radio" value="bottom" id="moove_gdpr_infobar_position_bottom" <?php echo isset( $gdpr_options['moove_gdpr_infobar_position'] ) ? ( 'bottom' === $gdpr_options['moove_gdpr_infobar_position'] ? 'checked' : '' ) : 'checked'; ?> class="on-off"> <label for="moove_gdpr_infobar_position_bottom"><?php esc_html_e( 'Bottom', 'gdpr-cookie-compliance' ); ?></label>
|
171 |
+
|
172 |
+
<?php do_action( 'gdpr_cc_moove_gdpr_infobar_position_settings' ); ?>
|
173 |
+
</td>
|
174 |
+
</tr>
|
175 |
+
|
176 |
+
<tr>
|
177 |
+
<th scope="row">
|
178 |
+
<label for="moove_gdpr_colour_scheme"><?php esc_html_e( 'Colour scheme', 'gdpr-cookie-compliance' ); ?></label>
|
179 |
+
</th>
|
180 |
+
<td>
|
181 |
+
<label class="gdpr-checkbox-toggle gdpr-color-scheme-toggle">
|
182 |
+
<input type="checkbox" name="moove_gdpr_colour_scheme" <?php echo isset( $gdpr_options['moove_gdpr_colour_scheme'] ) ? ( 1 === intval( $gdpr_options['moove_gdpr_colour_scheme'] ) ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_colour_scheme'] ) ? 'checked' : '' ) ) : 'checked'; ?> >
|
183 |
+
<span class="gdpr-checkbox-slider" data-enable="<?php esc_html_e( 'Dark', 'gdpr-cookie-compliance' ); ?>" data-disable="<?php esc_html_e( 'Light', 'gdpr-cookie-compliance' ); ?>"></span>
|
184 |
+
</label>
|
185 |
+
</td>
|
186 |
+
</tr>
|
187 |
+
|
188 |
+
<?php do_action( 'gdpr_cc_infobar_settings' ); ?>
|
189 |
+
|
190 |
+
</tbody>
|
191 |
+
</table>
|
192 |
+
|
193 |
+
<br />
|
194 |
+
<hr />
|
195 |
+
<br />
|
196 |
+
<button type="submit" class="button button-primary"><?php esc_html_e( 'Save changes', 'gdpr-cookie-compliance' ); ?></button>
|
197 |
+
<?php do_action( 'gdpr_cc_banner_buttons_settings' ); ?>
|
198 |
+
</form>
|
views/moove/admin/settings/banner_settings.php
DELETED
@@ -1,193 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
3 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
4 |
-
$gdpr_options = get_option( $option_name );
|
5 |
-
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
6 |
-
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
7 |
-
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
8 |
-
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
9 |
-
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
10 |
-
die( 'Security check' );
|
11 |
-
else :
|
12 |
-
if ( is_array( $_POST ) ) :
|
13 |
-
$restricted_keys = array(
|
14 |
-
'moove_gdpr_floating_button_enable',
|
15 |
-
'moove_gdpr_infobar_visibility',
|
16 |
-
'moove_gdpr_reject_button_enable',
|
17 |
-
'moove_gdpr_colour_scheme'
|
18 |
-
);
|
19 |
-
|
20 |
-
// Cookie Banner Visibility
|
21 |
-
$moove_gdpr_infobar_visibility = 'hidden';
|
22 |
-
if ( isset( $_POST['moove_gdpr_infobar_visibility'] ) ) :
|
23 |
-
$moove_gdpr_infobar_visibility = 'visible';
|
24 |
-
endif;
|
25 |
-
$gdpr_options['moove_gdpr_infobar_visibility'] = $moove_gdpr_infobar_visibility;
|
26 |
-
|
27 |
-
// Cookie Banner Reject Button
|
28 |
-
$moove_gdpr_reject_enable = '0';
|
29 |
-
if ( isset( $_POST['moove_gdpr_reject_button_enable'] ) ) :
|
30 |
-
$moove_gdpr_reject_enable = '1';
|
31 |
-
endif;
|
32 |
-
$gdpr_options['moove_gdpr_reject_button_enable'] = $moove_gdpr_reject_enable;
|
33 |
-
|
34 |
-
// Cookie Banner Colour Scheme
|
35 |
-
$moove_gdpr_colour_scheme = '2';
|
36 |
-
if ( isset( $_POST['moove_gdpr_colour_scheme'] ) ) :
|
37 |
-
$moove_gdpr_colour_scheme = '1';
|
38 |
-
endif;
|
39 |
-
$gdpr_options['moove_gdpr_colour_scheme'] = $moove_gdpr_colour_scheme;
|
40 |
-
|
41 |
-
update_option( $option_name, $gdpr_options );
|
42 |
-
|
43 |
-
foreach ( $_POST as $form_key => $form_value ) :
|
44 |
-
if ( $form_key === 'moove_gdpr_info_bar_content' ) :
|
45 |
-
$value = wpautop( wp_unslash( $form_value ) );
|
46 |
-
$gdpr_options[$form_key.$wpml_lang] = $value;
|
47 |
-
update_option( $option_name, $gdpr_options );
|
48 |
-
$gdpr_options = get_option( $option_name );
|
49 |
-
elseif ( $form_key === 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ) :
|
50 |
-
$value = wpautop( wp_unslash( $form_value ) );
|
51 |
-
$gdpr_options[$form_key] = $value;
|
52 |
-
update_option( $option_name, $gdpr_options );
|
53 |
-
$gdpr_options = get_option( $option_name );
|
54 |
-
elseif ( ! in_array( $form_key, $restricted_keys ) ) :
|
55 |
-
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
56 |
-
$gdpr_options[$form_key] = $value;
|
57 |
-
update_option( $option_name, $gdpr_options );
|
58 |
-
$gdpr_options = get_option( $option_name );
|
59 |
-
endif;
|
60 |
-
endforeach;
|
61 |
-
endif;
|
62 |
-
do_action('gdpr_cookie_filter_settings');
|
63 |
-
?>
|
64 |
-
<script>
|
65 |
-
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
66 |
-
</script>
|
67 |
-
<?php
|
68 |
-
endif;
|
69 |
-
endif;
|
70 |
-
?>
|
71 |
-
<form action="?page=moove-gdpr&tab=banner_settings" method="post" id="moove_gdpr_tab_banner_settings">
|
72 |
-
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
73 |
-
<h2><?php _e('Cookie Banner Settings','gdpr-cookie-compliance'); ?></h2>
|
74 |
-
<hr />
|
75 |
-
|
76 |
-
<table class="form-table">
|
77 |
-
<tbody>
|
78 |
-
<tr>
|
79 |
-
<th scope="row">
|
80 |
-
<label for="moove_gdpr_infobar_visibility"><?php _e('Turn','gdpr-cookie-compliance'); ?></label>
|
81 |
-
</th>
|
82 |
-
<td>
|
83 |
-
<!-- GDPR Rounded switch -->
|
84 |
-
<label class="gdpr-checkbox-toggle">
|
85 |
-
<input type="checkbox" name="moove_gdpr_infobar_visibility" <?php echo isset( $gdpr_options['moove_gdpr_infobar_visibility'] ) ? ( $gdpr_options['moove_gdpr_infobar_visibility'] === 'visible' ? 'checked' : '' ) : 'checked'; ?> >
|
86 |
-
<span class="gdpr-checkbox-slider" data-enable="<?php _e('On','gdpr-cookie-compliance'); ?>" data-disable="<?php _e('Off','gdpr-cookie-compliance'); ?>"></span>
|
87 |
-
</label>
|
88 |
-
<?php do_action('gdpr_cc_moove_gdpr_infobar_visibility_settings'); ?>
|
89 |
-
</td>
|
90 |
-
</tr>
|
91 |
-
|
92 |
-
<tr>
|
93 |
-
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
94 |
-
<label for="moove_gdpr_info_bar_content"><?php _e('Cookie Banner Content','gdpr-cookie-compliance'); ?></label>
|
95 |
-
</th>
|
96 |
-
</tr>
|
97 |
-
|
98 |
-
<tr class="moove_gdpr_table_form_holder">
|
99 |
-
<th colspan="2" scope="row">
|
100 |
-
<?php
|
101 |
-
$content = isset( $gdpr_options['moove_gdpr_info_bar_content'.$wpml_lang] ) && $gdpr_options['moove_gdpr_info_bar_content'.$wpml_lang] ? maybe_unserialize( $gdpr_options['moove_gdpr_info_bar_content'.$wpml_lang] ) : false;
|
102 |
-
if ( ! $content ) :
|
103 |
-
$_content = __("<p>We are using cookies to give you the best experience on our website.</p><p>You can find out more about which cookies we are using or switch them off in [setting]settings[/setting].</p>","gdpr-cookie-compliance");
|
104 |
-
$content = $_content;
|
105 |
-
endif;
|
106 |
-
?>
|
107 |
-
<?php
|
108 |
-
$settings = array (
|
109 |
-
'media_buttons' => false,
|
110 |
-
'editor_height' => 150,
|
111 |
-
'teeny' => false
|
112 |
-
);
|
113 |
-
wp_editor( $content, 'moove_gdpr_info_bar_content', $settings );
|
114 |
-
?>
|
115 |
-
<p class="description"><?php _e('You can use the following shortcut to link the Cookie Settings Screen:<br><span><strong>[setting]</strong>settings<strong>[/setting]</strong></span>','gdpr-cookie-compliance'); ?></p>
|
116 |
-
</th>
|
117 |
-
</tr>
|
118 |
-
|
119 |
-
<tr>
|
120 |
-
<th scope="row">
|
121 |
-
<label for="moove_gdpr_infobar_accept_button_label"><?php _e('Accept - Button Label','gdpr-cookie-compliance'); ?></label>
|
122 |
-
</th>
|
123 |
-
<td>
|
124 |
-
<input name="moove_gdpr_infobar_accept_button_label<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_infobar_accept_button_label" value="<?php echo isset( $gdpr_options['moove_gdpr_infobar_accept_button_label'.$wpml_lang] ) && $gdpr_options['moove_gdpr_infobar_accept_button_label'.$wpml_lang] ? $gdpr_options['moove_gdpr_infobar_accept_button_label'.$wpml_lang] : __('Accept','gdpr-cookie-compliance'); ?>" class="regular-text">
|
125 |
-
</td>
|
126 |
-
</tr>
|
127 |
-
|
128 |
-
<tr>
|
129 |
-
<th scope="row">
|
130 |
-
<label for="moove_gdpr_reject_button_enable"><?php _e('Reject button','gdpr-cookie-compliance-addon'); ?></label>
|
131 |
-
</th>
|
132 |
-
<td>
|
133 |
-
|
134 |
-
<!-- GDPR Rounded switch -->
|
135 |
-
<label class="gdpr-checkbox-toggle">
|
136 |
-
<input type="checkbox" name="moove_gdpr_reject_button_enable" id="moove_gdpr_reject_button_enable" <?php echo isset( $gdpr_options['moove_gdpr_reject_button_enable'] ) ? ( intval( $gdpr_options['moove_gdpr_reject_button_enable'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_reject_button_enable'] ) ? 'checked' : '' ) ) : ''; ?> >
|
137 |
-
<span class="gdpr-checkbox-slider" data-enable="<?php _e('Enabled','gdpr-cookie-compliance'); ?>" data-disable="<?php _e('Disabled','gdpr-cookie-compliance'); ?>"></span>
|
138 |
-
</label>
|
139 |
-
|
140 |
-
|
141 |
-
<p class="description" id="moove_gdpr_reject_button_enable-description" ><?php _e("If it's enabled, the Cookie Banner will be extended with a button that allows users to reject all cookies.",'gdpr-cookie-compliance-addon'); ?></p>
|
142 |
-
<!-- .description -->
|
143 |
-
</td>
|
144 |
-
</tr>
|
145 |
-
<tr class="gdpr-conditional-field" data-dependency="#moove_gdpr_reject_button_enable">
|
146 |
-
<th scope="row">
|
147 |
-
<label for="moove_gdpr_infobar_reject_button_label"><?php _e('Reject - Button Label','gdpr-cookie-compliance'); ?></label>
|
148 |
-
</th>
|
149 |
-
<td>
|
150 |
-
<input name="moove_gdpr_infobar_reject_button_label<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_infobar_reject_button_label" value="<?php echo isset( $gdpr_options['moove_gdpr_infobar_reject_button_label'.$wpml_lang] ) && $gdpr_options['moove_gdpr_infobar_reject_button_label'.$wpml_lang] ? $gdpr_options['moove_gdpr_infobar_reject_button_label'.$wpml_lang] : __('Reject','gdpr-cookie-compliance'); ?>" class="regular-text">
|
151 |
-
</td>
|
152 |
-
</tr>
|
153 |
-
|
154 |
-
<tr>
|
155 |
-
<th scope="row">
|
156 |
-
<label for="moove_gdpr_infobar_position"><?php _e('Cookie Banner position','gdpr-cookie-compliance'); ?></label>
|
157 |
-
</th>
|
158 |
-
<td>
|
159 |
-
|
160 |
-
<input name="moove_gdpr_infobar_position" type="radio" value="top" id="moove_gdpr_infobar_position_top" <?php echo isset( $gdpr_options['moove_gdpr_infobar_position'] ) ? ( $gdpr_options['moove_gdpr_infobar_position'] === 'top' ? 'checked' : '' ) : ''; ?> class="on-top"> <label for="moove_gdpr_infobar_position_top"><?php _e('Top','gdpr-cookie-compliance'); ?></label>
|
161 |
-
<span class="separator"></span>
|
162 |
-
|
163 |
-
<input name="moove_gdpr_infobar_position" type="radio" value="bottom" id="moove_gdpr_infobar_position_bottom" <?php echo isset( $gdpr_options['moove_gdpr_infobar_position'] ) ? ( $gdpr_options['moove_gdpr_infobar_position'] === 'bottom' ? 'checked' : '' ) : 'checked'; ?> class="on-off"> <label for="moove_gdpr_infobar_position_bottom"><?php _e('Bottom','gdpr-cookie-compliance'); ?></label>
|
164 |
-
|
165 |
-
<?php do_action('gdpr_cc_moove_gdpr_infobar_position_settings'); ?>
|
166 |
-
|
167 |
-
|
168 |
-
</td>
|
169 |
-
</tr>
|
170 |
-
|
171 |
-
<tr>
|
172 |
-
<th scope="row">
|
173 |
-
<label for="moove_gdpr_colour_scheme"><?php _e('Colour scheme','gdpr-cookie-compliance'); ?></label>
|
174 |
-
</th>
|
175 |
-
<td>
|
176 |
-
<label class="gdpr-checkbox-toggle gdpr-color-scheme-toggle">
|
177 |
-
<input type="checkbox" name="moove_gdpr_colour_scheme" <?php echo isset( $gdpr_options['moove_gdpr_colour_scheme'] ) ? ( intval( $gdpr_options['moove_gdpr_colour_scheme'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_colour_scheme'] ) ? 'checked' : '' ) ) : 'checked'; ?> >
|
178 |
-
<span class="gdpr-checkbox-slider" data-enable="<?php _e('Dark','gdpr-cookie-compliance'); ?>" data-disable="<?php _e('Light','gdpr-cookie-compliance'); ?>"></span>
|
179 |
-
</label>
|
180 |
-
</td>
|
181 |
-
</tr>
|
182 |
-
|
183 |
-
<?php do_action('gdpr_cc_infobar_settings'); ?>
|
184 |
-
|
185 |
-
</tbody>
|
186 |
-
</table>
|
187 |
-
|
188 |
-
<br />
|
189 |
-
<hr />
|
190 |
-
<br />
|
191 |
-
<button type="submit" class="button button-primary"><?php _e('Save changes','gdpr-cookie-compliance'); ?></button>
|
192 |
-
<?php do_action('gdpr_cc_banner_buttons_settings'); ?>
|
193 |
-
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
views/moove/admin/settings/branding.php
CHANGED
@@ -1,189 +1,194 @@
|
|
1 |
<?php
|
2 |
-
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
10 |
-
die( 'Security check' );
|
11 |
-
else :
|
12 |
-
if ( is_array( $_POST ) ) :
|
13 |
-
$gdpr_options = get_option( $option_name );
|
14 |
-
foreach ( $_POST as $form_key => $form_value ) :
|
15 |
-
if ( $form_key === 'moove_gdpr_info_bar_content' ) :
|
16 |
-
$value = wpautop( wp_unslash( $form_value ) );
|
17 |
-
$gdpr_options[$form_key.$wpml_lang] = $value;
|
18 |
-
update_option( $option_name, $gdpr_options );
|
19 |
-
$gdpr_options = get_option( $option_name );
|
20 |
-
elseif ( $form_key === 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ) :
|
21 |
-
$value = wpautop( wp_unslash( $form_value ) );
|
22 |
-
$gdpr_options[$form_key] = $value;
|
23 |
-
update_option( $option_name, $gdpr_options );
|
24 |
-
$gdpr_options = get_option( $option_name );
|
25 |
-
elseif ( $form_key !== 'moove_gdpr_floating_button_enable' && $form_key !== 'moove_gdpr_modal_powered_by_disable' ) :
|
26 |
-
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
27 |
-
$gdpr_options[$form_key] = $value;
|
28 |
-
update_option( $option_name, $gdpr_options );
|
29 |
-
$gdpr_options = get_option( $option_name );
|
30 |
-
endif;
|
31 |
-
endforeach;
|
32 |
-
endif;
|
33 |
-
do_action('gdpr_cookie_filter_settings');
|
34 |
-
?>
|
35 |
-
<script>
|
36 |
-
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
37 |
-
</script>
|
38 |
-
<?php
|
39 |
-
endif;
|
40 |
-
endif;
|
41 |
-
?>
|
42 |
-
<form action="?page=moove-gdpr&tab=branding" method="post" id="moove_gdpr_tab_branding_settings">
|
43 |
-
<h2><?php _e('Branding','gdpr-cookie-compliance'); ?></h2>
|
44 |
-
<hr />
|
45 |
-
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
46 |
-
<table class="form-table">
|
47 |
-
<tbody>
|
48 |
-
|
49 |
-
<tr>
|
50 |
-
<th scope="row">
|
51 |
-
<label for="moove_gdpr_brand_colour"><?php _e('Brand Primary Colour','gdpr-cookie-compliance'); ?></label>
|
52 |
-
</th>
|
53 |
-
<td>
|
54 |
-
<div class="iris-colorpicker-group-cnt">
|
55 |
-
<?php $color = isset( $gdpr_options['moove_gdpr_brand_colour'] ) && $gdpr_options['moove_gdpr_brand_colour'] ? $gdpr_options['moove_gdpr_brand_colour'] : '0C4DA2'; ?>
|
56 |
-
<input class="iris-colorpicker regular-text" name="moove_gdpr_brand_colour" value="<?php echo $color; ?>" style="background-color: <?php echo $color; ?>" type="text">
|
57 |
-
<span class="iris-selectbtn"><?php _e('Select','gdpr-cookie-compliance'); ?></span>
|
58 |
-
</div>
|
59 |
-
</td>
|
60 |
-
</tr>
|
61 |
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
102 |
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
108 |
-
|
109 |
-
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
|
|
|
114 |
|
115 |
-
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
122 |
|
123 |
-
|
124 |
-
|
125 |
-
|
126 |
-
|
127 |
-
|
128 |
-
|
129 |
-
|
|
|
|
|
|
|
|
|
130 |
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
-
|
|
|
|
|
|
|
135 |
|
136 |
-
|
137 |
-
|
138 |
-
|
|
|
|
|
|
|
|
|
139 |
|
140 |
-
|
141 |
-
|
142 |
-
|
143 |
-
</th>
|
144 |
-
<td>
|
145 |
-
<input name="moove_gdpr_plugin_font_type" type="radio" value="1" data-val="'Nunito', sans-serif" id="moove_gdpr_plugin_font_type_1" <?php echo isset( $gdpr_options['moove_gdpr_plugin_font_type'] ) ? ( $gdpr_options['moove_gdpr_plugin_font_type'] === '1' ? 'checked' : '' ) : 'checked'; ?> class="on-off"> <label for="moove_gdpr_plugin_font_type_1"><?php _e('Default','gdpr-cookie-compliance'); ?></label>
|
146 |
-
<span class="separator"></span>
|
147 |
-
<br /><br />
|
148 |
|
149 |
-
|
150 |
-
|
151 |
-
|
152 |
|
153 |
-
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
-
|
158 |
-
|
159 |
-
|
160 |
-
|
161 |
-
}
|
162 |
-
endif;
|
163 |
|
164 |
-
|
165 |
-
|
166 |
-
|
167 |
-
</tr>
|
168 |
-
<tr>
|
169 |
-
<th scope="row">
|
170 |
-
<label for="moove_gdpr_cdn_url"><?php _e('CDN Base URL','gdpr-cookie-compliance'); ?></label>
|
171 |
-
</th>
|
172 |
-
<td>
|
173 |
-
<input name="moove_gdpr_cdn_url" type="text" id="moove_gdpr_cdn_url" value="<?php echo isset( $gdpr_options['moove_gdpr_cdn_url'] ) && $gdpr_options['moove_gdpr_cdn_url'] ? $gdpr_options['moove_gdpr_cdn_url'] : ''; ?>" class="regular-text">
|
174 |
-
<p class="description"><strong>* <?php _e('Optional, leave it empty to use default domain</strong><br /> Enter your CDN root URL to enable CDN for GDPR Lity library files. The URL can be http, https or protocol-relative', 'gdpr-cookie-compliance'); ?> (e.g. //cdn.example.com/).</p>
|
175 |
-
<!-- .description -->
|
176 |
-
</td>
|
177 |
-
</tr>
|
178 |
-
<?php do_action('gdpr_cc_general_modal_settings'); ?>
|
179 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
180 |
|
181 |
-
|
182 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
183 |
|
184 |
-
|
185 |
-
|
186 |
-
|
187 |
-
|
188 |
-
|
189 |
-
</form>
|
1 |
<?php
|
2 |
+
/**
|
3 |
+
* Branding File Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
9 |
|
10 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
11 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
12 |
+
$gdpr_options = get_option( $option_name );
|
13 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
14 |
+
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
15 |
+
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
16 |
+
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
17 |
+
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
18 |
+
die( 'Security check' );
|
19 |
+
else :
|
20 |
+
if ( is_array( $_POST ) ) :
|
21 |
+
$gdpr_options = get_option( $option_name );
|
22 |
+
foreach ( $_POST as $form_key => $form_value ) :
|
23 |
+
if ( 'moove_gdpr_info_bar_content' === $form_key ) :
|
24 |
+
$value = wpautop( wp_unslash( $form_value ) );
|
25 |
+
$gdpr_options[ $form_key . $wpml_lang ] = $value;
|
26 |
+
update_option( $option_name, $gdpr_options );
|
27 |
+
$gdpr_options = get_option( $option_name );
|
28 |
+
elseif ( 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang === $form_key ) :
|
29 |
+
$value = wpautop( wp_unslash( $form_value ) );
|
30 |
+
$gdpr_options[ $form_key ] = $value;
|
31 |
+
update_option( $option_name, $gdpr_options );
|
32 |
+
$gdpr_options = get_option( $option_name );
|
33 |
+
elseif ( 'moove_gdpr_floating_button_enable' !== $form_key && 'moove_gdpr_modal_powered_by_disable' !== $form_key ) :
|
34 |
+
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
35 |
+
$gdpr_options[ $form_key ] = $value;
|
36 |
+
update_option( $option_name, $gdpr_options );
|
37 |
+
$gdpr_options = get_option( $option_name );
|
38 |
+
endif;
|
39 |
+
endforeach;
|
40 |
+
endif;
|
41 |
+
do_action( 'gdpr_cookie_filter_settings' );
|
42 |
+
?>
|
43 |
+
<script>
|
44 |
+
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
45 |
+
</script>
|
46 |
+
<?php
|
47 |
+
endif;
|
48 |
+
endif;
|
49 |
+
?>
|
50 |
+
<form action="<?php echo esc_url( admin_url( '?page=moove-gdpr&tab=branding' ) ); ?>" method="post" id="moove_gdpr_tab_branding_settings">
|
51 |
+
<h2><?php esc_html_e( 'Branding', 'gdpr-cookie-compliance' ); ?></h2>
|
52 |
+
<hr />
|
53 |
+
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
54 |
+
<table class="form-table">
|
55 |
+
<tbody>
|
56 |
+
<tr>
|
57 |
+
<th scope="row">
|
58 |
+
<label for="moove_gdpr_brand_colour"><?php esc_html_e( 'Brand Primary Colour', 'gdpr-cookie-compliance' ); ?></label>
|
59 |
+
</th>
|
60 |
+
<td>
|
61 |
+
<div class="iris-colorpicker-group-cnt">
|
62 |
+
<?php $color = isset( $gdpr_options['moove_gdpr_brand_colour'] ) && $gdpr_options['moove_gdpr_brand_colour'] ? $gdpr_options['moove_gdpr_brand_colour'] : '0C4DA2'; ?>
|
63 |
+
<input class="iris-colorpicker regular-text" name="moove_gdpr_brand_colour" value="<?php echo esc_attr( $color ); ?>" style="background-color: <?php echo esc_attr( $color ); ?>" type="text">
|
64 |
+
<span class="iris-selectbtn"><?php esc_html_e( 'Select', 'gdpr-cookie-compliance' ); ?></span>
|
65 |
+
</div>
|
66 |
+
</td>
|
67 |
+
</tr>
|
68 |
|
69 |
+
<tr>
|
70 |
+
<th scope="row">
|
71 |
+
<label for="moove_gdpr_brand_secondary_colour"><?php esc_html_e( 'Brand Secondary Colour', 'gdpr-cookie-compliance' ); ?></label>
|
72 |
+
</th>
|
73 |
+
<td>
|
74 |
+
<div class="iris-colorpicker-group-cnt">
|
75 |
+
<?php $color = isset( $gdpr_options['moove_gdpr_brand_secondary_colour'] ) && $gdpr_options['moove_gdpr_brand_secondary_colour'] ? $gdpr_options['moove_gdpr_brand_secondary_colour'] : '000000'; ?>
|
76 |
+
<input class="iris-colorpicker regular-text" name="moove_gdpr_brand_secondary_colour" value="<?php echo esc_attr( $color ); ?>" style="background-color: <?php echo esc_attr( $color ); ?>" type="text">
|
77 |
+
<span class="iris-selectbtn"><?php esc_html_e( 'Select', 'gdpr-cookie-compliance' ); ?></span>
|
78 |
+
</div>
|
79 |
+
</td>
|
80 |
+
</tr>
|
81 |
|
82 |
+
<tr>
|
83 |
+
<th scope="row">
|
84 |
+
<label for="moove_gdpr_company_logo"><?php esc_html_e( 'Cookie Settings Logo', 'gdpr-cookie-compliance' ); ?></label>
|
85 |
+
<p class="description"><?php esc_html_e( 'Recommended size:', 'gdpr-cookie-compliance' ); ?><br>130 x 50 <?php esc_html_e( 'pixels', 'gdpr-cookie-compliance' ); ?></p>
|
86 |
+
<!-- .description -->
|
87 |
+
</th>
|
88 |
+
<td>
|
89 |
+
<?php
|
90 |
+
if ( function_exists( 'wp_enqueue_media' ) ) :
|
91 |
+
wp_enqueue_media();
|
92 |
+
else :
|
93 |
+
wp_enqueue_style( 'thickbox' );
|
94 |
+
wp_enqueue_script( 'media-upload' );
|
95 |
+
wp_enqueue_script( 'thickbox' );
|
96 |
+
endif;
|
97 |
+
?>
|
98 |
+
<?php
|
99 |
+
$plugin_dir = moove_gdpr_get_plugin_directory_url();
|
100 |
+
$image_url = isset( $gdpr_options['moove_gdpr_company_logo'] ) && $gdpr_options['moove_gdpr_company_logo'] ? $gdpr_options['moove_gdpr_company_logo'] : $plugin_dir . 'dist/images/gdpr-logo.png';
|
101 |
+
?>
|
102 |
+
<span class="moove_gdpr_company_logo_holder" style="background-image: url(<?php echo esc_url( $image_url ); ?>);"></span><br /><br />
|
103 |
+
<input class="regular-text code" type="text" name="moove_gdpr_company_logo" value="<?php echo esc_url( $image_url ); ?>" required> <br /><br />
|
104 |
+
<a href="#" class="button moove_gdpr_company_logo_upload">Upload Logo</a>
|
105 |
+
<script>
|
106 |
+
jQuery(document).ready(function($) {
|
107 |
+
$('.moove_gdpr_company_logo_upload').click(function(e) {
|
108 |
+
e.preventDefault();
|
109 |
|
110 |
+
var custom_uploader = wp.media({
|
111 |
+
title: 'GDPR Modal - Company Logo',
|
112 |
+
button: {
|
113 |
+
text: 'Upload Logo'
|
114 |
+
},
|
115 |
+
multiple: false // Set this to true to allow multiple files to be selected
|
116 |
+
})
|
117 |
+
.on('select', function() {
|
118 |
+
var attachment = custom_uploader.state().get('selection').first().toJSON();
|
119 |
+
$('.moove_gdpr_company_logo_holder').css('background-image', 'url('+attachment.url+')');
|
120 |
+
$('input[name=moove_gdpr_company_logo]').val(attachment.url);
|
121 |
|
122 |
+
})
|
123 |
+
.open();
|
124 |
+
});
|
125 |
+
});
|
126 |
+
</script>
|
127 |
+
</td>
|
128 |
+
</tr>
|
129 |
|
130 |
+
<tr>
|
131 |
+
<th scope="row">
|
132 |
+
<label for="moove_gdpr_logo_position"><?php esc_html_e( 'Logo Position', 'gdpr-cookie-compliance' ); ?></label>
|
133 |
+
</th>
|
134 |
+
<td>
|
135 |
+
<input name="moove_gdpr_logo_position" type="radio" value="left" id="moove_gdpr_logo_position_left" <?php echo isset( $gdpr_options['moove_gdpr_logo_position'] ) ? ( 'left' === $gdpr_options['moove_gdpr_logo_position'] ? 'checked' : '' ) : 'checked'; ?> class="on-off"> <label for="moove_gdpr_logo_position_left"><?php esc_html_e( 'Left', 'gdpr-cookie-compliance' ); ?></label>
|
136 |
+
<span class="separator"></span>
|
137 |
|
138 |
+
<input name="moove_gdpr_logo_position" type="radio" value="center" id="moove_gdpr_logo_position_center" <?php echo isset( $gdpr_options['moove_gdpr_logo_position'] ) ? ( 'center' === $gdpr_options['moove_gdpr_logo_position'] ? 'checked' : '' ) : ''; ?> class="on-off"> <label for="moove_gdpr_logo_position_center"><?php esc_html_e( 'Center', 'gdpr-cookie-compliance' ); ?></label>
|
139 |
+
<span class="separator"></span>
|
140 |
+
<input name="moove_gdpr_logo_position" type="radio" value="right" id="moove_gdpr_logo_position_right" <?php echo isset( $gdpr_options['moove_gdpr_logo_position'] ) ? ( 'right' === $gdpr_options['moove_gdpr_logo_position'] ? 'checked' : '' ) : ''; ?> class="on-off"> <label for="moove_gdpr_logo_position_right"><?php esc_html_e( 'Right', 'gdpr-cookie-compliance' ); ?></label>
|
|
|
|
|
|
|
|
|
|
|
141 |
|
142 |
+
<?php do_action( 'gdpr_cc_moove_gdpr_logo_position_settings' ); ?>
|
143 |
+
</td>
|
144 |
+
</tr>
|
145 |
|
146 |
+
<tr>
|
147 |
+
<th scope="row">
|
148 |
+
<label for="moove_gdpr_plugin_font_family"><?php esc_html_e( 'Choose font', 'gdpr-cookie-compliance' ); ?></label>
|
149 |
+
</th>
|
150 |
+
<td>
|
151 |
+
<input name="moove_gdpr_plugin_font_type" type="radio" value="1" data-val="'Nunito', sans-serif" id="moove_gdpr_plugin_font_type_1" <?php echo isset( $gdpr_options['moove_gdpr_plugin_font_type'] ) ? ( '1' === $gdpr_options['moove_gdpr_plugin_font_type'] ? 'checked' : '' ) : 'checked'; ?> class="on-off"> <label for="moove_gdpr_plugin_font_type_1"><?php esc_html_e( 'Default', 'gdpr-cookie-compliance' ); ?></label>
|
152 |
+
<span class="separator"></span>
|
153 |
+
<br /><br />
|
|
|
|
|
154 |
|
155 |
+
<input name="moove_gdpr_plugin_font_type" type="radio" value="2" data-val="inherit" id="moove_gdpr_plugin_font_type_2" <?php echo isset( $gdpr_options['moove_gdpr_plugin_font_type'] ) ? ( '2' === $gdpr_options['moove_gdpr_plugin_font_type'] ? 'checked' : '' ) : ''; ?> class="on-off"> <label for="moove_gdpr_plugin_font_type_2"><?php esc_html_e( 'Inherit font-family from your WordPress theme', 'gdpr-cookie-compliance' ); ?></label>
|
156 |
+
<span class="separator"></span>
|
157 |
+
<br /><br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
158 |
|
159 |
+
<input name="moove_gdpr_plugin_font_type" type="radio" value="3" data-val="" id="moove_gdpr_plugin_font_type_3" <?php echo isset( $gdpr_options['moove_gdpr_plugin_font_type'] ) ? ( '3' === $gdpr_options['moove_gdpr_plugin_font_type'] ? 'checked' : '' ) : ''; ?> class="on-off"> <label for="moove_gdpr_plugin_font_type_3"><?php esc_html_e( 'Specify custom font', 'gdpr-cookie-compliance' ); ?></label>
|
160 |
+
<span class="separator"></span>
|
161 |
+
<br /><br />
|
162 |
+
<?php
|
163 |
+
$field_class = '';
|
164 |
+
if ( isset( $gdpr_options['moove_gdpr_plugin_font_type'] ) ) :
|
165 |
+
if ( '1' === $gdpr_options['moove_gdpr_plugin_font_type'] || '2' === $gdpr_options['moove_gdpr_plugin_font_type'] ) {
|
166 |
+
$field_class = 'moove-not-visible';
|
167 |
+
}
|
168 |
+
endif;
|
169 |
|
170 |
+
?>
|
171 |
+
<input name="moove_gdpr_plugin_font_family" type="text" id="moove_gdpr_plugin_font_family" value="<?php echo isset( $gdpr_options['moove_gdpr_plugin_font_family'] ) && $gdpr_options['moove_gdpr_plugin_font_family'] ? esc_attr( $gdpr_options['moove_gdpr_plugin_font_family'] ) : "'Nunito', sans-serif"; ?>" class="regular-text <?php echo esc_attr( $field_class ); ?>">
|
172 |
+
</td>
|
173 |
+
</tr>
|
174 |
+
<tr>
|
175 |
+
<th scope="row">
|
176 |
+
<label for="moove_gdpr_cdn_url"><?php esc_html_e( 'CDN Base URL', 'gdpr-cookie-compliance' ); ?></label>
|
177 |
+
</th>
|
178 |
+
<td>
|
179 |
+
<input name="moove_gdpr_cdn_url" type="text" id="moove_gdpr_cdn_url" value="<?php echo isset( $gdpr_options['moove_gdpr_cdn_url'] ) && $gdpr_options['moove_gdpr_cdn_url'] ? esc_url( $gdpr_options['moove_gdpr_cdn_url'] ) : ''; ?>" class="regular-text">
|
180 |
+
<p class="description">
|
181 |
+
<strong>* <?php esc_html_e( 'Optional, leave it empty to use default domain','gdpr-cookie-compliance');?></strong><br /><?php esc_html_e('Enter your CDN root URL to enable CDN for GDPR Lity library files. The URL can be http, https or protocol-relative', 'gdpr-cookie-compliance' ); ?> (e.g. //cdn.example.com/).</p>
|
182 |
+
<!-- .description -->
|
183 |
+
</td>
|
184 |
+
</tr>
|
185 |
+
<?php do_action( 'gdpr_cc_general_modal_settings' ); ?>
|
186 |
+
</tbody>
|
187 |
+
</table>
|
188 |
|
189 |
+
<br />
|
190 |
+
<hr />
|
191 |
+
<br />
|
192 |
+
<button type="submit" class="button button-primary"><?php esc_html_e( 'Save changes', 'gdpr-cookie-compliance' ); ?></button>
|
193 |
+
<?php do_action( 'gdpr_cc_general_buttons_settings' ); ?>
|
194 |
+
</form>
|
views/moove/admin/settings/cookie-banner-manager.php
CHANGED
@@ -1,4 +1,12 @@
|
|
1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
<hr />
|
3 |
-
|
4 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Cookie Banner Manager Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
?>
|
10 |
+
<h2><?php esc_html_e('Hide Cookie Banner on Selected Posts / Pages','gdpr-cookie-compliance'); ?></h2>
|
11 |
<hr />
|
|
|
12 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
views/moove/admin/settings/cookie-policy.php
ADDED
@@ -0,0 +1,114 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Cookie Banner Manager Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
11 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
12 |
+
$gdpr_options = get_option( $option_name );
|
13 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
14 |
+
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
15 |
+
|
16 |
+
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
17 |
+
if ( ! wp_verify_nonce( sanitize_key( wp_unslash( $_POST['moove_gdpr_nonce'] ) ), 'moove_gdpr_nonce_field' ) ) :
|
18 |
+
die( 'Security check' );
|
19 |
+
else :
|
20 |
+
if ( is_array( $_POST ) ) :
|
21 |
+
if ( isset( $_POST['moove_gdpr_cookie_policy_enable'] ) ) :
|
22 |
+
$value = 1;
|
23 |
+
else :
|
24 |
+
$value = 0;
|
25 |
+
endif;
|
26 |
+
$gdpr_options['moove_gdpr_cookie_policy_enable'] = $value;
|
27 |
+
update_option( $option_name, $gdpr_options );
|
28 |
+
$gdpr_options = get_option( $option_name );
|
29 |
+
foreach ( $_POST as $form_key => $form_value ) :
|
30 |
+
if ( 'moove_gdpr_cookies_policy_tab_content' === $form_key ) :
|
31 |
+
$value = wp_unslash( $form_value );
|
32 |
+
$gdpr_options[ $form_key . $wpml_lang ] = $value;
|
33 |
+
update_option( $option_name, $gdpr_options );
|
34 |
+
$gdpr_options = get_option( $option_name );
|
35 |
+
elseif ( 'moove_gdpr_cookie_policy_enable' !== $form_key ) :
|
36 |
+
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
37 |
+
$gdpr_options[ $form_key ] = $value;
|
38 |
+
update_option( $option_name, $gdpr_options );
|
39 |
+
$gdpr_options = get_option( $option_name );
|
40 |
+
endif;
|
41 |
+
endforeach;
|
42 |
+
endif;
|
43 |
+
do_action( 'gdpr_cookie_filter_settings' );
|
44 |
+
?>
|
45 |
+
<script>
|
46 |
+
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
47 |
+
</script>
|
48 |
+
<?php
|
49 |
+
endif;
|
50 |
+
endif;
|
51 |
+
?>
|
52 |
+
<?php
|
53 |
+
$nav_label = isset( $gdpr_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] ? $gdpr_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] : __( 'Cookie Policy', 'gdpr-cookie-compliance' );
|
54 |
+
?>
|
55 |
+
<h2><?php echo esc_attr( $nav_label ); ?></h2>
|
56 |
+
<hr />
|
57 |
+
<form action="<?php echo esc_url( admin_url( '?page=moove-gdpr&tab=cookie-policy' ) ); ?>" method="post" id="moove_gdpr_tab_cookie_policy">
|
58 |
+
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
59 |
+
<table class="form-table">
|
60 |
+
<tbody>
|
61 |
+
<tr>
|
62 |
+
<th scope="row">
|
63 |
+
<label for="moove_gdpr_cookie_policy_enable"><?php esc_html_e( 'Turn', 'gdpr-cookie-compliance' ); ?></label>
|
64 |
+
</th>
|
65 |
+
<td>
|
66 |
+
|
67 |
+
<!-- GDPR Rounded switch -->
|
68 |
+
<label class="gdpr-checkbox-toggle">
|
69 |
+
<input type="checkbox" name="moove_gdpr_cookie_policy_enable" id="moove_gdpr_cookie_policy_enable" <?php echo isset( $gdpr_options['moove_gdpr_cookie_policy_enable'] ) ? ( intval( $gdpr_options['moove_gdpr_cookie_policy_enable'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_cookie_policy_enable'] ) ? 'checked' : '' ) ) : ''; ?> >
|
70 |
+
<span class="gdpr-checkbox-slider" data-enable="<?php esc_html_e( 'On', 'gdpr-cookie-compliance' ); ?>" data-disable="<?php esc_html_e( 'Off', 'gdpr-cookie-compliance' ); ?>"></span>
|
71 |
+
</label>
|
72 |
+
|
73 |
+
</td>
|
74 |
+
</tr>
|
75 |
+
<tr>
|
76 |
+
<th scope="row">
|
77 |
+
<label for="moove_gdpr_cookie_policy_tab_nav_label"><?php esc_html_e( 'Tab Title', 'gdpr-cookie-compliance' ); ?></label>
|
78 |
+
</th>
|
79 |
+
<td>
|
80 |
+
<input name="moove_gdpr_cookie_policy_tab_nav_label<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_cookie_policy_tab_nav_label" value="<?php echo esc_attr( $nav_label ); ?>" class="regular-text">
|
81 |
+
</td>
|
82 |
+
</tr>
|
83 |
+
|
84 |
+
<tr>
|
85 |
+
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
86 |
+
<label for="moove_gdpr_cookies_policy_tab_content"><?php esc_html_e( 'Tab Content', 'gdpr-cookie-compliance' ); ?></label>
|
87 |
+
</th>
|
88 |
+
</tr>
|
89 |
+
<tr class="moove_gdpr_table_form_holder">
|
90 |
+
<th colspan="2" scope="row">
|
91 |
+
<?php
|
92 |
+
$content = isset( $gdpr_options[ 'moove_gdpr_cookies_policy_tab_content' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_cookies_policy_tab_content' . $wpml_lang ] ? wp_unslash( $gdpr_options[ 'moove_gdpr_cookies_policy_tab_content' . $wpml_lang ] ) : false;
|
93 |
+
if ( ! $content ) :
|
94 |
+
$_content = $gdpr_default_content->moove_gdpr_get_cookie_policy_content();
|
95 |
+
$content = $_content;
|
96 |
+
endif;
|
97 |
+
?>
|
98 |
+
<?php
|
99 |
+
$settings = array(
|
100 |
+
'media_buttons' => false,
|
101 |
+
'editor_height' => 150,
|
102 |
+
);
|
103 |
+
wp_editor( $content, 'moove_gdpr_cookies_policy_tab_content', $settings );
|
104 |
+
?>
|
105 |
+
</th>
|
106 |
+
</tr>
|
107 |
+
|
108 |
+
</tbody>
|
109 |
+
</table>
|
110 |
+
|
111 |
+
<hr />
|
112 |
+
<br />
|
113 |
+
<button type="submit" class="button button-primary"><?php esc_html_e( 'Save changes', 'gdpr-cookie-compliance' ); ?></button>
|
114 |
+
</form>
|
views/moove/admin/settings/cookie_policy.php
DELETED
@@ -1,107 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
3 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
4 |
-
$gdpr_options = get_option( $option_name );
|
5 |
-
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
6 |
-
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
7 |
-
|
8 |
-
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
9 |
-
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
10 |
-
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
11 |
-
die( 'Security check' );
|
12 |
-
else :
|
13 |
-
if ( is_array( $_POST ) ) :
|
14 |
-
if ( isset( $_POST['moove_gdpr_cookie_policy_enable'] ) ) :
|
15 |
-
$value = 1;
|
16 |
-
else :
|
17 |
-
$value = 0;
|
18 |
-
endif;
|
19 |
-
$gdpr_options['moove_gdpr_cookie_policy_enable'] = $value;
|
20 |
-
update_option( $option_name, $gdpr_options );
|
21 |
-
$gdpr_options = get_option( $option_name );
|
22 |
-
foreach ( $_POST as $form_key => $form_value ) :
|
23 |
-
if ( $form_key === 'moove_gdpr_cookies_policy_tab_content' ) :
|
24 |
-
$value = wp_unslash( $form_value );
|
25 |
-
$gdpr_options[$form_key.$wpml_lang] = $value;
|
26 |
-
update_option( $option_name, $gdpr_options );
|
27 |
-
$gdpr_options = get_option( $option_name );
|
28 |
-
elseif ( $form_key !== 'moove_gdpr_cookie_policy_enable' ) :
|
29 |
-
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
30 |
-
$gdpr_options[$form_key] = $value;
|
31 |
-
update_option( $option_name, $gdpr_options );
|
32 |
-
$gdpr_options = get_option( $option_name );
|
33 |
-
endif;
|
34 |
-
endforeach;
|
35 |
-
endif;
|
36 |
-
do_action('gdpr_cookie_filter_settings');
|
37 |
-
?>
|
38 |
-
<script>
|
39 |
-
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
40 |
-
</script>
|
41 |
-
<?php
|
42 |
-
endif;
|
43 |
-
endif;
|
44 |
-
?>
|
45 |
-
<?php
|
46 |
-
$nav_label = isset( $gdpr_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] ) && $gdpr_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] ? $gdpr_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] : __('Cookie Policy','gdpr-cookie-compliance');
|
47 |
-
?>
|
48 |
-
<h2><?php echo $nav_label; ?></h2>
|
49 |
-
<hr />
|
50 |
-
<form action="?page=moove-gdpr&tab=cookie_policy" method="post" id="moove_gdpr_tab_cookie_policy">
|
51 |
-
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
52 |
-
<table class="form-table">
|
53 |
-
<tbody>
|
54 |
-
<tr>
|
55 |
-
<th scope="row">
|
56 |
-
<label for="moove_gdpr_cookie_policy_enable"><?php _e('Turn','gdpr-cookie-compliance'); ?></label>
|
57 |
-
</th>
|
58 |
-
<td>
|
59 |
-
|
60 |
-
<!-- GDPR Rounded switch -->
|
61 |
-
<label class="gdpr-checkbox-toggle">
|
62 |
-
<input type="checkbox" name="moove_gdpr_cookie_policy_enable" id="moove_gdpr_cookie_policy_enable" <?php echo isset( $gdpr_options['moove_gdpr_cookie_policy_enable'] ) ? ( intval( $gdpr_options['moove_gdpr_cookie_policy_enable'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_cookie_policy_enable'] ) ? 'checked' : '' ) ) : ''; ?> >
|
63 |
-
<span class="gdpr-checkbox-slider" data-enable="<?php _e('On','gdpr-cookie-compliance'); ?>" data-disable="<?php _e('Off','gdpr-cookie-compliance'); ?>"></span>
|
64 |
-
</label>
|
65 |
-
|
66 |
-
</td>
|
67 |
-
</tr>
|
68 |
-
<tr>
|
69 |
-
<th scope="row">
|
70 |
-
<label for="moove_gdpr_cookie_policy_tab_nav_label"><?php _e('Tab Title','gdpr-cookie-compliance'); ?></label>
|
71 |
-
</th>
|
72 |
-
<td>
|
73 |
-
<input name="moove_gdpr_cookie_policy_tab_nav_label<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_cookie_policy_tab_nav_label" value="<?php echo $nav_label; ?>" class="regular-text">
|
74 |
-
</td>
|
75 |
-
</tr>
|
76 |
-
|
77 |
-
<tr>
|
78 |
-
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
79 |
-
<label for="moove_gdpr_cookies_policy_tab_content"><?php _e('Tab Content','gdpr-cookie-compliance'); ?></label>
|
80 |
-
</th>
|
81 |
-
</tr>
|
82 |
-
<tr class="moove_gdpr_table_form_holder">
|
83 |
-
<th colspan="2" scope="row">
|
84 |
-
<?php
|
85 |
-
$content = isset( $gdpr_options['moove_gdpr_cookies_policy_tab_content'.$wpml_lang] ) && $gdpr_options['moove_gdpr_cookies_policy_tab_content'.$wpml_lang] ? wp_unslash( $gdpr_options['moove_gdpr_cookies_policy_tab_content'.$wpml_lang] ) : false;
|
86 |
-
if ( ! $content ) :
|
87 |
-
$_content = $gdpr_default_content->moove_gdpr_get_cookie_policy_content();
|
88 |
-
$content = $_content;
|
89 |
-
endif;
|
90 |
-
?>
|
91 |
-
<?php
|
92 |
-
$settings = array (
|
93 |
-
'media_buttons' => false,
|
94 |
-
'editor_height' => 150,
|
95 |
-
);
|
96 |
-
wp_editor( $content, 'moove_gdpr_cookies_policy_tab_content', $settings );
|
97 |
-
?>
|
98 |
-
</th>
|
99 |
-
</tr>
|
100 |
-
|
101 |
-
</tbody>
|
102 |
-
</table>
|
103 |
-
|
104 |
-
<hr />
|
105 |
-
<br />
|
106 |
-
<button type="submit" class="button button-primary"><?php _e('Save changes','gdpr-cookie-compliance'); ?></button>
|
107 |
-
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
views/moove/admin/settings/export-import.php
CHANGED
@@ -1,4 +1,12 @@
|
|
1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
<hr />
|
3 |
-
|
4 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Export Import Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
?>
|
10 |
+
<h2><?php esc_attr_e('Export / Import Settings','gdpr-cookie-compliance-addon'); ?></h2>
|
11 |
<hr />
|
|
|
12 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
views/moove/admin/settings/floating-button.php
ADDED
@@ -0,0 +1,143 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Floating Button Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
11 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
12 |
+
$gdpr_options = get_option( $option_name );
|
13 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
14 |
+
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
15 |
+
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
16 |
+
if ( ! wp_verify_nonce( sanitize_key( wp_unslash( $_POST['moove_gdpr_nonce'] ) ), 'moove_gdpr_nonce_field' ) ) :
|
17 |
+
die( 'Security check' );
|
18 |
+
else :
|
19 |
+
if ( is_array( $_POST ) ) :
|
20 |
+
if ( isset( $_POST['moove_gdpr_floating_button_enable'] ) ) :
|
21 |
+
$value = 1;
|
22 |
+
else :
|
23 |
+
$value = 0;
|
24 |
+
endif;
|
25 |
+
$gdpr_options['moove_gdpr_floating_button_enable'] = $value;
|
26 |
+
update_option( $option_name, $gdpr_options );
|
27 |
+
$gdpr_options = get_option( $option_name );
|
28 |
+
|
29 |
+
foreach ( $_POST as $form_key => $form_value ) :
|
30 |
+
if ( 'moove_gdpr_floating_button_enable' !== $form_key ) :
|
31 |
+
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
32 |
+
$gdpr_options[ $form_key ] = $value;
|
33 |
+
update_option( $option_name, $gdpr_options );
|
34 |
+
$gdpr_options = get_option( $option_name );
|
35 |
+
endif;
|
36 |
+
endforeach;
|
37 |
+
endif;
|
38 |
+
do_action( 'gdpr_cookie_filter_settings' );
|
39 |
+
?>
|
40 |
+
<script>
|
41 |
+
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
42 |
+
</script>
|
43 |
+
<?php
|
44 |
+
endif;
|
45 |
+
endif;
|
46 |
+
?>
|
47 |
+
<form action="<?php esc_url( admin_url( '?page=moove-gdpr&tab=floating_button' ) ); ?>" method="post" id="moove_gdpr_tab_floating_button">
|
48 |
+
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
49 |
+
<h2><?php esc_html_e( 'Floating Button', 'gdpr-cookie-compliance' ); ?></h2>
|
50 |
+
<hr />
|
51 |
+
|
52 |
+
<table class="form-table">
|
53 |
+
<tbody>
|
54 |
+
<tr>
|
55 |
+
<th scope="row">
|
56 |
+
<label for="moove_gdpr_floating_button_enable"><?php esc_html_e( 'Floating Button', 'gdpr-cookie-compliance' ); ?></label>
|
57 |
+
</th>
|
58 |
+
<td>
|
59 |
+
<!-- GDPR Rounded switch -->
|
60 |
+
<label class="gdpr-checkbox-toggle">
|
61 |
+
<input type="checkbox" name="moove_gdpr_floating_button_enable" id="moove_gdpr_floating_button_enable" <?php echo isset( $gdpr_options['moove_gdpr_floating_button_enable'] ) ? ( intval( $gdpr_options['moove_gdpr_floating_button_enable'] ) === 1 ? 'checked' : '' ) : ''; ?> >
|
62 |
+
<span class="gdpr-checkbox-slider" data-enable="<?php esc_html_e( 'Enabled', 'gdpr-cookie-compliance' ); ?>" data-disable="<?php esc_html_e( 'Disabled', 'gdpr-cookie-compliance' ); ?>"></span>
|
63 |
+
</label>
|
64 |
+
|
65 |
+
</td>
|
66 |
+
</tr>
|
67 |
+
|
68 |
+
<tr>
|
69 |
+
<th scope="row">
|
70 |
+
<label for="moove_gdpr_floating_button_label"><?php esc_html_e( 'Button - Hover Label', 'gdpr-cookie-compliance' ); ?></label>
|
71 |
+
</th>
|
72 |
+
<td>
|
73 |
+
<input name="moove_gdpr_floating_button_label<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_floating_button_label" value="<?php echo isset( $gdpr_options[ 'moove_gdpr_floating_button_label' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_floating_button_label' . $wpml_lang ] ? esc_attr( $gdpr_options[ 'moove_gdpr_floating_button_label' . $wpml_lang ] ) : esc_attr__( 'Change cookie settings', 'gdpr-cookie-compliance' ); ?>" class="regular-text">
|
74 |
+
</td>
|
75 |
+
</tr>
|
76 |
+
|
77 |
+
<tr>
|
78 |
+
<th scope="row">
|
79 |
+
<label for="moove_gdpr_floating_button_position"><?php esc_html_e( 'Button - Custom Position (CSS)', 'gdpr-cookie-compliance' ); ?></label>
|
80 |
+
</th>
|
81 |
+
<td>
|
82 |
+
<input name="moove_gdpr_floating_button_position" type="text" id="moove_gdpr_floating_button_position" value="<?php echo isset( $gdpr_options['moove_gdpr_floating_button_position'] ) && $gdpr_options['moove_gdpr_floating_button_position'] ? esc_attr( $gdpr_options['moove_gdpr_floating_button_position'] ) : 'bottom: 20px; left: 20px;'; ?>" class="regular-text">
|
83 |
+
<p class="description" id="moove_gdpr_floating_button_position-description">
|
84 |
+
<?php
|
85 |
+
$content = __( 'You can align the position eg.: <strong>top: 20px; right: 20px;</strong>', 'gdpr-cookie-compliance' );
|
86 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
87 |
+
?>
|
88 |
+
</p>
|
89 |
+
</td>
|
90 |
+
</tr>
|
91 |
+
|
92 |
+
<tr>
|
93 |
+
<th scope="row">
|
94 |
+
<label for="moove_gdpr_floating_button_background_colour"><?php esc_html_e( 'Button - Background Colour', 'gdpr-cookie-compliance' ); ?></label>
|
95 |
+
</th>
|
96 |
+
<td>
|
97 |
+
<div class="iris-colorpicker-group-cnt">
|
98 |
+
<?php $color = isset( $gdpr_options['moove_gdpr_floating_button_background_colour'] ) && $gdpr_options['moove_gdpr_floating_button_background_colour'] ? $gdpr_options['moove_gdpr_floating_button_background_colour'] : '373737'; ?>
|
99 |
+
<input class="iris-colorpicker regular-text" name="moove_gdpr_floating_button_background_colour" value="<?php echo esc_attr( $color ); ?>" style="background-color: <?php echo esc_attr( $color ); ?>;" >
|
100 |
+
<span class="iris-selectbtn"><?php esc_html_e( 'Select', 'gdpr-cookie-compliance' ); ?></span>
|
101 |
+
</div>
|
102 |
+
</td>
|
103 |
+
</tr>
|
104 |
+
|
105 |
+
<tr>
|
106 |
+
<th scope="row">
|
107 |
+
<label for="moove_gdpr_floating_button_hover_background_colour"><?php esc_html_e( 'Button - Hover Background Colour', 'gdpr-cookie-compliance' ); ?></label>
|
108 |
+
</th>
|
109 |
+
<td>
|
110 |
+
<div class="iris-colorpicker-group-cnt">
|
111 |
+
<?php
|
112 |
+
$color = isset( $gdpr_options['moove_gdpr_floating_button_hover_background_colour'] ) && $gdpr_options['moove_gdpr_floating_button_hover_background_colour'] ? $gdpr_options['moove_gdpr_floating_button_hover_background_colour'] : '000000';
|
113 |
+
?>
|
114 |
+
<input class="iris-colorpicker regular-text" name="moove_gdpr_floating_button_hover_background_colour" value="<?php echo esc_attr( $color ); ?>" style="background-color: <?php echo esc_attr( $color ); ?>;" >
|
115 |
+
<span class="iris-selectbtn"><?php esc_html_e( 'Select', 'gdpr-cookie-compliance' ); ?></span>
|
116 |
+
</div>
|
117 |
+
</td>
|
118 |
+
</tr>
|
119 |
+
|
120 |
+
<tr>
|
121 |
+
<th scope="row">
|
122 |
+
<label for="moove_gdpr_floating_button_font_colour"><?php esc_html_e( 'Button - Font Colour', 'gdpr-cookie-compliance' ); ?></label>
|
123 |
+
</th>
|
124 |
+
<td>
|
125 |
+
<div class="iris-colorpicker-group-cnt">
|
126 |
+
<?php $color = isset( $gdpr_options['moove_gdpr_floating_button_font_colour'] ) && $gdpr_options['moove_gdpr_floating_button_font_colour'] ? $gdpr_options['moove_gdpr_floating_button_font_colour'] : 'ffffff'; ?>
|
127 |
+
<input class="iris-colorpicker regular-text" name="moove_gdpr_floating_button_font_colour" value="<?php echo esc_attr( $color ); ?>" style="background-color: <?php echo esc_attr( $color ); ?>;" >
|
128 |
+
<span class="iris-selectbtn"><?php esc_html_e( 'Select', 'gdpr-cookie-compliance' ); ?></span>
|
129 |
+
</div>
|
130 |
+
</td>
|
131 |
+
</tr>
|
132 |
+
|
133 |
+
<?php do_action( 'gdpr_cc_floating_button_settings' ); ?>
|
134 |
+
|
135 |
+
</tbody>
|
136 |
+
</table>
|
137 |
+
|
138 |
+
<br />
|
139 |
+
<hr />
|
140 |
+
<br />
|
141 |
+
<button type="submit" class="button button-primary"><?php esc_html_e( 'Save changes', 'gdpr-cookie-compliance' ); ?></button>
|
142 |
+
<?php do_action( 'gdpr_cc_floating_button_settings' ); ?>
|
143 |
+
</form>
|
views/moove/admin/settings/floating_button.php
DELETED
@@ -1,129 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
3 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
4 |
-
$gdpr_options = get_option( $option_name );
|
5 |
-
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
6 |
-
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
7 |
-
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
8 |
-
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
9 |
-
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
10 |
-
die( 'Security check' );
|
11 |
-
else :
|
12 |
-
if ( is_array( $_POST ) ) :
|
13 |
-
if ( isset( $_POST['moove_gdpr_floating_button_enable'] ) ) :
|
14 |
-
$value = 1;
|
15 |
-
else :
|
16 |
-
$value = 0;
|
17 |
-
endif;
|
18 |
-
$gdpr_options['moove_gdpr_floating_button_enable'] = $value;
|
19 |
-
update_option( $option_name, $gdpr_options );
|
20 |
-
$gdpr_options = get_option( $option_name );
|
21 |
-
|
22 |
-
foreach ( $_POST as $form_key => $form_value ) :
|
23 |
-
if ( $form_key !== 'moove_gdpr_floating_button_enable' ) :
|
24 |
-
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
25 |
-
$gdpr_options[$form_key] = $value;
|
26 |
-
update_option( $option_name, $gdpr_options );
|
27 |
-
$gdpr_options = get_option( $option_name );
|
28 |
-
endif;
|
29 |
-
endforeach;
|
30 |
-
endif;
|
31 |
-
do_action('gdpr_cookie_filter_settings');
|
32 |
-
?>
|
33 |
-
<script>
|
34 |
-
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
35 |
-
</script>
|
36 |
-
<?php
|
37 |
-
endif;
|
38 |
-
endif;
|
39 |
-
?>
|
40 |
-
<form action="?page=moove-gdpr&tab=floating_button" method="post" id="moove_gdpr_tab_floating_button">
|
41 |
-
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
42 |
-
<h2><?php _e('Floating Button','gdpr-cookie-compliance'); ?></h2>
|
43 |
-
<hr />
|
44 |
-
|
45 |
-
<table class="form-table">
|
46 |
-
<tbody>
|
47 |
-
<tr>
|
48 |
-
<th scope="row">
|
49 |
-
<label for="moove_gdpr_floating_button_enable"><?php _e('Floating Button','gdpr-cookie-compliance'); ?></label>
|
50 |
-
</th>
|
51 |
-
<td>
|
52 |
-
<!-- GDPR Rounded switch -->
|
53 |
-
<label class="gdpr-checkbox-toggle">
|
54 |
-
<input type="checkbox" name="moove_gdpr_floating_button_enable" id="moove_gdpr_floating_button_enable" <?php echo isset( $gdpr_options['moove_gdpr_floating_button_enable'] ) ? ( intval( $gdpr_options['moove_gdpr_floating_button_enable'] ) === 1 ? 'checked' : '' ) : ''; ?> >
|
55 |
-
<span class="gdpr-checkbox-slider" data-enable="<?php _e('Enabled','gdpr-cookie-compliance'); ?>" data-disable="<?php _e('Disabled','gdpr-cookie-compliance'); ?>"></span>
|
56 |
-
</label>
|
57 |
-
|
58 |
-
</td>
|
59 |
-
</tr>
|
60 |
-
|
61 |
-
<tr>
|
62 |
-
<th scope="row">
|
63 |
-
<label for="moove_gdpr_floating_button_label"><?php _e('Button - Hover Label','gdpr-cookie-compliance'); ?></label>
|
64 |
-
</th>
|
65 |
-
<td>
|
66 |
-
<input name="moove_gdpr_floating_button_label<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_floating_button_label" value="<?php echo isset( $gdpr_options['moove_gdpr_floating_button_label'.$wpml_lang] ) && $gdpr_options['moove_gdpr_floating_button_label'.$wpml_lang] ? $gdpr_options['moove_gdpr_floating_button_label'.$wpml_lang] : __('Change cookie settings','gdpr-cookie-compliance'); ?>" class="regular-text">
|
67 |
-
</td>
|
68 |
-
</tr>
|
69 |
-
|
70 |
-
<tr>
|
71 |
-
<th scope="row">
|
72 |
-
<label for="moove_gdpr_floating_button_position"><?php _e('Button - Custom Position (CSS)','gdpr-cookie-compliance'); ?></label>
|
73 |
-
</th>
|
74 |
-
<td>
|
75 |
-
<input name="moove_gdpr_floating_button_position" type="text" id="moove_gdpr_floating_button_position" value="<?php echo isset( $gdpr_options['moove_gdpr_floating_button_position'] ) && $gdpr_options['moove_gdpr_floating_button_position'] ? $gdpr_options['moove_gdpr_floating_button_position'] : 'bottom: 20px; left: 20px;'; ?>" class="regular-text">
|
76 |
-
<p class="description" id="moove_gdpr_floating_button_position-description"><?php _e('You can align the position eg.: <strong>top: 20px; right: 20px;</strong>','gdpr-cookie-compliance'); ?></p>
|
77 |
-
</td>
|
78 |
-
</tr>
|
79 |
-
|
80 |
-
<tr>
|
81 |
-
<th scope="row">
|
82 |
-
<label for="moove_gdpr_floating_button_background_colour"><?php _e('Button - Background Colour','gdpr-cookie-compliance'); ?></label>
|
83 |
-
</th>
|
84 |
-
<td>
|
85 |
-
<div class="iris-colorpicker-group-cnt">
|
86 |
-
<?php $color = isset( $gdpr_options['moove_gdpr_floating_button_background_colour'] ) && $gdpr_options['moove_gdpr_floating_button_background_colour'] ? $gdpr_options['moove_gdpr_floating_button_background_colour'] : '373737'; ?>
|
87 |
-
<input class="iris-colorpicker regular-text" name="moove_gdpr_floating_button_background_colour" value="<?php echo $color; ?>" style="background-color: <?php echo $color; ?>;" >
|
88 |
-
<span class="iris-selectbtn"><?php _e('Select','gdpr-cookie-compliance'); ?></span>
|
89 |
-
</div>
|
90 |
-
</td>
|
91 |
-
</tr>
|
92 |
-
|
93 |
-
<tr>
|
94 |
-
<th scope="row">
|
95 |
-
<label for="moove_gdpr_floating_button_hover_background_colour"><?php _e('Button - Hover Background Colour','gdpr-cookie-compliance'); ?></label>
|
96 |
-
</th>
|
97 |
-
<td>
|
98 |
-
<div class="iris-colorpicker-group-cnt">
|
99 |
-
<?php $color = isset( $gdpr_options['moove_gdpr_floating_button_hover_background_colour'] ) && $gdpr_options['moove_gdpr_floating_button_hover_background_colour'] ? $gdpr_options['moove_gdpr_floating_button_hover_background_colour'] : '000000';; ?>
|
100 |
-
<input class="iris-colorpicker regular-text" name="moove_gdpr_floating_button_hover_background_colour" value="<?php echo $color ?>" style="background-color: <?php echo $color; ?>;" >
|
101 |
-
<span class="iris-selectbtn"><?php _e('Select','gdpr-cookie-compliance'); ?></span>
|
102 |
-
</div>
|
103 |
-
</td>
|
104 |
-
</tr>
|
105 |
-
|
106 |
-
<tr>
|
107 |
-
<th scope="row">
|
108 |
-
<label for="moove_gdpr_floating_button_font_colour"><?php _e('Button - Font Colour','gdpr-cookie-compliance'); ?></label>
|
109 |
-
</th>
|
110 |
-
<td>
|
111 |
-
<div class="iris-colorpicker-group-cnt">
|
112 |
-
<?php $color = isset( $gdpr_options['moove_gdpr_floating_button_font_colour'] ) && $gdpr_options['moove_gdpr_floating_button_font_colour'] ? $gdpr_options['moove_gdpr_floating_button_font_colour'] : 'ffffff'; ?>
|
113 |
-
<input class="iris-colorpicker regular-text" name="moove_gdpr_floating_button_font_colour" value="<?php echo $color; ?>" style="background-color: <?php echo $color; ?>;" >
|
114 |
-
<span class="iris-selectbtn"><?php _e('Select','gdpr-cookie-compliance'); ?></span>
|
115 |
-
</div>
|
116 |
-
</td>
|
117 |
-
</tr>
|
118 |
-
|
119 |
-
<?php do_action('gdpr_cc_floating_button_settings'); ?>
|
120 |
-
|
121 |
-
</tbody>
|
122 |
-
</table>
|
123 |
-
|
124 |
-
<br />
|
125 |
-
<hr />
|
126 |
-
<br />
|
127 |
-
<button type="submit" class="button button-primary"><?php _e('Save changes','gdpr-cookie-compliance'); ?></button>
|
128 |
-
<?php do_action('gdpr_cc_floating_button_settings'); ?>
|
129 |
-
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
views/moove/admin/settings/full-screen-mode.php
CHANGED
@@ -1,4 +1,12 @@
|
|
1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
<hr />
|
3 |
-
|
4 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Full Screen Mode Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
?>
|
10 |
+
<h2><?php esc_html_e('Full-Screen Mode Setup','gdpr-cookie-compliance'); ?></h2>
|
11 |
<hr />
|
|
|
12 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
views/moove/admin/settings/general-settings.php
ADDED
@@ -0,0 +1,169 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* General Settings Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
11 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
12 |
+
$gdpr_options = get_option( $option_name );
|
13 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
14 |
+
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
15 |
+
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
16 |
+
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
17 |
+
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
18 |
+
die( 'Security check' );
|
19 |
+
else :
|
20 |
+
if ( is_array( $_POST ) ) :
|
21 |
+
|
22 |
+
if ( isset( $_POST['moove_gdpr_modal_powered_by_disable'] ) ) :
|
23 |
+
$value = intval( $_POST['moove_gdpr_modal_powered_by_disable'] );
|
24 |
+
else :
|
25 |
+
$value = 0;
|
26 |
+
endif;
|
27 |
+
|
28 |
+
if ( isset( $_POST[ 'moove_gdpr_modal_powered_by_label' . $wpml_lang ] ) ) :
|
29 |
+
if ( 0 === strlen( trim( sanitize_text_field( wp_unslash( $_POST[ 'moove_gdpr_modal_powered_by_label' . $wpml_lang ] ) ) ) ) ) :
|
30 |
+
$value = 1;
|
31 |
+
else :
|
32 |
+
$value = 0;
|
33 |
+
endif;
|
34 |
+
endif;
|
35 |
+
|
36 |
+
|
37 |
+
$gdpr_options['moove_gdpr_modal_powered_by_disable'] = $value;
|
38 |
+
update_option( $option_name, $gdpr_options );
|
39 |
+
$gdpr_options = get_option( $option_name );
|
40 |
+
foreach ( $_POST as $form_key => $form_value ) :
|
41 |
+
if ( 'moove_gdpr_info_bar_content' === $form_key ) :
|
42 |
+
$value = wpautop( wp_unslash( $form_value ) );
|
43 |
+
$gdpr_options[ $form_key . $wpml_lang ] = $value;
|
44 |
+
update_option( $option_name, $gdpr_options );
|
45 |
+
$gdpr_options = get_option( $option_name );
|
46 |
+
elseif ( 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang === $form_key ) :
|
47 |
+
$value = wpautop( wp_unslash( $form_value ) );
|
48 |
+
$gdpr_options[ $form_key ] = $value;
|
49 |
+
update_option( $option_name, $gdpr_options );
|
50 |
+
$gdpr_options = get_option( $option_name );
|
51 |
+
elseif ( 'moove_gdpr_floating_button_enable' !== $form_key && 'moove_gdpr_modal_powered_by_disable' !== $form_key ) :
|
52 |
+
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
53 |
+
$gdpr_options[ $form_key ] = $value;
|
54 |
+
update_option( $option_name, $gdpr_options );
|
55 |
+
$gdpr_options = get_option( $option_name );
|
56 |
+
endif;
|
57 |
+
endforeach;
|
58 |
+
endif;
|
59 |
+
do_action( 'gdpr_cookie_filter_settings' );
|
60 |
+
?>
|
61 |
+
<script>
|
62 |
+
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
63 |
+
</script>
|
64 |
+
<?php
|
65 |
+
endif;
|
66 |
+
endif;
|
67 |
+
?>
|
68 |
+
<form action="<?php esc_url( admin_url( '?page=moove-gdpr&tab=general-settings' ) ); ?>" method="post" id="moove_gdpr_tab_general_settings">
|
69 |
+
<h2><?php esc_html_e( 'Cookie Settings Screen - General Setup', 'gdpr-cookie-compliance' ); ?></h2>
|
70 |
+
<hr />
|
71 |
+
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
72 |
+
<table class="form-table">
|
73 |
+
<tbody>
|
74 |
+
<tr>
|
75 |
+
<th scope="row">
|
76 |
+
<label for="moove_gdpr_plugin_layout"><?php esc_html_e( 'Choose your layout', 'gdpr-cookie-compliance' ); ?></label>
|
77 |
+
</th>
|
78 |
+
<td>
|
79 |
+
<input name="moove_gdpr_plugin_layout" type="radio" value="v1" id="moove_gdpr_plugin_layout_v1" <?php echo isset( $gdpr_options['moove_gdpr_plugin_layout'] ) ? ( 'v1' === $gdpr_options['moove_gdpr_plugin_layout'] ? 'checked' : '' ) : 'checked'; ?> class="on-off">
|
80 |
+
<label for="moove_gdpr_plugin_layout_v1">
|
81 |
+
<?php esc_html_e( 'Tabs layout', 'gdpr-cookie-compliance' ); ?>
|
82 |
+
</label>
|
83 |
+
<span class="separator"></span>
|
84 |
+
|
85 |
+
<input name="moove_gdpr_plugin_layout" type="radio" value="v2" id="moove_gdpr_plugin_layout_v2" <?php echo isset( $gdpr_options['moove_gdpr_plugin_layout'] ) ? ( 'v2' === $gdpr_options['moove_gdpr_plugin_layout'] ? 'checked' : '' ) : ''; ?> class="on-off">
|
86 |
+
<label for="moove_gdpr_plugin_layout_v2">
|
87 |
+
<?php esc_html_e( 'One page layout', 'gdpr-cookie-compliance' ); ?>
|
88 |
+
</label>
|
89 |
+
<?php do_action( 'gdpr_cc_moove_gdpr_plugin_layout_settings' ); ?>
|
90 |
+
|
91 |
+
</td>
|
92 |
+
</tr>
|
93 |
+
|
94 |
+
<tr>
|
95 |
+
<th scope="row">
|
96 |
+
<label for="moove_gdpr_modal_save_button_label"><?php esc_html_e( 'Save Settings - Button Label', 'gdpr-cookie-compliance' ); ?></label>
|
97 |
+
</th>
|
98 |
+
<td>
|
99 |
+
<input name="moove_gdpr_modal_save_button_label<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_modal_save_button_label" value="<?php echo isset( $gdpr_options[ 'moove_gdpr_modal_save_button_label' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_modal_save_button_label' . $wpml_lang ] ? esc_attr( $gdpr_options[ 'moove_gdpr_modal_save_button_label' . $wpml_lang ] ) : esc_html__( 'Save Changes', 'gdpr-cookie-compliance' ); ?>" class="regular-text">
|
100 |
+
</td>
|
101 |
+
</tr>
|
102 |
+
|
103 |
+
<tr>
|
104 |
+
<th scope="row">
|
105 |
+
<label for="moove_gdpr_modal_allow_button_label"><?php esc_html_e( 'Enable All - Button Label', 'gdpr-cookie-compliance' ); ?></label>
|
106 |
+
</th>
|
107 |
+
<td>
|
108 |
+
<input name="moove_gdpr_modal_allow_button_label<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_modal_allow_button_label" value="<?php echo isset( $gdpr_options[ 'moove_gdpr_modal_allow_button_label' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_modal_allow_button_label' . $wpml_lang ] ? esc_attr( $gdpr_options[ 'moove_gdpr_modal_allow_button_label' . $wpml_lang ] ) : esc_html__( 'Enable All', 'gdpr-cookie-compliance' ); ?>" class="regular-text">
|
109 |
+
</td>
|
110 |
+
</tr>
|
111 |
+
|
112 |
+
<tr>
|
113 |
+
<th scope="row">
|
114 |
+
<label for="moove_gdpr_modal_enabled_checkbox_label">
|
115 |
+
<?php esc_html_e( 'Checkbox Labels', 'gdpr-cookie-compliance' ); ?>
|
116 |
+
</label>
|
117 |
+
</th>
|
118 |
+
<td>
|
119 |
+
<input name="moove_gdpr_modal_enabled_checkbox_label<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_modal_enabled_checkbox_label" value="<?php echo isset( $gdpr_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] ? esc_attr( $gdpr_options[ 'moove_gdpr_modal_enabled_checkbox_label' . $wpml_lang ] ) : esc_html__( 'Enabled', 'gdpr-cookie-compliance' ); ?>" class="regular-text"><br />
|
120 |
+
<input name="moove_gdpr_modal_disabled_checkbox_label<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_modal_disabled_checkbox_label" value="<?php echo isset( $gdpr_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] ? esc_attr( $gdpr_options[ 'moove_gdpr_modal_disabled_checkbox_label' . $wpml_lang ] ) : esc_html__( 'Disabled', 'gdpr-cookie-compliance' ); ?>" class="regular-text">
|
121 |
+
</td>
|
122 |
+
|
123 |
+
</tr>
|
124 |
+
|
125 |
+
<tr>
|
126 |
+
<th scope="row">
|
127 |
+
<label><?php esc_html_e( 'Powered by GDPR', 'gdpr-cookie-compliance' ); ?></label>
|
128 |
+
</th>
|
129 |
+
<td>
|
130 |
+
<span class="powered-by-label">
|
131 |
+
<label for="">Default label:</label>
|
132 |
+
<input name="moove_gdpr_modal_powered_by_label<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_modal_powered_by_label" value="<?php echo isset( $gdpr_options[ 'moove_gdpr_modal_powered_by_label' . $wpml_lang ] ) ? esc_attr( $gdpr_options[ 'moove_gdpr_modal_powered_by_label' . $wpml_lang ] ) : 'Powered by'; ?>" class="regular-text">
|
133 |
+
</span>
|
134 |
+
|
135 |
+
<input name="moove_gdpr_modal_powered_by_disable" type="hidden" <?php echo isset( $gdpr_options['moove_gdpr_modal_powered_by_disable'] ) ? ( intval( $gdpr_options['moove_gdpr_modal_powered_by_disable'] ) === 1 ? 'checked' : '' ) : ''; ?> id="moove_gdpr_modal_powered_by_disable" value="<?php echo isset( $gdpr_options['moove_gdpr_modal_powered_by_disable'] ) ? ( intval( $gdpr_options['moove_gdpr_modal_powered_by_disable'] ) === 1 ? '1' : '0' ) : '0'; ?>">
|
136 |
+
</td>
|
137 |
+
</tr>
|
138 |
+
<?php do_action( 'gdpr_cc_general_modal_settings' ); ?>
|
139 |
+
</tbody>
|
140 |
+
</table>
|
141 |
+
|
142 |
+
<br />
|
143 |
+
<hr />
|
144 |
+
<br />
|
145 |
+
<button type="submit" class="button button-primary"><?php esc_html_e( 'Save changes', 'gdpr-cookie-compliance' ); ?></button>
|
146 |
+
|
147 |
+
<button type="button" class="button button-primary button-reset-settings"><?php esc_html_e( 'Reset Settings', 'gdpr-cookie-compliance' ); ?></button>
|
148 |
+
|
149 |
+
<?php do_action( 'gdpr_cc_general_buttons_settings' ); ?>
|
150 |
+
</form>
|
151 |
+
|
152 |
+
<div class="gdpr-admin-popup gdpr-admin-popup-reset-settings" style="display: none;">
|
153 |
+
<span class="gdpr-popup-overlay"></span>
|
154 |
+
<div class="gdpr-popup-content">
|
155 |
+
<div class="gdpr-popup-content-header">
|
156 |
+
<a href="#" class="gdpr-popup-close"><span class="dashicons dashicons-no-alt"></span></a>
|
157 |
+
</div>
|
158 |
+
<!-- .gdpr-popup-content-header -->
|
159 |
+
<div class="gdpr-popup-content-content">
|
160 |
+
<h4><strong><?php esc_html_e( 'Please confirm that you would like to reset the plugin to default.', 'gdpr-cookie-compliance' ); ?> </strong></h4><p><strong><?php esc_html_e( 'This action will remove all of the modifications and settings.', 'gdpr-cookie-compliance' ); ?></strong></p>
|
161 |
+
<button class="button button-primary button-reset-settings-confirm" data-ajaxurl="<?php echo admin_url( 'admin-ajax.php' ); ?>">
|
162 |
+
<?php esc_html_e( 'Reset plugin to default', 'gdpr-cookie-compliance' ); ?>
|
163 |
+
</button>
|
164 |
+
</div>
|
165 |
+
<!-- .gdpr-popup-content-content -->
|
166 |
+
</div>
|
167 |
+
<!-- .gdpr-popup-content -->
|
168 |
+
</div>
|
169 |
+
<!-- .gdpr-admin-popup -->
|
views/moove/admin/settings/general_settings.php
DELETED
@@ -1,136 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
3 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
4 |
-
$gdpr_options = get_option( $option_name );
|
5 |
-
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
6 |
-
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
7 |
-
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
8 |
-
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
9 |
-
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
10 |
-
die( 'Security check' );
|
11 |
-
else :
|
12 |
-
if ( is_array( $_POST ) ) :
|
13 |
-
|
14 |
-
if ( isset( $_POST['moove_gdpr_modal_powered_by_disable'] ) ) :
|
15 |
-
$value = intval( $_POST['moove_gdpr_modal_powered_by_disable'] );
|
16 |
-
else :
|
17 |
-
$value = 0;
|
18 |
-
endif;
|
19 |
-
|
20 |
-
if ( isset( $_POST['moove_gdpr_modal_powered_by_label' . $wpml_lang] ) ) :
|
21 |
-
if ( strlen( trim( $_POST['moove_gdpr_modal_powered_by_label' . $wpml_lang] ) ) === 0 ) :
|
22 |
-
$value = 1;
|
23 |
-
else :
|
24 |
-
$value = 0;
|
25 |
-
endif;
|
26 |
-
endif;
|
27 |
-
|
28 |
-
|
29 |
-
$gdpr_options['moove_gdpr_modal_powered_by_disable'] = $value;
|
30 |
-
update_option( $option_name, $gdpr_options );
|
31 |
-
$gdpr_options = get_option( $option_name );
|
32 |
-
foreach ( $_POST as $form_key => $form_value ) :
|
33 |
-
if ( $form_key === 'moove_gdpr_info_bar_content' ) :
|
34 |
-
$value = wpautop( wp_unslash( $form_value ) );
|
35 |
-
$gdpr_options[$form_key.$wpml_lang] = $value;
|
36 |
-
update_option( $option_name, $gdpr_options );
|
37 |
-
$gdpr_options = get_option( $option_name );
|
38 |
-
elseif ( $form_key === 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ) :
|
39 |
-
$value = wpautop( wp_unslash( $form_value ) );
|
40 |
-
$gdpr_options[$form_key] = $value;
|
41 |
-
update_option( $option_name, $gdpr_options );
|
42 |
-
$gdpr_options = get_option( $option_name );
|
43 |
-
elseif ( $form_key !== 'moove_gdpr_floating_button_enable' && $form_key !== 'moove_gdpr_modal_powered_by_disable' ) :
|
44 |
-
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
45 |
-
$gdpr_options[$form_key] = $value;
|
46 |
-
update_option( $option_name, $gdpr_options );
|
47 |
-
$gdpr_options = get_option( $option_name );
|
48 |
-
endif;
|
49 |
-
endforeach;
|
50 |
-
endif;
|
51 |
-
do_action('gdpr_cookie_filter_settings');
|
52 |
-
?>
|
53 |
-
<script>
|
54 |
-
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
55 |
-
</script>
|
56 |
-
<?php
|
57 |
-
endif;
|
58 |
-
endif;
|
59 |
-
?>
|
60 |
-
<form action="?page=moove-gdpr&tab=general_settings" method="post" id="moove_gdpr_tab_general_settings">
|
61 |
-
<h2><?php _e('Cookie Settings Screen - General Setup','gdpr-cookie-compliance'); ?></h2>
|
62 |
-
<hr />
|
63 |
-
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
64 |
-
<table class="form-table">
|
65 |
-
<tbody>
|
66 |
-
<tr>
|
67 |
-
<th scope="row">
|
68 |
-
<label for="moove_gdpr_plugin_layout"><?php _e('Choose your layout','gdpr-cookie-compliance'); ?></label>
|
69 |
-
</th>
|
70 |
-
<td>
|
71 |
-
<input name="moove_gdpr_plugin_layout" type="radio" value="v1" id="moove_gdpr_plugin_layout_v1" <?php echo isset( $gdpr_options['moove_gdpr_plugin_layout'] ) ? ( $gdpr_options['moove_gdpr_plugin_layout'] === 'v1' ? 'checked' : '' ) : 'checked'; ?> class="on-off"> <label for="moove_gdpr_plugin_layout_v1"><?php _e('Tabs layout','gdpr-cookie-compliance'); ?></label>
|
72 |
-
<span class="separator"></span>
|
73 |
-
|
74 |
-
<input name="moove_gdpr_plugin_layout" type="radio" value="v2" id="moove_gdpr_plugin_layout_v2" <?php echo isset( $gdpr_options['moove_gdpr_plugin_layout'] ) ? ( $gdpr_options['moove_gdpr_plugin_layout'] === 'v2' ? 'checked' : '' ) : ''; ?> class="on-off"> <label for="moove_gdpr_plugin_layout_v2"><?php _e('One page layout','gdpr-cookie-compliance'); ?></label>
|
75 |
-
|
76 |
-
<?php do_action('gdpr_cc_moove_gdpr_plugin_layout_settings'); ?>
|
77 |
-
|
78 |
-
</td>
|
79 |
-
</tr>
|
80 |
-
|
81 |
-
<tr>
|
82 |
-
<th scope="row">
|
83 |
-
<label for="moove_gdpr_modal_save_button_label"><?php _e('Save Settings - Button Label','gdpr-cookie-compliance'); ?></label>
|
84 |
-
</th>
|
85 |
-
<td>
|
86 |
-
<input name="moove_gdpr_modal_save_button_label<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_modal_save_button_label" value="<?php echo isset( $gdpr_options['moove_gdpr_modal_save_button_label'.$wpml_lang] ) && $gdpr_options['moove_gdpr_modal_save_button_label'.$wpml_lang] ? $gdpr_options['moove_gdpr_modal_save_button_label'.$wpml_lang] : __('Save Changes','gdpr-cookie-compliance'); ?>" class="regular-text">
|
87 |
-
</td>
|
88 |
-
</tr>
|
89 |
-
|
90 |
-
<tr>
|
91 |
-
<th scope="row">
|
92 |
-
<label for="moove_gdpr_modal_allow_button_label"><?php _e('Enable All - Button Label','gdpr-cookie-compliance'); ?></label>
|
93 |
-
</th>
|
94 |
-
<td>
|
95 |
-
<input name="moove_gdpr_modal_allow_button_label<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_modal_allow_button_label" value="<?php echo isset( $gdpr_options['moove_gdpr_modal_allow_button_label'.$wpml_lang] ) && $gdpr_options['moove_gdpr_modal_allow_button_label'.$wpml_lang] ? $gdpr_options['moove_gdpr_modal_allow_button_label'.$wpml_lang] : __('Enable All','gdpr-cookie-compliance'); ?>" class="regular-text">
|
96 |
-
</td>
|
97 |
-
</tr>
|
98 |
-
|
99 |
-
<tr>
|
100 |
-
<th scope="row">
|
101 |
-
<label for="moove_gdpr_modal_enabled_checkbox_label"><?php _e('Checkbox Labels','gdpr-cookie-compliance'); ?></label>
|
102 |
-
</th>
|
103 |
-
<td>
|
104 |
-
<input name="moove_gdpr_modal_enabled_checkbox_label<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_modal_enabled_checkbox_label" value="<?php echo isset( $gdpr_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] ) && $gdpr_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] ? $gdpr_options['moove_gdpr_modal_enabled_checkbox_label'.$wpml_lang] : __('Enabled','gdpr-cookie-compliance'); ?>" class="regular-text"><br />
|
105 |
-
<input name="moove_gdpr_modal_disabled_checkbox_label<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_modal_disabled_checkbox_label" value="<?php echo isset( $gdpr_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] ) && $gdpr_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] ? $gdpr_options['moove_gdpr_modal_disabled_checkbox_label'.$wpml_lang] : __('Disabled','gdpr-cookie-compliance'); ?>" class="regular-text">
|
106 |
-
</td>
|
107 |
-
|
108 |
-
</tr>
|
109 |
-
|
110 |
-
<tr>
|
111 |
-
<th scope="row">
|
112 |
-
<label><?php _e('Powered by GDPR','gdpr-cookie-compliance'); ?></label>
|
113 |
-
</th>
|
114 |
-
<td>
|
115 |
-
<span class="powered-by-label">
|
116 |
-
<label for="">Default label:</label>
|
117 |
-
<input name="moove_gdpr_modal_powered_by_label<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_modal_powered_by_label" value="<?php echo isset( $gdpr_options['moove_gdpr_modal_powered_by_label'.$wpml_lang] ) ? $gdpr_options['moove_gdpr_modal_powered_by_label'.$wpml_lang] : 'Powered by'; ?>" class="regular-text">
|
118 |
-
</span>
|
119 |
-
|
120 |
-
<input name="moove_gdpr_modal_powered_by_disable" type="hidden" <?php echo isset( $gdpr_options['moove_gdpr_modal_powered_by_disable'] ) ? ( intval( $gdpr_options['moove_gdpr_modal_powered_by_disable'] ) === 1 ? 'checked' : '' ) : ''; ?> id="moove_gdpr_modal_powered_by_disable" value="<?php echo isset( $gdpr_options['moove_gdpr_modal_powered_by_disable'] ) ? ( intval( $gdpr_options['moove_gdpr_modal_powered_by_disable'] ) === 1 ? '1' : '0' ) : '0'; ?>">
|
121 |
-
|
122 |
-
</fieldset>
|
123 |
-
</td>
|
124 |
-
</tr>
|
125 |
-
<?php do_action('gdpr_cc_general_modal_settings'); ?>
|
126 |
-
|
127 |
-
|
128 |
-
</tbody>
|
129 |
-
</table>
|
130 |
-
|
131 |
-
<br />
|
132 |
-
<hr />
|
133 |
-
<br />
|
134 |
-
<button type="submit" class="button button-primary"><?php _e('Save changes','gdpr-cookie-compliance'); ?></button>
|
135 |
-
<?php do_action('gdpr_cc_general_buttons_settings'); ?>
|
136 |
-
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
views/moove/admin/settings/geo-location.php
CHANGED
@@ -1,3 +1,12 @@
|
|
1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
<hr />
|
3 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Geo Location Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
?>
|
10 |
+
<h2><?php esc_html_e('Geo Location Setup','gdpr-cookie-compliance'); ?></h2>
|
11 |
<hr />
|
12 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
views/moove/admin/settings/help.php
CHANGED
@@ -1,23 +1,33 @@
|
|
1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
<hr />
|
3 |
<ul class="gdpr-disable-posts-nav moove-clearfix">
|
4 |
<li></li>
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
</ul>
|
10 |
|
11 |
<div class="gdpr-help-content-cnt">
|
12 |
<div id="gdpr_cbm_faq" class="gdpr-help-content-block help-block-open">
|
13 |
<div class="gdpr-faq-toggle gdpr-faq-open">
|
14 |
<div class="gdpr-faq-accordion-header">
|
15 |
-
<h3
|
16 |
</div>
|
17 |
<div class="gdpr-faq-accordion-content">
|
18 |
-
<p
|
19 |
-
<p
|
20 |
-
<p
|
21 |
</div>
|
22 |
<!-- .gdpr-faq-accordion-content -->
|
23 |
</div>
|
@@ -25,16 +35,16 @@
|
|
25 |
|
26 |
<div class="gdpr-faq-toggle">
|
27 |
<div class="gdpr-faq-accordion-header">
|
28 |
-
<h3
|
29 |
</div>
|
30 |
<div class="gdpr-faq-accordion-content" >
|
31 |
-
<p
|
32 |
-
<p
|
33 |
<code>/#gdpr_cookie_modal</code>
|
34 |
|
35 |
-
<p
|
36 |
-
<code><?php echo home_url(); ?>/#gdpr_cookie_modal</code><br /><br />
|
37 |
-
<code><?php echo home_url(); ?>/your-internal-page/#gdpr_cookie_modal</code>
|
38 |
</div>
|
39 |
<!-- .gdpr-faq-accordion-content -->
|
40 |
</div>
|
@@ -42,10 +52,10 @@
|
|
42 |
|
43 |
<div class="gdpr-faq-toggle">
|
44 |
<div class="gdpr-faq-accordion-header">
|
45 |
-
<h3
|
46 |
</div>
|
47 |
<div class="gdpr-faq-accordion-content" >
|
48 |
-
<p
|
49 |
</div>
|
50 |
<!-- .gdpr-faq-accordion-content -->
|
51 |
</div>
|
@@ -53,10 +63,10 @@
|
|
53 |
|
54 |
<div class="gdpr-faq-toggle">
|
55 |
<div class="gdpr-faq-accordion-header">
|
56 |
-
<h3
|
57 |
</div>
|
58 |
<div class="gdpr-faq-accordion-content" >
|
59 |
-
<p
|
60 |
</div>
|
61 |
<!-- .gdpr-faq-accordion-content -->
|
62 |
</div>
|
@@ -64,10 +74,10 @@
|
|
64 |
|
65 |
<div class="gdpr-faq-toggle">
|
66 |
<div class="gdpr-faq-accordion-header">
|
67 |
-
<h3
|
68 |
</div>
|
69 |
<div class="gdpr-faq-accordion-content" >
|
70 |
-
<p
|
71 |
</div>
|
72 |
<!-- .gdpr-faq-accordion-content -->
|
73 |
</div>
|
@@ -75,10 +85,10 @@
|
|
75 |
|
76 |
<div class="gdpr-faq-toggle">
|
77 |
<div class="gdpr-faq-accordion-header">
|
78 |
-
<h3
|
79 |
</div>
|
80 |
<div class="gdpr-faq-accordion-content" >
|
81 |
-
<p
|
82 |
</div>
|
83 |
<!-- .gdpr-faq-accordion-content -->
|
84 |
</div>
|
@@ -86,21 +96,21 @@
|
|
86 |
|
87 |
<div class="gdpr-faq-toggle">
|
88 |
<div class="gdpr-faq-accordion-header">
|
89 |
-
<h3
|
90 |
</div>
|
91 |
<div class="gdpr-faq-accordion-content" >
|
92 |
-
<p
|
93 |
</div>
|
94 |
<!-- .gdpr-faq-accordion-content -->
|
95 |
</div>
|
96 |
<!-- .gdpr-faq-toggle -->
|
97 |
-
|
98 |
<div class="gdpr-faq-toggle">
|
99 |
<div class="gdpr-faq-accordion-header">
|
100 |
-
<h3
|
101 |
</div>
|
102 |
<div class="gdpr-faq-accordion-content" >
|
103 |
-
<p
|
104 |
</div>
|
105 |
<!-- .gdpr-faq-accordion-content -->
|
106 |
</div>
|
@@ -108,10 +118,10 @@
|
|
108 |
|
109 |
<div class="gdpr-faq-toggle">
|
110 |
<div class="gdpr-faq-accordion-header">
|
111 |
-
<h3
|
112 |
</div>
|
113 |
<div class="gdpr-faq-accordion-content" >
|
114 |
-
<p
|
115 |
</div>
|
116 |
<!-- .gdpr-faq-accordion-content -->
|
117 |
</div>
|
@@ -120,12 +130,12 @@
|
|
120 |
<!-- #gdpr_cbm_faq -->
|
121 |
|
122 |
<div id="gdpr_cbm_dh" class="gdpr-help-content-block">
|
123 |
-
<p
|
124 |
-
<p><strong
|
125 |
|
126 |
<div class="gdpr-faq-toggle gdpr-faq-open">
|
127 |
<div class="gdpr-faq-accordion-header">
|
128 |
-
<h3
|
129 |
</div>
|
130 |
<div class="gdpr-faq-accordion-content">
|
131 |
<?php ob_start(); ?>
|
@@ -135,11 +145,8 @@
|
|
135 |
return $scripts;
|
136 |
}
|
137 |
<?php $code = trim( ob_get_clean() ); ?>
|
138 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
139 |
-
<div class="gdpr-code"
|
140 |
-
|
141 |
-
</div>
|
142 |
-
<!-- .gdpr-code -->
|
143 |
</div>
|
144 |
<!-- .gdpr-faq-accordion-content -->
|
145 |
</div>
|
@@ -147,7 +154,7 @@
|
|
147 |
|
148 |
<div class="gdpr-faq-toggle">
|
149 |
<div class="gdpr-faq-accordion-header">
|
150 |
-
<h3
|
151 |
</div>
|
152 |
<div class="gdpr-faq-accordion-content" >
|
153 |
<?php ob_start(); ?>
|
@@ -157,11 +164,8 @@
|
|
157 |
return $scripts;
|
158 |
}
|
159 |
<?php $code = trim( ob_get_clean() ); ?>
|
160 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
161 |
-
<div class="gdpr-code"
|
162 |
-
|
163 |
-
</div>
|
164 |
-
<!-- .gdpr-code -->
|
165 |
</div>
|
166 |
<!-- .gdpr-faq-accordion-content -->
|
167 |
</div>
|
@@ -169,7 +173,7 @@
|
|
169 |
|
170 |
<div class="gdpr-faq-toggle">
|
171 |
<div class="gdpr-faq-accordion-header">
|
172 |
-
<h3
|
173 |
</div>
|
174 |
<div class="gdpr-faq-accordion-content" >
|
175 |
<?php ob_start(); ?>
|
@@ -179,11 +183,8 @@
|
|
179 |
return $scripts;
|
180 |
}
|
181 |
<?php $code = trim( ob_get_clean() ); ?>
|
182 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
183 |
-
<div class="gdpr-code"
|
184 |
-
|
185 |
-
</div>
|
186 |
-
<!-- .gdpr-code -->
|
187 |
</div>
|
188 |
<!-- .gdpr-faq-accordion-content -->
|
189 |
</div>
|
@@ -191,7 +192,7 @@
|
|
191 |
|
192 |
<div class="gdpr-faq-toggle">
|
193 |
<div class="gdpr-faq-accordion-header">
|
194 |
-
<h3
|
195 |
</div>
|
196 |
<div class="gdpr-faq-accordion-content" >
|
197 |
<?php ob_start(); ?>
|
@@ -201,11 +202,8 @@
|
|
201 |
return $scripts;
|
202 |
}
|
203 |
<?php $code = trim( ob_get_clean() ); ?>
|
204 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
205 |
-
<div class="gdpr-code"
|
206 |
-
|
207 |
-
</div>
|
208 |
-
<!-- .gdpr-code -->
|
209 |
</div>
|
210 |
<!-- .gdpr-faq-accordion-content -->
|
211 |
</div>
|
@@ -213,7 +211,7 @@
|
|
213 |
|
214 |
<div class="gdpr-faq-toggle">
|
215 |
<div class="gdpr-faq-accordion-header">
|
216 |
-
<h3
|
217 |
</div>
|
218 |
<div class="gdpr-faq-accordion-content" >
|
219 |
<?php ob_start(); ?>
|
@@ -223,11 +221,8 @@
|
|
223 |
return $scripts;
|
224 |
}
|
225 |
<?php $code = trim( ob_get_clean() ); ?>
|
226 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
227 |
-
<div class="gdpr-code"
|
228 |
-
|
229 |
-
</div>
|
230 |
-
<!-- .gdpr-code -->
|
231 |
</div>
|
232 |
<!-- .gdpr-faq-accordion-content -->
|
233 |
</div>
|
@@ -235,7 +230,7 @@
|
|
235 |
|
236 |
<div class="gdpr-faq-toggle">
|
237 |
<div class="gdpr-faq-accordion-header">
|
238 |
-
<h3
|
239 |
</div>
|
240 |
<div class="gdpr-faq-accordion-content" >
|
241 |
<?php ob_start(); ?>
|
@@ -245,11 +240,8 @@
|
|
245 |
return $scripts;
|
246 |
}
|
247 |
<?php $code = trim( ob_get_clean() ); ?>
|
248 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
249 |
-
<div class="gdpr-code"
|
250 |
-
|
251 |
-
</div>
|
252 |
-
<!-- .gdpr-code -->
|
253 |
</div>
|
254 |
<!-- .gdpr-faq-accordion-content -->
|
255 |
</div>
|
@@ -257,42 +249,35 @@
|
|
257 |
|
258 |
<div class="gdpr-faq-toggle">
|
259 |
<div class="gdpr-faq-accordion-header">
|
260 |
-
<h3
|
261 |
</div>
|
262 |
<div class="gdpr-faq-accordion-content" >
|
263 |
<?php ob_start(); ?>
|
264 |
add_action( 'gdpr_force_reload', '__return_true' );
|
265 |
<?php $code = trim( ob_get_clean() ); ?>
|
266 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
267 |
-
<div class="gdpr-code"
|
268 |
-
|
269 |
-
</div>
|
270 |
-
<!-- .gdpr-code -->
|
271 |
</div>
|
272 |
<!-- .gdpr-faq-accordion-content -->
|
273 |
</div>
|
274 |
<!-- .gdpr-faq-toggle -->
|
275 |
-
|
276 |
<div class="gdpr-faq-toggle">
|
277 |
<div class="gdpr-faq-accordion-header">
|
278 |
-
<h3
|
279 |
</div>
|
280 |
<div class="gdpr-faq-accordion-content" >
|
281 |
<?php ob_start(); ?>
|
282 |
if ( function_exists( 'gdpr_cookie_is_accepted' ) ) {
|
283 |
-
|
284 |
-
|
285 |
-
|
286 |
-
|
287 |
-
|
288 |
-
|
289 |
}
|
290 |
<?php $code = trim( ob_get_clean() ); ?>
|
291 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
292 |
-
<div class="gdpr-code"
|
293 |
-
|
294 |
-
</div>
|
295 |
-
<!-- .gdpr-code -->
|
296 |
</div>
|
297 |
<!-- .gdpr-faq-accordion-content -->
|
298 |
</div>
|
@@ -300,7 +285,7 @@
|
|
300 |
|
301 |
<div class="gdpr-faq-toggle">
|
302 |
<div class="gdpr-faq-accordion-header">
|
303 |
-
<h3
|
304 |
</div>
|
305 |
<div class="gdpr-faq-accordion-content" >
|
306 |
<?php ob_start(); ?>
|
@@ -312,11 +297,8 @@
|
|
312 |
return $styles;
|
313 |
}
|
314 |
<?php $code = trim( ob_get_clean() ); ?>
|
315 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
316 |
-
<div class="gdpr-code"
|
317 |
-
|
318 |
-
</div>
|
319 |
-
<!-- .gdpr-code -->
|
320 |
</div>
|
321 |
<!-- .gdpr-faq-accordion-content -->
|
322 |
</div>
|
@@ -324,26 +306,23 @@
|
|
324 |
|
325 |
<div class="gdpr-faq-toggle">
|
326 |
<div class="gdpr-faq-accordion-header">
|
327 |
-
<h3
|
328 |
</div>
|
329 |
<div class="gdpr-faq-accordion-content" >
|
330 |
<?php ob_start(); ?>
|
331 |
add_action( 'init', 'toggle_monster_insights_based_on_moove' );
|
332 |
function toggle_monster_insights_based_on_moove() {
|
333 |
-
|
334 |
-
|
335 |
-
|
336 |
-
|
337 |
-
|
|
|
338 |
}
|
339 |
-
}
|
340 |
}
|
341 |
<?php $code = trim( ob_get_clean() ); ?>
|
342 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
343 |
-
<div class="gdpr-code"
|
344 |
-
|
345 |
-
</div>
|
346 |
-
<!-- .gdpr-code -->
|
347 |
</div>
|
348 |
<!-- .gdpr-faq-accordion-content -->
|
349 |
</div>
|
@@ -351,7 +330,7 @@
|
|
351 |
|
352 |
<div class="gdpr-faq-toggle">
|
353 |
<div class="gdpr-faq-accordion-header">
|
354 |
-
<h3
|
355 |
</div>
|
356 |
<div class="gdpr-faq-accordion-content" >
|
357 |
<?php ob_start(); ?>
|
@@ -361,11 +340,8 @@
|
|
361 |
return str_replace( trailingslashit( site_url() ) , trailingslashit( $cdn_url ), $plugin_url );
|
362 |
}
|
363 |
<?php $code = trim( ob_get_clean() ); ?>
|
364 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
365 |
-
<div class="gdpr-code"
|
366 |
-
|
367 |
-
</div>
|
368 |
-
<!-- .gdpr-code -->
|
369 |
</div>
|
370 |
<!-- .gdpr-faq-accordion-content -->
|
371 |
</div>
|
@@ -373,28 +349,24 @@
|
|
373 |
|
374 |
<div class="gdpr-faq-toggle">
|
375 |
<div class="gdpr-faq-accordion-header">
|
376 |
-
<h3
|
377 |
</div>
|
378 |
<div class="gdpr-faq-accordion-content" >
|
379 |
<?php ob_start(); ?>
|
380 |
add_action( 'wp_footer', 'gdpr_js_extension', 1000 );
|
381 |
function gdpr_js_extension() {
|
382 |
-
|
383 |
-
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
</script>
|
391 |
}
|
392 |
<?php $code = trim( ob_get_clean() ); ?>
|
393 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
394 |
-
<div class="gdpr-code"
|
395 |
-
|
396 |
-
</div>
|
397 |
-
<!-- .gdpr-code -->
|
398 |
</div>
|
399 |
<!-- .gdpr-faq-accordion-content -->
|
400 |
</div>
|
@@ -402,29 +374,22 @@
|
|
402 |
|
403 |
<div class="gdpr-faq-toggle">
|
404 |
<div class="gdpr-faq-accordion-header">
|
405 |
-
<h3
|
406 |
</div>
|
407 |
<div class="gdpr-faq-accordion-content" >
|
408 |
<?php ob_start(); ?>
|
409 |
add_filter( 'pys_disable_by_gdpr', 'gdpr_cookie_compliance_pys' );
|
410 |
function gdpr_cookie_compliance_pys() {
|
411 |
-
|
412 |
if ( function_exists( 'gdpr_cookie_is_accepted' ) ) :
|
413 |
-
|
414 |
$disable_pys = gdpr_cookie_is_accepted( 'thirdparty' ) ? false : true;
|
415 |
return $disable_pys;
|
416 |
endif;
|
417 |
-
|
418 |
return true;
|
419 |
}
|
420 |
-
|
421 |
add_action( 'gdpr_force_reload', '__return_true' );
|
422 |
<?php $code = trim( ob_get_clean() ); ?>
|
423 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
424 |
-
<div class="gdpr-code"
|
425 |
-
|
426 |
-
</div>
|
427 |
-
<!-- .gdpr-code -->
|
428 |
</div>
|
429 |
<!-- .gdpr-faq-accordion-content -->
|
430 |
</div>
|
@@ -432,7 +397,7 @@
|
|
432 |
|
433 |
<div class="gdpr-faq-toggle">
|
434 |
<div class="gdpr-faq-accordion-header">
|
435 |
-
<h3
|
436 |
</div>
|
437 |
<div class="gdpr-faq-accordion-content" >
|
438 |
<?php ob_start(); ?>
|
@@ -446,11 +411,8 @@
|
|
446 |
}
|
447 |
add_action( 'gdpr_force_reload', '__return_true' );
|
448 |
<?php $code = trim( ob_get_clean() ); ?>
|
449 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
450 |
-
<div class="gdpr-code"
|
451 |
-
|
452 |
-
</div>
|
453 |
-
<!-- .gdpr-code -->
|
454 |
</div>
|
455 |
<!-- .gdpr-faq-accordion-content -->
|
456 |
</div>
|
@@ -458,7 +420,7 @@
|
|
458 |
|
459 |
<div class="gdpr-faq-toggle">
|
460 |
<div class="gdpr-faq-accordion-header">
|
461 |
-
<h3
|
462 |
</div>
|
463 |
<div class="gdpr-faq-accordion-content" >
|
464 |
<?php ob_start(); ?>
|
@@ -467,11 +429,8 @@
|
|
467 |
return array();
|
468 |
}
|
469 |
<?php $code = trim( ob_get_clean() ); ?>
|
470 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
471 |
-
<div class="gdpr-code"
|
472 |
-
|
473 |
-
</div>
|
474 |
-
<!-- .gdpr-code -->
|
475 |
</div>
|
476 |
<!-- .gdpr-faq-accordion-content -->
|
477 |
</div>
|
@@ -479,14 +438,14 @@
|
|
479 |
|
480 |
<div class="gdpr-faq-toggle">
|
481 |
<div class="gdpr-faq-accordion-header">
|
482 |
-
<h3
|
483 |
</div>
|
484 |
<div class="gdpr-faq-accordion-content" >
|
485 |
<?php ob_start(); ?>
|
486 |
// The SCRIPT caching should be disabled if you have separate scripts / site!
|
487 |
add_filter('gdpr_cookie_script_cache','gdpr_prevent_script_cache');
|
488 |
function gdpr_prevent_script_cache() {
|
489 |
-
|
490 |
}
|
491 |
// Force reload required because of PHP functions
|
492 |
add_action( 'gdpr_force_reload', '__return_true' );
|
@@ -497,7 +456,7 @@
|
|
497 |
// PHP Cookie checker, replace the 'thirdparty' to 'advanced' if you need to load the scripts for "Advanced cookies"
|
498 |
if ( function_exists( 'gdpr_cookie_is_accepted' ) && gdpr_cookie_is_accepted( 'thirdparty' ) ) :
|
499 |
$gdpr_default_content = new Moove_GDPR_Content();
|
500 |
-
|
501 |
// Variable named $wpml_lang returns the localization string
|
502 |
if ( $wpml_lang === 'fr' ) :
|
503 |
// Custom Script to FR site only
|
@@ -506,14 +465,11 @@
|
|
506 |
// Custom Script to EN site only
|
507 |
echo "<script>console.log('English - Custom Script Added');</script>";
|
508 |
endif;
|
509 |
-
|
510 |
}
|
511 |
<?php $code = trim( ob_get_clean() ); ?>
|
512 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
513 |
-
<div class="gdpr-code"
|
514 |
-
|
515 |
-
</div>
|
516 |
-
<!-- .gdpr-code -->
|
517 |
</div>
|
518 |
<!-- .gdpr-faq-accordion-content -->
|
519 |
</div>
|
@@ -521,19 +477,17 @@
|
|
521 |
|
522 |
<div class="gdpr-faq-toggle">
|
523 |
<div class="gdpr-faq-accordion-header">
|
524 |
-
<h3
|
525 |
</div>
|
526 |
<div class="gdpr-faq-accordion-content" >
|
527 |
-
<p><strong
|
|
|
528 |
<hr />
|
529 |
<?php ob_start(); ?>
|
530 |
add_action( 'gdpr_enqueue_lity_nojs', '__return_false' );
|
531 |
<?php $code = trim( ob_get_clean() ); ?>
|
532 |
-
<textarea id="<?php echo uniqid( strtotime('now') ); ?>"><?php
|
533 |
-
<div class="gdpr-code"
|
534 |
-
|
535 |
-
</div>
|
536 |
-
<!-- .gdpr-code -->
|
537 |
</div>
|
538 |
<!-- .gdpr-faq-accordion-content -->
|
539 |
</div>
|
@@ -543,12 +497,12 @@
|
|
543 |
<!-- #gdpr_cbm_faq -->
|
544 |
|
545 |
<div id="gdpr_cbm_ph" class="gdpr-help-content-block">
|
546 |
-
<?php do_action('gdpr_tab_cbm_ph'); ?>
|
547 |
</div>
|
548 |
<!-- #gdpr_cbm_ph -->
|
549 |
|
550 |
<div id="gdpr_cbm_ps" class="gdpr-help-content-block">
|
551 |
-
<?php do_action('gdpr_tab_cbm_ps'); ?>
|
552 |
</div>
|
553 |
<!-- #gdpr_cbm_ph -->
|
554 |
|
@@ -557,87 +511,87 @@
|
|
557 |
|
558 |
|
559 |
|
560 |
-
<script type="text/javascript" src="<?php echo moove_gdpr_get_plugin_directory_url(); ?>/dist/scripts/codemirror.js"></script>
|
561 |
<script type="text/javascript">
|
562 |
-
|
563 |
-
|
564 |
-
|
565 |
-
|
566 |
-
|
567 |
-
|
568 |
-
|
569 |
-
|
570 |
-
|
571 |
-
|
572 |
-
|
573 |
-
|
574 |
-
|
575 |
-
|
576 |
-
|
577 |
-
|
578 |
-
|
579 |
-
|
580 |
-
|
581 |
-
|
582 |
-
|
583 |
-
|
584 |
-
|
585 |
-
|
586 |
-
|
587 |
-
|
588 |
-
|
589 |
-
|
590 |
-
|
591 |
-
|
592 |
-
|
593 |
-
|
594 |
-
|
595 |
-
|
596 |
-
|
597 |
-
|
598 |
-
|
599 |
});
|
600 |
|
601 |
// Applies automatic mode-aware indentation to the specified range
|
602 |
CodeMirror.defineExtension("autoIndentRange", function (from, to) {
|
603 |
-
|
604 |
-
|
605 |
-
|
606 |
-
|
607 |
-
|
608 |
-
|
609 |
});
|
610 |
function GDPR_CodeMirror() {
|
611 |
jQuery('.gdpr-faq-accordion-content textarea').each(function(){
|
612 |
-
|
613 |
-
|
614 |
-
|
615 |
-
|
616 |
-
|
617 |
-
|
618 |
-
|
619 |
-
|
620 |
-
|
621 |
-
|
622 |
-
|
623 |
-
|
624 |
-
|
625 |
-
|
626 |
-
|
627 |
editor.autoFormatRange({line:0, ch:0}, {line:totalLines});
|
628 |
-
|
629 |
}
|
630 |
jQuery(document).ready(function(){
|
631 |
GDPR_CodeMirror();
|
|
|
632 |
jQuery('.gdpr-faq-toggle:not(.gdpr-faq-open)').find('.gdpr-faq-accordion-content').hide();
|
633 |
jQuery('.gdpr-help-content-block:not(.help-block-open)').hide();
|
634 |
});
|
635 |
-
|
636 |
-
|
637 |
</script>
|
638 |
<style>
|
639 |
.CodeMirror {
|
640 |
height: auto;
|
641 |
border: none !important;
|
642 |
}
|
643 |
-
</style>
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Help Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
?>
|
11 |
+
<h2><?php esc_html_e( 'Help, Hooks, Filters & Shortcodes', 'gdpr-cookie-compliance' ); ?></h2>
|
12 |
<hr />
|
13 |
<ul class="gdpr-disable-posts-nav moove-clearfix">
|
14 |
<li></li>
|
15 |
+
<li><a href="#gdpr_cbm_faq" class="gdpr-help-tab-toggle active"><?php esc_html_e( 'FAQ', 'gdpr-cookie-compliance' ); ?></a></li>
|
16 |
+
<li><a href="#gdpr_cbm_dh" class="gdpr-help-tab-toggle"><?php esc_html_e( 'Default Hooks', 'gdpr-cookie-compliance' ); ?></a></li>
|
17 |
+
<li><a href="#gdpr_cbm_ph" class="gdpr-help-tab-toggle"><?php esc_html_e( 'Premium Hooks', 'gdpr-cookie-compliance' ); ?></a></li>
|
18 |
+
<li><a href="#gdpr_cbm_ps" class="gdpr-help-tab-toggle"><?php esc_html_e( 'Premium Shortcodes', 'gdpr-cookie-compliance' ); ?></a></li>
|
19 |
</ul>
|
20 |
|
21 |
<div class="gdpr-help-content-cnt">
|
22 |
<div id="gdpr_cbm_faq" class="gdpr-help-content-block help-block-open">
|
23 |
<div class="gdpr-faq-toggle gdpr-faq-open">
|
24 |
<div class="gdpr-faq-accordion-header">
|
25 |
+
<h3><?php esc_html_e( 'How do I setup your plugin?', 'gdpr-cookie-compliance' ); ?></h3>
|
26 |
</div>
|
27 |
<div class="gdpr-faq-accordion-content">
|
28 |
+
<p><?php esc_html_e( 'You can setup the plugin in the WordPress CMS -> GDPR Cookie Compliance. You can setup the branding, and other elements.', 'gdpr-cookie-compliance' ); ?></p>
|
29 |
+
<p><?php esc_html_e( 'To add Google Analytics, you can enable the “3rd Party Cookies” tab but selecting the “Turn” radio value to “ON”. At the bottom of the “3rd Party Cookies” tab you’ll find 3 sections to add scripts – choose the section that is appropriate for your script.', 'gdpr-cookie-compliance' ); ?></p>
|
30 |
+
<p><?php esc_html_e( 'For Google Analytics, we recommend using the ‘Footer’ section.', 'gdpr-cookie-compliance' ); ?></p>
|
31 |
</div>
|
32 |
<!-- .gdpr-faq-accordion-content -->
|
33 |
</div>
|
35 |
|
36 |
<div class="gdpr-faq-toggle">
|
37 |
<div class="gdpr-faq-accordion-header">
|
38 |
+
<h3><?php esc_html_e( 'How can I link to the pop-up settings screen?', 'gdpr-cookie-compliance' ); ?></h3>
|
39 |
</div>
|
40 |
<div class="gdpr-faq-accordion-content" >
|
41 |
+
<p><?php esc_html_e( 'You can use the following link to display the modal window:', 'gdpr-cookie-compliance' ); ?></p>
|
42 |
+
<p><?php esc_html_e( '[Relative Path – RECOMMENDED]', 'gdpr-cookie-compliance' ); ?></p>
|
43 |
<code>/#gdpr_cookie_modal</code>
|
44 |
|
45 |
+
<p><?php esc_html_e( '[Absolute Path]', 'gdpr-cookie-compliance' ); ?></p>
|
46 |
+
<code><?php echo esc_url( home_url() ); ?>/#gdpr_cookie_modal</code><br /><br />
|
47 |
+
<code><?php echo esc_url( home_url() ); ?>/your-internal-page/#gdpr_cookie_modal</code>
|
48 |
</div>
|
49 |
<!-- .gdpr-faq-accordion-content -->
|
50 |
</div>
|
52 |
|
53 |
<div class="gdpr-faq-toggle">
|
54 |
<div class="gdpr-faq-accordion-header">
|
55 |
+
<h3><?php esc_html_e( 'Pasted code is not visible when view-source page is viewed.', 'gdpr-cookie-compliance' ); ?></h3>
|
56 |
</div>
|
57 |
<div class="gdpr-faq-accordion-content" >
|
58 |
+
<p><?php esc_html_e( 'Our plugin loads the script with JavaScript, and that’s why you can’t find it in the view-source page. You can use the developer console in Chrome browser (Inspect Element feature) and find the scripts.', 'gdpr-cookie-compliance' ); ?></p>
|
59 |
</div>
|
60 |
<!-- .gdpr-faq-accordion-content -->
|
61 |
</div>
|
63 |
|
64 |
<div class="gdpr-faq-toggle">
|
65 |
<div class="gdpr-faq-accordion-header">
|
66 |
+
<h3><?php esc_html_e( 'Can I use custom code or hooks with your plugin?', 'gdpr-cookie-compliance' ); ?></h3>
|
67 |
</div>
|
68 |
<div class="gdpr-faq-accordion-content" >
|
69 |
+
<p><?php esc_html_e( 'Yes. We have implemented hooks that allow you to implement custom scripts, for some examples see the list of pre-defined hooks here:', 'gdpr-cookie-compliance' ); ?> <a href="#gdpr_cbm_dh" class="gdpr-help-tab-toggle"><?php esc_html_e( 'Default Hooks', 'gdpr-cookie-compliance' ); ?></a></p>
|
70 |
</div>
|
71 |
<!-- .gdpr-faq-accordion-content -->
|
72 |
</div>
|
74 |
|
75 |
<div class="gdpr-faq-toggle">
|
76 |
<div class="gdpr-faq-accordion-header">
|
77 |
+
<h3><?php esc_html_e( 'Does the plugin support sub domains?', 'gdpr-cookie-compliance' ); ?></h3>
|
78 |
</div>
|
79 |
<div class="gdpr-faq-accordion-content" >
|
80 |
+
<p><?php esc_html_e( 'Unfortunately not, sub domains are treated as separate domains by browsers and we’re unable to change the cookies stored by another domain. If your multi site setup use sub domain version, each sub site will be recognised as a separate domain by the browser and will create cookies for each sub domain.', 'gdpr-cookie-compliance' ); ?></p>
|
81 |
</div>
|
82 |
<!-- .gdpr-faq-accordion-content -->
|
83 |
</div>
|
85 |
|
86 |
<div class="gdpr-faq-toggle">
|
87 |
<div class="gdpr-faq-accordion-header">
|
88 |
+
<h3><?php esc_html_e( 'Does this plugin block all cookies?', 'gdpr-cookie-compliance' ); ?></h3>
|
89 |
</div>
|
90 |
<div class="gdpr-faq-accordion-content" >
|
91 |
+
<p><?php esc_html_e( 'No. This plugin only restricts cookies for scripts that you have setup in the Settings. If you want to block all cookies, you have to add all scripts that use cookies into the Settings of this plugin.', 'gdpr-cookie-compliance' ); ?></p>
|
92 |
</div>
|
93 |
<!-- .gdpr-faq-accordion-content -->
|
94 |
</div>
|
96 |
|
97 |
<div class="gdpr-faq-toggle">
|
98 |
<div class="gdpr-faq-accordion-header">
|
99 |
+
<h3><?php esc_html_e( 'Once I add scripts to this plugin, should I delete them from the website’s code?', 'gdpr-cookie-compliance' ); ?></h3>
|
100 |
</div>
|
101 |
<div class="gdpr-faq-accordion-content" >
|
102 |
+
<p><?php esc_html_e( 'Yes. Once you setup the plugin, you should delete the scripts you uploaded to the plugin from your website’s code to ensure that your scripts are not loaded twice.', 'gdpr-cookie-compliance' ); ?></p>
|
103 |
</div>
|
104 |
<!-- .gdpr-faq-accordion-content -->
|
105 |
</div>
|
106 |
<!-- .gdpr-faq-toggle -->
|
107 |
+
|
108 |
<div class="gdpr-faq-toggle">
|
109 |
<div class="gdpr-faq-accordion-header">
|
110 |
+
<h3><?php esc_html_e( 'Does this plugin stop all cookies from being stored?', 'gdpr-cookie-compliance' ); ?></h3>
|
111 |
</div>
|
112 |
<div class="gdpr-faq-accordion-content" >
|
113 |
+
<p><?php esc_html_e( 'This plugin is just a template and needs to be setup by your developer in order to work properly. Once setup fully, it will prevent scripts that store cookies from being loaded on users computers until consent is given.', 'gdpr-cookie-compliance' ); ?></p>
|
114 |
</div>
|
115 |
<!-- .gdpr-faq-accordion-content -->
|
116 |
</div>
|
118 |
|
119 |
<div class="gdpr-faq-toggle">
|
120 |
<div class="gdpr-faq-accordion-header">
|
121 |
+
<h3><?php esc_html_e( 'Does this plugin guarantee that I will comply with GDPR law?', 'gdpr-cookie-compliance' ); ?></h3>
|
122 |
</div>
|
123 |
<div class="gdpr-faq-accordion-content" >
|
124 |
+
<p><?php esc_html_e( 'Unfortunately no. This plugin is just a template and needs to be setup by your developer in order to work properly.', 'gdpr-cookie-compliance' ); ?></p>
|
125 |
</div>
|
126 |
<!-- .gdpr-faq-accordion-content -->
|
127 |
</div>
|
130 |
<!-- #gdpr_cbm_faq -->
|
131 |
|
132 |
<div id="gdpr_cbm_dh" class="gdpr-help-content-block">
|
133 |
+
<p><?php esc_html_e( 'Below the hooks & custom scripts included in the GDPR Cookie Compliance plugin.', 'gdpr-cookie-compliance' ); ?></p>
|
134 |
+
<p><strong><?php esc_html_e( 'Note: Some of them require some development work on your end to be extended or modified properly! These are just examples.' ); ?></strong></p>
|
135 |
|
136 |
<div class="gdpr-faq-toggle gdpr-faq-open">
|
137 |
<div class="gdpr-faq-accordion-header">
|
138 |
+
<h3><?php esc_html_e( 'HOOK to GDPR custom 3RD-PARTY script by php – HEAD', 'gdpr-cookie-compliance' ); ?></h3>
|
139 |
</div>
|
140 |
<div class="gdpr-faq-accordion-content">
|
141 |
<?php ob_start(); ?>
|
145 |
return $scripts;
|
146 |
}
|
147 |
<?php $code = trim( ob_get_clean() ); ?>
|
148 |
+
<textarea id="<?php echo esc_attr( esc_attr( uniqid( strtotime( 'now' ) ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
149 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
150 |
</div>
|
151 |
<!-- .gdpr-faq-accordion-content -->
|
152 |
</div>
|
154 |
|
155 |
<div class="gdpr-faq-toggle">
|
156 |
<div class="gdpr-faq-accordion-header">
|
157 |
+
<h3><?php esc_html_e( 'HOOK to GDPR custom 3RD-PARTY script by php – BODY', 'gdpr-cookie-compliance' ); ?></h3>
|
158 |
</div>
|
159 |
<div class="gdpr-faq-accordion-content" >
|
160 |
<?php ob_start(); ?>
|
164 |
return $scripts;
|
165 |
}
|
166 |
<?php $code = trim( ob_get_clean() ); ?>
|
167 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
168 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
169 |
</div>
|
170 |
<!-- .gdpr-faq-accordion-content -->
|
171 |
</div>
|
173 |
|
174 |
<div class="gdpr-faq-toggle">
|
175 |
<div class="gdpr-faq-accordion-header">
|
176 |
+
<h3><?php esc_html_e( 'HOOK to GDPR custom 3RD-PARTY script by php – FOOTER', 'gdpr-cookie-compliance' ); ?></h3>
|
177 |
</div>
|
178 |
<div class="gdpr-faq-accordion-content" >
|
179 |
<?php ob_start(); ?>
|
183 |
return $scripts;
|
184 |
}
|
185 |
<?php $code = trim( ob_get_clean() ); ?>
|
186 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
187 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
188 |
</div>
|
189 |
<!-- .gdpr-faq-accordion-content -->
|
190 |
</div>
|
192 |
|
193 |
<div class="gdpr-faq-toggle">
|
194 |
<div class="gdpr-faq-accordion-header">
|
195 |
+
<h3><?php esc_html_e( 'HOOK to GDPR custom ADVANCED-PARTY script by php – HEAD', 'gdpr-cookie-compliance' ); ?></h3>
|
196 |
</div>
|
197 |
<div class="gdpr-faq-accordion-content" >
|
198 |
<?php ob_start(); ?>
|
202 |
return $scripts;
|
203 |
}
|
204 |
<?php $code = trim( ob_get_clean() ); ?>
|
205 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
206 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
207 |
</div>
|
208 |
<!-- .gdpr-faq-accordion-content -->
|
209 |
</div>
|
211 |
|
212 |
<div class="gdpr-faq-toggle">
|
213 |
<div class="gdpr-faq-accordion-header">
|
214 |
+
<h3><?php esc_html_e( 'HOOK to GDPR custom ADVANCED-PARTY script by php – BODY', 'gdpr-cookie-compliance' ); ?></h3>
|
215 |
</div>
|
216 |
<div class="gdpr-faq-accordion-content" >
|
217 |
<?php ob_start(); ?>
|
221 |
return $scripts;
|
222 |
}
|
223 |
<?php $code = trim( ob_get_clean() ); ?>
|
224 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
225 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
226 |
</div>
|
227 |
<!-- .gdpr-faq-accordion-content -->
|
228 |
</div>
|
230 |
|
231 |
<div class="gdpr-faq-toggle">
|
232 |
<div class="gdpr-faq-accordion-header">
|
233 |
+
<h3><?php esc_html_e( 'HOOK to GDPR custom ADVANCED-PARTY script by php – FOOTER', 'gdpr-cookie-compliance' ); ?></h3>
|
234 |
</div>
|
235 |
<div class="gdpr-faq-accordion-content" >
|
236 |
<?php ob_start(); ?>
|
240 |
return $scripts;
|
241 |
}
|
242 |
<?php $code = trim( ob_get_clean() ); ?>
|
243 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
244 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
245 |
</div>
|
246 |
<!-- .gdpr-faq-accordion-content -->
|
247 |
</div>
|
249 |
|
250 |
<div class="gdpr-faq-toggle">
|
251 |
<div class="gdpr-faq-accordion-header">
|
252 |
+
<h3><?php esc_html_e( 'Enable Force Reload', 'gdpr-cookie-compliance' ); ?></h3>
|
253 |
</div>
|
254 |
<div class="gdpr-faq-accordion-content" >
|
255 |
<?php ob_start(); ?>
|
256 |
add_action( 'gdpr_force_reload', '__return_true' );
|
257 |
<?php $code = trim( ob_get_clean() ); ?>
|
258 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
259 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
260 |
</div>
|
261 |
<!-- .gdpr-faq-accordion-content -->
|
262 |
</div>
|
263 |
<!-- .gdpr-faq-toggle -->
|
|
|
264 |
<div class="gdpr-faq-toggle">
|
265 |
<div class="gdpr-faq-accordion-header">
|
266 |
+
<h3><?php esc_html_e( 'PHP Cookie checker', 'gdpr-cookie-compliance' ); ?></h3>
|
267 |
</div>
|
268 |
<div class="gdpr-faq-accordion-content" >
|
269 |
<?php ob_start(); ?>
|
270 |
if ( function_exists( 'gdpr_cookie_is_accepted' ) ) {
|
271 |
+
/* supported types: 'strict', 'thirdparty', 'advanced' */
|
272 |
+
if ( gdpr_cookie_is_accepted( 'thirdparty' ) ) {
|
273 |
+
echo "GDPR third party ENABLED content";
|
274 |
+
} else {
|
275 |
+
echo "GDPR third party RESTRICTED content";
|
276 |
+
}
|
277 |
}
|
278 |
<?php $code = trim( ob_get_clean() ); ?>
|
279 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
280 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
281 |
</div>
|
282 |
<!-- .gdpr-faq-accordion-content -->
|
283 |
</div>
|
285 |
|
286 |
<div class="gdpr-faq-toggle">
|
287 |
<div class="gdpr-faq-accordion-header">
|
288 |
+
<h3><?php esc_html_e( 'Extend Styles', 'gdpr-cookie-compliance' ); ?></h3>
|
289 |
</div>
|
290 |
<div class="gdpr-faq-accordion-content" >
|
291 |
<?php ob_start(); ?>
|
297 |
return $styles;
|
298 |
}
|
299 |
<?php $code = trim( ob_get_clean() ); ?>
|
300 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
301 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
302 |
</div>
|
303 |
<!-- .gdpr-faq-accordion-content -->
|
304 |
</div>
|
306 |
|
307 |
<div class="gdpr-faq-toggle">
|
308 |
<div class="gdpr-faq-accordion-header">
|
309 |
+
<h3><?php esc_html_e( 'Disable Monster Insights based on cookie selected', 'gdpr-cookie-compliance' ); ?></h3>
|
310 |
</div>
|
311 |
<div class="gdpr-faq-accordion-content" >
|
312 |
<?php ob_start(); ?>
|
313 |
add_action( 'init', 'toggle_monster_insights_based_on_moove' );
|
314 |
function toggle_monster_insights_based_on_moove() {
|
315 |
+
if ( function_exists( gdpr_cookie_is_accepted ) && function_exists('monsterinsights_get_ua')) {
|
316 |
+
if ( gdpr_cookie_is_accepted('thirdparty') ) {
|
317 |
+
setCookie( 'ga-disable-'.monsterinsights_get_ua(), 'false' );
|
318 |
+
} else {
|
319 |
+
setCookie( 'ga-disable-'.monsterinsights_get_ua(), 'true' );
|
320 |
+
}
|
321 |
}
|
|
|
322 |
}
|
323 |
<?php $code = trim( ob_get_clean() ); ?>
|
324 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
325 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
326 |
</div>
|
327 |
<!-- .gdpr-faq-accordion-content -->
|
328 |
</div>
|
330 |
|
331 |
<div class="gdpr-faq-toggle">
|
332 |
<div class="gdpr-faq-accordion-header">
|
333 |
+
<h3><?php esc_html_e( 'Define CDN URL for Lity library', 'gdpr-cookie-compliance' ); ?></h3>
|
334 |
</div>
|
335 |
<div class="gdpr-faq-accordion-content" >
|
336 |
<?php ob_start(); ?>
|
340 |
return str_replace( trailingslashit( site_url() ) , trailingslashit( $cdn_url ), $plugin_url );
|
341 |
}
|
342 |
<?php $code = trim( ob_get_clean() ); ?>
|
343 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
344 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
345 |
</div>
|
346 |
<!-- .gdpr-faq-accordion-content -->
|
347 |
</div>
|
349 |
|
350 |
<div class="gdpr-faq-toggle">
|
351 |
<div class="gdpr-faq-accordion-header">
|
352 |
+
<h3><?php esc_html_e( 'Read cookie values with JavaScript', 'gdpr-cookie-compliance' ); ?></h3>
|
353 |
</div>
|
354 |
<div class="gdpr-faq-accordion-content" >
|
355 |
<?php ob_start(); ?>
|
356 |
add_action( 'wp_footer', 'gdpr_js_extension', 1000 );
|
357 |
function gdpr_js_extension() {
|
358 |
+
<script>
|
359 |
+
jQuery(document).ready(function(){
|
360 |
+
var cookies_object = jQuery(this).moove_gdpr_read_cookies();
|
361 |
+
if ( typeof cookies_object === 'object' ) {
|
362 |
+
console.log(cookies_object);
|
363 |
+
}
|
364 |
+
});
|
365 |
+
</script>
|
|
|
366 |
}
|
367 |
<?php $code = trim( ob_get_clean() ); ?>
|
368 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
369 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
370 |
</div>
|
371 |
<!-- .gdpr-faq-accordion-content -->
|
372 |
</div>
|
374 |
|
375 |
<div class="gdpr-faq-toggle">
|
376 |
<div class="gdpr-faq-accordion-header">
|
377 |
+
<h3><?php esc_html_e( 'Compatibility with Pixel Your Site plugin', 'gdpr-cookie-compliance' ); ?></h3>
|
378 |
</div>
|
379 |
<div class="gdpr-faq-accordion-content" >
|
380 |
<?php ob_start(); ?>
|
381 |
add_filter( 'pys_disable_by_gdpr', 'gdpr_cookie_compliance_pys' );
|
382 |
function gdpr_cookie_compliance_pys() {
|
|
|
383 |
if ( function_exists( 'gdpr_cookie_is_accepted' ) ) :
|
|
|
384 |
$disable_pys = gdpr_cookie_is_accepted( 'thirdparty' ) ? false : true;
|
385 |
return $disable_pys;
|
386 |
endif;
|
|
|
387 |
return true;
|
388 |
}
|
|
|
389 |
add_action( 'gdpr_force_reload', '__return_true' );
|
390 |
<?php $code = trim( ob_get_clean() ); ?>
|
391 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
392 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
393 |
</div>
|
394 |
<!-- .gdpr-faq-accordion-content -->
|
395 |
</div>
|
397 |
|
398 |
<div class="gdpr-faq-toggle">
|
399 |
<div class="gdpr-faq-accordion-header">
|
400 |
+
<h3><?php esc_html_e( 'Hook for WooCommerce Facebook Pixel plugin', 'gdpr-cookie-compliance' ); ?></h3>
|
401 |
</div>
|
402 |
<div class="gdpr-faq-accordion-content" >
|
403 |
<?php ob_start(); ?>
|
411 |
}
|
412 |
add_action( 'gdpr_force_reload', '__return_true' );
|
413 |
<?php $code = trim( ob_get_clean() ); ?>
|
414 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
415 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
416 |
</div>
|
417 |
<!-- .gdpr-faq-accordion-content -->
|
418 |
</div>
|
420 |
|
421 |
<div class="gdpr-faq-toggle">
|
422 |
<div class="gdpr-faq-accordion-header">
|
423 |
+
<h3><?php esc_html_e( 'Disable Script Caching', 'gdpr-cookie-compliance' ); ?></h3>
|
424 |
</div>
|
425 |
<div class="gdpr-faq-accordion-content" >
|
426 |
<?php ob_start(); ?>
|
429 |
return array();
|
430 |
}
|
431 |
<?php $code = trim( ob_get_clean() ); ?>
|
432 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
433 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
434 |
</div>
|
435 |
<!-- .gdpr-faq-accordion-content -->
|
436 |
</div>
|
438 |
|
439 |
<div class="gdpr-faq-toggle">
|
440 |
<div class="gdpr-faq-accordion-header">
|
441 |
+
<h3><?php esc_html_e( 'Custom Tracking Code on language sites (WPML, qTranslate, WP Multilang, Polylang)', 'gdpr-cookie-compliance' ); ?></h3>
|
442 |
</div>
|
443 |
<div class="gdpr-faq-accordion-content" >
|
444 |
<?php ob_start(); ?>
|
445 |
// The SCRIPT caching should be disabled if you have separate scripts / site!
|
446 |
add_filter('gdpr_cookie_script_cache','gdpr_prevent_script_cache');
|
447 |
function gdpr_prevent_script_cache() {
|
448 |
+
return array();
|
449 |
}
|
450 |
// Force reload required because of PHP functions
|
451 |
add_action( 'gdpr_force_reload', '__return_true' );
|
456 |
// PHP Cookie checker, replace the 'thirdparty' to 'advanced' if you need to load the scripts for "Advanced cookies"
|
457 |
if ( function_exists( 'gdpr_cookie_is_accepted' ) && gdpr_cookie_is_accepted( 'thirdparty' ) ) :
|
458 |
$gdpr_default_content = new Moove_GDPR_Content();
|
459 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
460 |
// Variable named $wpml_lang returns the localization string
|
461 |
if ( $wpml_lang === 'fr' ) :
|
462 |
// Custom Script to FR site only
|
465 |
// Custom Script to EN site only
|
466 |
echo "<script>console.log('English - Custom Script Added');</script>";
|
467 |
endif;
|
468 |
+
endif;
|
469 |
}
|
470 |
<?php $code = trim( ob_get_clean() ); ?>
|
471 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
472 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
473 |
</div>
|
474 |
<!-- .gdpr-faq-accordion-content -->
|
475 |
</div>
|
477 |
|
478 |
<div class="gdpr-faq-toggle">
|
479 |
<div class="gdpr-faq-accordion-header">
|
480 |
+
<h3><?php esc_html_e( 'Prevent loading Lity Lightbox by JavaScript', 'gdpr-cookie-compliance' ); ?></h3>
|
481 |
</div>
|
482 |
<div class="gdpr-faq-accordion-content" >
|
483 |
+
<p><strong><?php esc_html_e( 'Note', 'gdpr-cookie-compliance' ); ?>:</strong> <?php esc_html_e( 'By default our plugin first checks (using JavaScript) if the Lity lightbox is defined and used by your theme or any of the active plugins. If the lightbox is not loaded our plugin will load the lightbox from the plugin folder by JavaScript.', 'gdpr-cookie-compliance' ); ?></p>
|
484 |
+
<p><?php esc_html_e( 'You can use the following filter to prevent this JavaScript checking feature and enqueue the lightbox assets using PHP.', 'gdpr-cookie-compliance' ); ?> </p>
|
485 |
<hr />
|
486 |
<?php ob_start(); ?>
|
487 |
add_action( 'gdpr_enqueue_lity_nojs', '__return_false' );
|
488 |
<?php $code = trim( ob_get_clean() ); ?>
|
489 |
+
<textarea id="<?php echo esc_attr( uniqid( strtotime( 'now' ) ) ); ?>"><?php apply_filters( 'gdpr_cc_keephtml', $code, true ); ?></textarea>
|
490 |
+
<div class="gdpr-code"></div><!-- .gdpr-code -->
|
|
|
|
|
|
|
491 |
</div>
|
492 |
<!-- .gdpr-faq-accordion-content -->
|
493 |
</div>
|
497 |
<!-- #gdpr_cbm_faq -->
|
498 |
|
499 |
<div id="gdpr_cbm_ph" class="gdpr-help-content-block">
|
500 |
+
<?php do_action( 'gdpr_tab_cbm_ph' ); ?>
|
501 |
</div>
|
502 |
<!-- #gdpr_cbm_ph -->
|
503 |
|
504 |
<div id="gdpr_cbm_ps" class="gdpr-help-content-block">
|
505 |
+
<?php do_action( 'gdpr_tab_cbm_ps' ); ?>
|
506 |
</div>
|
507 |
<!-- #gdpr_cbm_ph -->
|
508 |
|
511 |
|
512 |
|
513 |
|
514 |
+
<script type="text/javascript" src="<?php echo esc_url( moove_gdpr_get_plugin_directory_url() ); ?>/dist/scripts/codemirror.js"></script>
|
515 |
<script type="text/javascript">
|
516 |
+
if (typeof CodeMirror !== "undefined") {
|
517 |
+
CodeMirror.defineExtension("autoFormatRange", function (from, to) {
|
518 |
+
var cm = this;
|
519 |
+
var outer = cm.getMode(), text = cm.getRange(from, to).split("\n");
|
520 |
+
var state = CodeMirror.copyState(outer, cm.getTokenAt(from).state);
|
521 |
+
var tabSize = cm.getOption("tabSize");
|
522 |
+
|
523 |
+
var out = "", lines = 0, atSol = from.ch == 0;
|
524 |
+
function newline() {
|
525 |
+
out += "\n";
|
526 |
+
atSol = true;
|
527 |
+
++lines;
|
528 |
+
}
|
529 |
+
|
530 |
+
for (var i = 0; i < text.length; ++i) {
|
531 |
+
var stream = new CodeMirror.StringStream(text[i], tabSize);
|
532 |
+
while (!stream.eol()) {
|
533 |
+
var inner = CodeMirror.innerMode(outer, state);
|
534 |
+
var style = outer.token(stream, state), cur = stream.current();
|
535 |
+
stream.start = stream.pos;
|
536 |
+
if (!atSol || /\S/.test(cur)) {
|
537 |
+
out += cur;
|
538 |
+
atSol = false;
|
539 |
+
}
|
540 |
+
if (!atSol && inner.mode.newlineAfterToken &&
|
541 |
+
inner.mode.newlineAfterToken(style, cur, stream.string.slice(stream.pos) || text[i+1] || "", inner.state))
|
542 |
+
newline();
|
543 |
+
}
|
544 |
+
if (!stream.pos && outer.blankLine) outer.blankLine(state);
|
545 |
+
if (!atSol) newline();
|
546 |
+
}
|
547 |
+
|
548 |
+
cm.operation(function () {
|
549 |
+
cm.replaceRange(out, from, to);
|
550 |
+
for (var cur = from.line + 1, end = from.line + lines; cur <= end; ++cur)
|
551 |
+
cm.indentLine(cur, "smart");
|
552 |
+
});
|
553 |
});
|
554 |
|
555 |
// Applies automatic mode-aware indentation to the specified range
|
556 |
CodeMirror.defineExtension("autoIndentRange", function (from, to) {
|
557 |
+
var cmInstance = this;
|
558 |
+
this.operation(function () {
|
559 |
+
for (var i = from.line; i <= to.line; i++) {
|
560 |
+
cmInstance.indentLine(i, "smart");
|
561 |
+
}
|
562 |
+
});
|
563 |
});
|
564 |
function GDPR_CodeMirror() {
|
565 |
jQuery('.gdpr-faq-accordion-content textarea').each(function(){
|
566 |
+
var element = jQuery(this).closest('.gdpr-faq-accordion-content').find('.gdpr-code')[0];
|
567 |
+
var id = jQuery(this).attr('id');
|
568 |
+
console.log(element);
|
569 |
+
jQuery(this).css({
|
570 |
+
'opacity' : '0',
|
571 |
+
'height' : '0',
|
572 |
+
});
|
573 |
+
var editor = CodeMirror( element, {
|
574 |
+
mode: "javascript",
|
575 |
+
lineWrapping: true,
|
576 |
+
lineNumbers: false,
|
577 |
+
readOnly: true,
|
578 |
+
value: document.getElementById(id).value
|
579 |
+
});
|
580 |
+
var totalLines = editor.lineCount();
|
581 |
editor.autoFormatRange({line:0, ch:0}, {line:totalLines});
|
582 |
+
});
|
583 |
}
|
584 |
jQuery(document).ready(function(){
|
585 |
GDPR_CodeMirror();
|
586 |
+
|
587 |
jQuery('.gdpr-faq-toggle:not(.gdpr-faq-open)').find('.gdpr-faq-accordion-content').hide();
|
588 |
jQuery('.gdpr-help-content-block:not(.help-block-open)').hide();
|
589 |
});
|
590 |
+
}
|
|
|
591 |
</script>
|
592 |
<style>
|
593 |
.CodeMirror {
|
594 |
height: auto;
|
595 |
border: none !important;
|
596 |
}
|
597 |
+
</style>
|
views/moove/admin/settings/iframe-blocker.php
CHANGED
@@ -1,4 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
<h2><?php _e('Iframe Blocker','gdpr-cookie-compliance'); ?></h2>
|
2 |
<hr />
|
3 |
-
|
4 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Iframe Blocker Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
?>
|
10 |
<h2><?php _e('Iframe Blocker','gdpr-cookie-compliance'); ?></h2>
|
11 |
<hr />
|
|
|
12 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
views/moove/admin/settings/licence.php
CHANGED
@@ -1,125 +1,133 @@
|
|
1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
<hr />
|
3 |
-
<?php
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
?>
|
11 |
-
<form action="?page=moove-gdpr&tab=licence" method="post" id="moove_gdpr_license_settings" data-key="<?php echo $gdpr_key && isset( $gdpr_key['key'] ) && isset( $gdpr_key['activation'] ) ? $gdpr_key['key'] : ''; ?>">
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
if ( $is_valid_license && isset( $is_valid_license['valid'] ) && $is_valid_license['valid'] === true ) :
|
76 |
-
// VALID
|
77 |
-
do_action( 'gdpr_get_alertbox', 'success', $is_valid_license, $license_key );
|
78 |
-
else :
|
79 |
-
// INVALID
|
80 |
-
do_action( 'gdpr_get_alertbox', 'error', $is_valid_license, $license_key );
|
81 |
-
endif;
|
82 |
-
endif;
|
83 |
-
elseif ( $gdpr_key && isset( $gdpr_key['key'] ) && isset( $gdpr_key['activation'] ) ) :
|
84 |
-
$license_manager = new Moove_GDPR_License_Manager();
|
85 |
-
$is_valid_license = $license_manager->get_premium_add_on( $gdpr_key['key'], 'check' );
|
86 |
-
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
87 |
-
if ( $is_valid_license && isset( $is_valid_license['valid'] ) && $is_valid_license['valid'] === true ) :
|
88 |
-
// VALID
|
89 |
-
do_action( 'gdpr_get_alertbox', 'success', $is_valid_license, $gdpr_key );
|
90 |
-
else :
|
91 |
-
// INVALID
|
92 |
-
do_action( 'gdpr_get_alertbox', 'error', $is_valid_license, $gdpr_key );
|
93 |
-
endif;
|
94 |
-
endif;
|
95 |
-
?>
|
96 |
-
</td>
|
97 |
-
</tr>
|
98 |
-
<?php do_action( 'gdpr_licence_input_field', $is_valid_license, $gdpr_key ); ?>
|
99 |
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
107 |
</form>
|
108 |
<div class="gdpr-admin-popup gdpr-admin-popup-deactivate" style="display: none;">
|
109 |
-
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
|
122 |
-
|
123 |
-
|
124 |
</div>
|
125 |
<!-- .gdpr-admin-popup -->
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Licence Manager Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
?>
|
11 |
+
<h2><?php esc_html_e( 'Licence Manager', 'gdpr-cookie-compliance' ); ?></h2>
|
12 |
<hr />
|
13 |
+
<?php
|
14 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
15 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
16 |
+
$gdpr_options = get_option( $option_name );
|
17 |
+
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
18 |
+
$option_key = $gdpr_default_content->moove_gdpr_get_key_name();
|
19 |
+
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
20 |
?>
|
21 |
+
<form action="<?php echo esc_url( admin_url( '?page=moove-gdpr&tab=licence' ) ); ?>" method="post" id="moove_gdpr_license_settings" data-key="<?php echo $gdpr_key && isset( $gdpr_key['key'] ) && isset( $gdpr_key['activation'] ) ? esc_attr( $gdpr_key['key'] ) : ''; ?>">
|
22 |
+
<table class="form-table">
|
23 |
+
<tbody>
|
24 |
+
<tr>
|
25 |
+
<td colspan="2" class="gdpr_license_log_alert" style="padding: 0;">
|
26 |
+
<?php
|
27 |
+
$is_valid_license = false;
|
28 |
+
wp_verify_nonce( 'gdpr_nonce', 'gdpr_cookie_compliance_nonce' );
|
29 |
+
if ( isset( $_POST['moove_gdpr_license_key'] ) && isset( $_POST['gdpr_activate_license'] ) ) :
|
30 |
+
$license_key = sanitize_text_field( wp_unslash( $_POST['moove_gdpr_license_key'] ) );
|
31 |
+
if ( $license_key ) :
|
32 |
+
$license_manager = new Moove_GDPR_License_Manager();
|
33 |
+
$is_valid_license = $license_manager->get_premium_add_on( $license_key, 'activate' );
|
34 |
+
if ( $is_valid_license && isset( $is_valid_license['valid'] ) && true === $is_valid_license['valid'] ) :
|
35 |
+
if ( function_exists( 'update_site_option' ) ) :
|
36 |
+
update_site_option(
|
37 |
+
$option_key,
|
38 |
+
array(
|
39 |
+
'key' => $is_valid_license['key'],
|
40 |
+
'activation' => $is_valid_license['data']['today'],
|
41 |
+
)
|
42 |
+
);
|
43 |
+
else :
|
44 |
+
update_option(
|
45 |
+
$option_key,
|
46 |
+
array(
|
47 |
+
'key' => $is_valid_license['key'],
|
48 |
+
'activation' => $is_valid_license['data']['today'],
|
49 |
+
)
|
50 |
+
);
|
51 |
+
endif;
|
52 |
+
// VALID.
|
53 |
+
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
54 |
+
$messages = isset( $is_valid_license['message'] ) && is_array( $is_valid_license['message'] ) ? implode( '<br>', $is_valid_license['message'] ) : '';
|
55 |
+
do_action( 'gdpr_get_alertbox', 'success', $is_valid_license, $license_key );
|
56 |
+
else :
|
57 |
+
// INVALID.
|
58 |
+
do_action( 'gdpr_get_alertbox', 'error', $is_valid_license, $license_key );
|
59 |
+
endif;
|
60 |
+
endif;
|
61 |
+
elseif ( isset( $_POST['moove_gdpr_license_key'] ) && isset( $_POST['gdpr_deactivate_license'] ) ) :
|
62 |
+
$license_key = sanitize_text_field( wp_unslash( $_POST['moove_gdpr_license_key'] ) );
|
63 |
+
if ( $license_key ) :
|
64 |
+
$license_manager = new Moove_GDPR_License_Manager();
|
65 |
+
$is_valid_license = $license_manager->premium_deactivate( $license_key );
|
66 |
+
if ( function_exists( 'update_site_option' ) ) :
|
67 |
+
update_site_option(
|
68 |
+
$option_key,
|
69 |
+
array(
|
70 |
+
'key' => $license_key,
|
71 |
+
'deactivation' => strtotime( 'now' ),
|
72 |
+
)
|
73 |
+
);
|
74 |
+
else :
|
75 |
+
update_option(
|
76 |
+
$option_key,
|
77 |
+
array(
|
78 |
+
'key' => $license_key,
|
79 |
+
'deactivation' => strtotime( 'now' ),
|
80 |
+
)
|
81 |
+
);
|
82 |
+
endif;
|
83 |
+
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
84 |
|
85 |
+
if ( $is_valid_license && isset( $is_valid_license['valid'] ) && true === $is_valid_license['valid'] ) :
|
86 |
+
// VALID.
|
87 |
+
do_action( 'gdpr_get_alertbox', 'success', $is_valid_license, $license_key );
|
88 |
+
else :
|
89 |
+
// INVALID.
|
90 |
+
do_action( 'gdpr_get_alertbox', 'error', $is_valid_license, $license_key );
|
91 |
+
endif;
|
92 |
+
endif;
|
93 |
+
elseif ( $gdpr_key && isset( $gdpr_key['key'] ) && isset( $gdpr_key['activation'] ) ) :
|
94 |
+
$license_manager = new Moove_GDPR_License_Manager();
|
95 |
+
$is_valid_license = $license_manager->get_premium_add_on( $gdpr_key['key'], 'check' );
|
96 |
+
$gdpr_key = function_exists( 'get_site_option' ) ? get_site_option( $option_key ) : get_option( $option_key );
|
97 |
+
if ( $is_valid_license && isset( $is_valid_license['valid'] ) && true === $is_valid_license['valid'] ) :
|
98 |
+
// VALID.
|
99 |
+
do_action( 'gdpr_get_alertbox', 'success', $is_valid_license, $gdpr_key );
|
100 |
+
else :
|
101 |
+
// INVALID.
|
102 |
+
do_action( 'gdpr_get_alertbox', 'error', $is_valid_license, $gdpr_key );
|
103 |
+
endif;
|
104 |
+
endif;
|
105 |
+
?>
|
106 |
+
</td>
|
107 |
+
</tr>
|
108 |
+
<?php do_action( 'gdpr_licence_input_field', $is_valid_license, $gdpr_key ); ?>
|
109 |
+
</tbody>
|
110 |
+
</table>
|
111 |
+
<br />
|
112 |
+
<?php do_action( 'gdpr_licence_action_button', $is_valid_license, $gdpr_key ); ?>
|
113 |
+
<br />
|
114 |
+
<?php do_action( 'gdpr_cc_general_buttons_settings' ); ?>
|
115 |
</form>
|
116 |
<div class="gdpr-admin-popup gdpr-admin-popup-deactivate" style="display: none;">
|
117 |
+
<span class="gdpr-popup-overlay"></span>
|
118 |
+
<div class="gdpr-popup-content">
|
119 |
+
<div class="gdpr-popup-content-header">
|
120 |
+
<a href="#" class="gdpr-popup-close"><span class="dashicons dashicons-no-alt"></span></a>
|
121 |
+
</div>
|
122 |
+
<!-- .gdpr-popup-content-header -->
|
123 |
+
<div class="gdpr-popup-content-content">
|
124 |
+
<h4><strong><?php esc_html_e( 'Please confirm that you would like to de-activate this licence.', 'gdpr-cookie-compliance' ); ?> </strong></h4><p><strong><?php esc_html_e( 'This action will remove all of the premium features from your website.', 'gdpr-cookie-compliance' ); ?></strong></p>
|
125 |
+
<button class="button button-primary button-deactivate-confirm">
|
126 |
+
<?php esc_html_e( 'Deactivate Licence', 'gdpr-cookie-compliance' ); ?>
|
127 |
+
</button>
|
128 |
+
</div>
|
129 |
+
<!-- .gdpr-popup-content-content -->
|
130 |
+
</div>
|
131 |
+
<!-- .gdpr-popup-content -->
|
132 |
</div>
|
133 |
<!-- .gdpr-admin-popup -->
|
views/moove/admin/settings/multisite-settings.php
CHANGED
@@ -1,4 +1,13 @@
|
|
1 |
-
|
2 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
|
|
|
|
|
|
|
4 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Multisite Settings Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
|
10 |
+
?>
|
11 |
+
<h2><?php esc_html_e('Multisite Settings','gdpr-cookie-compliance-addon'); ?></h2>
|
12 |
+
<hr />
|
13 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
views/moove/admin/settings/plugin-boxes.php
ADDED
@@ -0,0 +1,121 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Plugin Boxes Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
$gdpr_controller = new Moove_GDPR_Controller();
|
11 |
+
$plugin_details = $gdpr_controller->get_gdpr_plugin_details( 'gdpr-cookie-compliance' );
|
12 |
+
?>
|
13 |
+
<div class="moove-plugins-info-boxes">
|
14 |
+
|
15 |
+
<?php ob_start(); ?>
|
16 |
+
<div class="m-plugin-box m-plugin-box-highlighted">
|
17 |
+
<div class="box-header">
|
18 |
+
<h4>Premium Add-On</h4>
|
19 |
+
</div>
|
20 |
+
<!-- .box-header -->
|
21 |
+
<div class="box-content">
|
22 |
+
<div class="gdpr-faq-forum-content">
|
23 |
+
<p><span class="gdpr-chevron-left">›</span> Includes full-screen layout</p>
|
24 |
+
<p><span class="gdpr-chevron-left">›</span> Export & import settings</p>
|
25 |
+
<p><span class="gdpr-chevron-left">›</span> WordPress Multisite extension</p>
|
26 |
+
<p><span class="gdpr-chevron-left">›</span> Accept cookies on scroll</p>
|
27 |
+
<p><span class="gdpr-chevron-left">›</span> Consent Analytics</p>
|
28 |
+
<p><span class="gdpr-chevron-left">›</span> Display cookie banner for EU visitors</p>
|
29 |
+
<p><span class="gdpr-chevron-left">›</span> Language specific scripts</p>
|
30 |
+
</div>
|
31 |
+
<!-- gdpr-faq-forum-content -->
|
32 |
+
<hr />
|
33 |
+
<strong>Buy Now for only <span>£49</span></strong>
|
34 |
+
<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="plugin-buy-now-btn">Buy Now</a>
|
35 |
+
|
36 |
+
</div>
|
37 |
+
<!-- .box-content -->
|
38 |
+
</div>
|
39 |
+
<!-- .m-plugin-box -->
|
40 |
+
<?php
|
41 |
+
$content = apply_filters( 'gdpr_cookie_compliance_premium_section', ob_get_clean() );
|
42 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
43 |
+
$support_class = apply_filters( 'gdpr_support_sidebar_class', '' );
|
44 |
+
?>
|
45 |
+
<div class="m-plugin-box m-plugin-box-support <?php echo esc_attr( $support_class ); ?>">
|
46 |
+
<div class="box-header">
|
47 |
+
<h4>Need Support or New Feature?</h4>
|
48 |
+
</div>
|
49 |
+
<!-- .box-header -->
|
50 |
+
<div class="box-content">
|
51 |
+
<?php
|
52 |
+
$faq_link = apply_filters( 'gdpr_cookie_compliance_faq_section_link', 'https://wordpress.org/plugins/gdpr-cookie-compliance/#faq-header' );
|
53 |
+
$forum_link = apply_filters( 'gdpr_cookie_compliance_forum_section_link', 'https://support.mooveagency.com/forum/gdpr-cookie-compliance/' );
|
54 |
+
?>
|
55 |
+
<div class="gdpr-faq-forum-content">
|
56 |
+
<p><span class="gdpr-chevron-left">›</span> Check the <a href="<?php esc_url( admin_url( '?page=moove-gdpr&tab=help' ) ); ?>">Help section</a> to find out more about Hooks, Filters & Shortcodes available</p>
|
57 |
+
<p><span class="gdpr-chevron-left">›</span> Find answers to your questions in the <a href="<?php echo esc_url( $faq_link ); ?>" target="_blank">FAQ section</a></p>
|
58 |
+
<p><span class="gdpr-chevron-left">›</span> Create a new support ticket or request new features in our <a href="<?php echo esc_url( $forum_link ); ?>" target="_blank">Support Forum</a></p>
|
59 |
+
</div>
|
60 |
+
<!-- .gdpr-faq-forum-content -->
|
61 |
+
<span class="gdpr-review-container" >
|
62 |
+
<a href="<?php echo esc_url( $forum_link ); ?>#new-post" target="_blank" class="gdpr-review-bnt ">Create a new support ticket</a>
|
63 |
+
</span>
|
64 |
+
</div>
|
65 |
+
<!-- .box-content -->
|
66 |
+
</div>
|
67 |
+
<!-- .m-plugin-box -->
|
68 |
+
|
69 |
+
<div class="m-plugin-box">
|
70 |
+
<div class="box-header">
|
71 |
+
<h4>Find this plugin useful?</h4>
|
72 |
+
</div>
|
73 |
+
<!-- .box-header -->
|
74 |
+
<div class="box-content">
|
75 |
+
|
76 |
+
<p>You can help other users find it too by <a href="https://wordpress.org/support/plugin/gdpr-cookie-compliance/reviews/?rate=5#new-post" target="_blank">rating this plugin</a>.</p>
|
77 |
+
<?php if ( $plugin_details ) : ?>
|
78 |
+
<hr />
|
79 |
+
<div class="plugin-stats">
|
80 |
+
<div class="plugin-download-ainstalls-cnt">
|
81 |
+
<div class="plugin-downloads">
|
82 |
+
Downloads: <strong><?php echo number_format( $plugin_details->downloaded, 0, '', ',' ); ?></strong>
|
83 |
+
</div>
|
84 |
+
<!-- .plugin-downloads -->
|
85 |
+
<div class="plugin-active-installs">
|
86 |
+
Active installations: <strong><?php echo number_format( $plugin_details->active_installs, 0, '', ',' ); ?>+</strong>
|
87 |
+
</div>
|
88 |
+
<!-- .plugin-downloads -->
|
89 |
+
</div>
|
90 |
+
<!-- .plugin-download-ainstalls-cnt -->
|
91 |
+
|
92 |
+
<div class="plugin-rating">
|
93 |
+
<a href="https://wordpress.org/support/plugin/gdpr-cookie-compliance/reviews/" target="_blank">
|
94 |
+
<span class="plugin-stars">
|
95 |
+
<?php
|
96 |
+
$rating_val = $plugin_details->rating * 5 / 100;
|
97 |
+
if ( $rating_val > 0 ) :
|
98 |
+
$args = array(
|
99 |
+
'rating' => $rating_val,
|
100 |
+
'number' => $plugin_details->num_ratings,
|
101 |
+
'echo' => false,
|
102 |
+
);
|
103 |
+
$rating = wp_star_rating( $args );
|
104 |
+
endif;
|
105 |
+
if ( $rating ) :
|
106 |
+
apply_filters( 'gdpr_cc_keephtml', $rating, true );
|
107 |
+
endif;
|
108 |
+
?>
|
109 |
+
</span>
|
110 |
+
</a>
|
111 |
+
</div>
|
112 |
+
<!-- .plugin-rating -->
|
113 |
+
</div>
|
114 |
+
<!-- .plugin-stats -->
|
115 |
+
<?php endif; ?>
|
116 |
+
</div>
|
117 |
+
<!-- .box-content -->
|
118 |
+
</div>
|
119 |
+
<!-- .m-plugin-box -->
|
120 |
+
</div>
|
121 |
+
<!-- .moove-plugins-info-boxes -->
|
views/moove/admin/settings/plugin_boxes.php
DELETED
@@ -1,118 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
$gdpr_controller = new Moove_GDPR_Controller();
|
3 |
-
$plugin_details = $gdpr_controller->get_gdpr_plugin_details( 'gdpr-cookie-compliance' );
|
4 |
-
?>
|
5 |
-
<div class="moove-plugins-info-boxes">
|
6 |
-
|
7 |
-
<?php ob_start(); ?>
|
8 |
-
<div class="m-plugin-box m-plugin-box-highlighted">
|
9 |
-
<div class="box-header">
|
10 |
-
<h4>Premium Add-On</h4>
|
11 |
-
</div>
|
12 |
-
<!-- .box-header -->
|
13 |
-
<div class="box-content">
|
14 |
-
<div class="gdpr-faq-forum-content">
|
15 |
-
<p><span class="gdpr-chevron-left">›</span> Includes full-screen layout</p>
|
16 |
-
<p><span class="gdpr-chevron-left">›</span> Export & import settings</p>
|
17 |
-
<p><span class="gdpr-chevron-left">›</span> WordPress Multisite extension</p>
|
18 |
-
<p><span class="gdpr-chevron-left">›</span> Accept cookies on scroll</p>
|
19 |
-
<p><span class="gdpr-chevron-left">›</span> Consent Analytics</p>
|
20 |
-
<p><span class="gdpr-chevron-left">›</span> Display cookie banner for EU visitors</p>
|
21 |
-
<p><span class="gdpr-chevron-left">›</span> Language specific scripts</p>
|
22 |
-
</div>
|
23 |
-
<!-- gdpr-faq-forum-content -->
|
24 |
-
|
25 |
-
<hr />
|
26 |
-
<strong>Buy Now for only <span>£49</span></strong>
|
27 |
-
<a href="https://www.mooveagency.com/wordpress-plugins/gdpr-cookie-compliance/" target="_blank" class="plugin-buy-now-btn">Buy Now</a>
|
28 |
-
|
29 |
-
</div>
|
30 |
-
<!-- .box-content -->
|
31 |
-
</div>
|
32 |
-
<!-- .m-plugin-box -->
|
33 |
-
<?php echo apply_filters( 'gdpr_cookie_compliance_premium_section', ob_get_clean() ); ?>
|
34 |
-
|
35 |
-
|
36 |
-
<?php $support_class = apply_filters( 'gdpr_support_sidebar_class', '' ); ?>
|
37 |
-
|
38 |
-
<div class="m-plugin-box m-plugin-box-support <?php echo $support_class; ?>">
|
39 |
-
<div class="box-header">
|
40 |
-
<h4>Need Support or New Feature?</h4>
|
41 |
-
</div>
|
42 |
-
<!-- .box-header -->
|
43 |
-
<div class="box-content">
|
44 |
-
<?php
|
45 |
-
$faq_link = apply_filters( 'gdpr_cookie_compliance_faq_section_link', 'https://wordpress.org/plugins/gdpr-cookie-compliance/#faq-header' );
|
46 |
-
$forum_link = apply_filters( 'gdpr_cookie_compliance_forum_section_link', 'https://support.mooveagency.com/forum/gdpr-cookie-compliance/' );
|
47 |
-
?>
|
48 |
-
<div class="gdpr-faq-forum-content">
|
49 |
-
<p><span class="gdpr-chevron-left">›</span> Check the <a href="?page=moove-gdpr&tab=help">Help section</a> to find out more about Hooks, Filters & Shortcodes available</p>
|
50 |
-
<p><span class="gdpr-chevron-left">›</span> Find answers to your questions in the <a href="<?php echo $faq_link; ?>" target="_blank">FAQ section</a></p>
|
51 |
-
<p><span class="gdpr-chevron-left">›</span> Create a new support ticket or request new features in our <a href="<?php echo $forum_link; ?>" target="_blank">Support Forum</a></p>
|
52 |
-
</div>
|
53 |
-
<!-- .gdpr-faq-forum-content -->
|
54 |
-
<span class="gdpr-review-container" >
|
55 |
-
<a href="<?php echo $forum_link; ?>#new-post" target="_blank" class="gdpr-review-bnt ">Create a new support ticket</a>
|
56 |
-
</span>
|
57 |
-
</div>
|
58 |
-
<!-- .box-content -->
|
59 |
-
</div>
|
60 |
-
<!-- .m-plugin-box -->
|
61 |
-
|
62 |
-
<div class="m-plugin-box">
|
63 |
-
<div class="box-header">
|
64 |
-
<h4>Find this plugin useful?</h4>
|
65 |
-
</div>
|
66 |
-
<!-- .box-header -->
|
67 |
-
<div class="box-content">
|
68 |
-
|
69 |
-
<p>You can help other users find it too by <a href="https://wordpress.org/support/plugin/gdpr-cookie-compliance/reviews/?rate=5#new-post" target="_blank">rating this plugin</a>.</p>
|
70 |
-
|
71 |
-
<?php if ( $plugin_details ) : ?>
|
72 |
-
|
73 |
-
<hr />
|
74 |
-
<div class="plugin-stats">
|
75 |
-
<div class="plugin-download-ainstalls-cnt">
|
76 |
-
<div class="plugin-downloads">
|
77 |
-
Downloads: <strong><?php echo number_format( $plugin_details->downloaded, 0, '', ','); ?></strong>
|
78 |
-
</div>
|
79 |
-
<!-- .plugin-downloads -->
|
80 |
-
<div class="plugin-active-installs">
|
81 |
-
Active installations: <strong><?php echo number_format( $plugin_details->active_installs, 0, '', ','); ?>+</strong>
|
82 |
-
</div>
|
83 |
-
<!-- .plugin-downloads -->
|
84 |
-
</div>
|
85 |
-
<!-- .plugin-download-ainstalls-cnt -->
|
86 |
-
|
87 |
-
<div class="plugin-rating">
|
88 |
-
<a href="https://wordpress.org/support/plugin/gdpr-cookie-compliance/reviews/" target="_blank">
|
89 |
-
<span class="plugin-stars">
|
90 |
-
<?php
|
91 |
-
$rating_val = $plugin_details->rating * 5 / 100;
|
92 |
-
if ( $rating_val > 0 ) :
|
93 |
-
$args = array(
|
94 |
-
'rating' => $rating_val,
|
95 |
-
'number' => $plugin_details->num_ratings,
|
96 |
-
'echo' => false
|
97 |
-
);
|
98 |
-
$rating = wp_star_rating( $args );
|
99 |
-
endif;
|
100 |
-
?>
|
101 |
-
<?php if ( $rating ) : ?>
|
102 |
-
<?php echo $rating; ?>
|
103 |
-
<?php endif; ?>
|
104 |
-
</span>
|
105 |
-
</a>
|
106 |
-
</div>
|
107 |
-
<!-- .plugin-rating -->
|
108 |
-
|
109 |
-
</div>
|
110 |
-
<!-- .plugin-stats -->
|
111 |
-
<?php endif; ?>
|
112 |
-
</div>
|
113 |
-
<!-- .box-content -->
|
114 |
-
</div>
|
115 |
-
<!-- .m-plugin-box -->
|
116 |
-
|
117 |
-
</div>
|
118 |
-
<!-- .moove-plugins-info-boxes -->
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
views/moove/admin/settings/privacy-overview.php
ADDED
@@ -0,0 +1,91 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Privacy Overview Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
11 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
12 |
+
$gdpr_options = get_option( $option_name );
|
13 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
14 |
+
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
15 |
+
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
16 |
+
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
17 |
+
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
18 |
+
die( 'Security check' );
|
19 |
+
else :
|
20 |
+
if ( is_array( $_POST ) ) :
|
21 |
+
foreach ( $_POST as $form_key => $form_value ) :
|
22 |
+
if ( 'moove_gdpr_privacy_overview_tab_content' === $form_key ) :
|
23 |
+
$value = wp_unslash( $form_value );
|
24 |
+
$gdpr_options[ $form_key . $wpml_lang ] = $value;
|
25 |
+
update_option( $option_name, $gdpr_options );
|
26 |
+
$gdpr_options = get_option( $option_name );
|
27 |
+
else :
|
28 |
+
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
29 |
+
$gdpr_options[ $form_key ] = $value;
|
30 |
+
update_option( $option_name, $gdpr_options );
|
31 |
+
$gdpr_options = get_option( $option_name );
|
32 |
+
endif;
|
33 |
+
endforeach;
|
34 |
+
endif;
|
35 |
+
?>
|
36 |
+
<script>
|
37 |
+
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
38 |
+
</script>
|
39 |
+
<?php
|
40 |
+
endif;
|
41 |
+
do_action( 'gdpr_cookie_filter_settings' );
|
42 |
+
endif;
|
43 |
+
?>
|
44 |
+
<?php
|
45 |
+
$nav_label = isset( $gdpr_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] ? $gdpr_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] : __( 'Privacy Overview', 'gdpr-cookie-compliance' );
|
46 |
+
?>
|
47 |
+
|
48 |
+
<h2><?php echo esc_attr( $nav_label ); ?></h2>
|
49 |
+
<hr />
|
50 |
+
<form action="<?php esc_url( admin_url( '?page=moove-gdpr&tab=privacy-overview' ) ); ?>" method="post" id="moove_gdpr_tab_privacy_overview">
|
51 |
+
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
52 |
+
<table class="form-table">
|
53 |
+
<tbody>
|
54 |
+
<tr>
|
55 |
+
<th scope="row">
|
56 |
+
<label for="moove_gdpr_privacy_overview_tab_title"><?php esc_html_e( 'Tab Title', 'gdpr-cookie-compliance' ); ?></label>
|
57 |
+
</th>
|
58 |
+
<td>
|
59 |
+
<input name="moove_gdpr_privacy_overview_tab_title<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_privacy_overview_tab_title" value="<?php echo esc_attr( $nav_label ); ?>" class="regular-text">
|
60 |
+
</td>
|
61 |
+
</tr>
|
62 |
+
|
63 |
+
<tr>
|
64 |
+
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
65 |
+
<label for="moove_gdpr_privacy_overview_tab_content"><?php esc_html_e( 'Tab Content', 'gdpr-cookie-compliance' ); ?></label>
|
66 |
+
</th>
|
67 |
+
</tr>
|
68 |
+
<tr class="moove_gdpr_table_form_holder">
|
69 |
+
<th colspan="2" scope="row">
|
70 |
+
<?php
|
71 |
+
$content = isset( $gdpr_options[ 'moove_gdpr_privacy_overview_tab_content' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_privacy_overview_tab_content' . $wpml_lang ] ? wp_unslash( $gdpr_options[ 'moove_gdpr_privacy_overview_tab_content' . $wpml_lang ] ) : false;
|
72 |
+
if ( ! $content ) :
|
73 |
+
$content = $gdpr_default_content->moove_gdpr_get_privacy_overview_content();
|
74 |
+
endif;
|
75 |
+
?>
|
76 |
+
<?php
|
77 |
+
$settings = array(
|
78 |
+
'media_buttons' => false,
|
79 |
+
'editor_height' => 150,
|
80 |
+
);
|
81 |
+
wp_editor( $content, 'moove_gdpr_privacy_overview_tab_content', $settings );
|
82 |
+
?>
|
83 |
+
</th>
|
84 |
+
</tr>
|
85 |
+
</tbody>
|
86 |
+
</table>
|
87 |
+
|
88 |
+
<hr />
|
89 |
+
<br />
|
90 |
+
<button type="submit" class="button button-primary"><?php esc_html_e( 'Save changes', 'gdpr-cookie-compliance' ); ?></button>
|
91 |
+
</form>
|
views/moove/admin/settings/privacy_overview.php
DELETED
@@ -1,83 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
3 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
4 |
-
$gdpr_options = get_option( $option_name );
|
5 |
-
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
6 |
-
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
7 |
-
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
8 |
-
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
9 |
-
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
10 |
-
die( 'Security check' );
|
11 |
-
else :
|
12 |
-
if ( is_array( $_POST ) ) :
|
13 |
-
foreach ( $_POST as $form_key => $form_value ) :
|
14 |
-
if ( $form_key === 'moove_gdpr_privacy_overview_tab_content' ) :
|
15 |
-
$value = wp_unslash( $form_value );
|
16 |
-
$gdpr_options[$form_key.$wpml_lang] = $value;
|
17 |
-
update_option( $option_name, $gdpr_options );
|
18 |
-
$gdpr_options = get_option( $option_name );
|
19 |
-
else :
|
20 |
-
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
21 |
-
$gdpr_options[$form_key] = $value;
|
22 |
-
update_option( $option_name, $gdpr_options );
|
23 |
-
$gdpr_options = get_option( $option_name );
|
24 |
-
endif;
|
25 |
-
endforeach;
|
26 |
-
endif;
|
27 |
-
?>
|
28 |
-
<script>
|
29 |
-
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
30 |
-
</script>
|
31 |
-
<?php
|
32 |
-
endif;
|
33 |
-
do_action('gdpr_cookie_filter_settings');
|
34 |
-
endif;
|
35 |
-
?>
|
36 |
-
<?php
|
37 |
-
$nav_label = isset( $gdpr_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] ) && $gdpr_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] ? $gdpr_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] : __('Privacy Overview','gdpr-cookie-compliance');
|
38 |
-
?>
|
39 |
-
|
40 |
-
<h2><?php echo $nav_label; ?></h2>
|
41 |
-
<hr />
|
42 |
-
<form action="?page=moove-gdpr&tab=privacy_overview" method="post" id="moove_gdpr_tab_privacy_overview">
|
43 |
-
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
44 |
-
<table class="form-table">
|
45 |
-
<tbody>
|
46 |
-
<tr>
|
47 |
-
<th scope="row">
|
48 |
-
<label for="moove_gdpr_privacy_overview_tab_title"><?php _e('Tab Title','gdpr-cookie-compliance'); ?></label>
|
49 |
-
</th>
|
50 |
-
<td>
|
51 |
-
<input name="moove_gdpr_privacy_overview_tab_title<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_privacy_overview_tab_title" value="<?php echo $nav_label; ?>" class="regular-text">
|
52 |
-
</td>
|
53 |
-
</tr>
|
54 |
-
|
55 |
-
<tr>
|
56 |
-
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
57 |
-
<label for="moove_gdpr_privacy_overview_tab_content"><?php _e('Tab Content','gdpr-cookie-compliance'); ?></label>
|
58 |
-
</th>
|
59 |
-
</tr>
|
60 |
-
<tr class="moove_gdpr_table_form_holder">
|
61 |
-
<th colspan="2" scope="row">
|
62 |
-
<?php
|
63 |
-
$content = isset( $gdpr_options['moove_gdpr_privacy_overview_tab_content'.$wpml_lang] ) && $gdpr_options['moove_gdpr_privacy_overview_tab_content'.$wpml_lang] ? wp_unslash( $gdpr_options['moove_gdpr_privacy_overview_tab_content'.$wpml_lang] ) : false;
|
64 |
-
if ( ! $content ) :
|
65 |
-
$content = $gdpr_default_content->moove_gdpr_get_privacy_overview_content();
|
66 |
-
endif;
|
67 |
-
?>
|
68 |
-
<?php
|
69 |
-
$settings = array (
|
70 |
-
'media_buttons' => false,
|
71 |
-
'editor_height' => 150,
|
72 |
-
);
|
73 |
-
wp_editor( $content, 'moove_gdpr_privacy_overview_tab_content', $settings );
|
74 |
-
?>
|
75 |
-
</th>
|
76 |
-
</tr>
|
77 |
-
</tbody>
|
78 |
-
</table>
|
79 |
-
|
80 |
-
<hr />
|
81 |
-
<br />
|
82 |
-
<button type="submit" class="button button-primary"><?php _e('Save changes','gdpr-cookie-compliance'); ?></button>
|
83 |
-
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
views/moove/admin/settings/settings-page.php
ADDED
@@ -0,0 +1,160 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Settings Page Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
?>
|
11 |
+
<div class="gdpr-cookie-compliance-header-section">
|
12 |
+
<h2><?php esc_html_e( 'GDPR Cookie Compliance Plugin', 'gdpr-cookie-compliance' ); ?> <span class="gdpr-plugin-version"><?php echo 'v' . esc_attr( MOOVE_GDPR_VERSION ); ?></span></h2>
|
13 |
+
<h4>
|
14 |
+
<?php
|
15 |
+
$content = __( 'General Data Protection Regulation (GDPR) is a <a href="http://www.eugdpr.org/" target="_blank">European regulation</a> to strengthen and unify the data protection of EU citizens.', 'gdpr-cookie-compliance' );
|
16 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
17 |
+
?>
|
18 |
+
<br>
|
19 |
+
</h4>
|
20 |
+
</div>
|
21 |
+
<!-- .gdpr-header-section -->
|
22 |
+
<script type="text/javascript" src="<?php echo esc_url( moove_gdpr_get_plugin_directory_url() ); ?>/dist/scripts/colorpicker.js"></script>
|
23 |
+
<div class="wrap moove-clearfix" id="moove_form_checker_wrap">
|
24 |
+
<h1></h1>
|
25 |
+
<div id="moove-gdpr-setting-error-settings_updated" class="updated settings-error notice is-dismissible" style="display:none;">
|
26 |
+
<p><strong><?php esc_html_e( 'Settings saved.', 'gdpr-cookie-compliance' ); ?></strong></p>
|
27 |
+
<button type="button" class="notice-dismiss">
|
28 |
+
<span class="screen-reader-text"><?php esc_html_e( 'Dismiss this notice.', 'gdpr-cookie-compliance' ); ?></span>
|
29 |
+
</button>
|
30 |
+
</div>
|
31 |
+
|
32 |
+
<?php do_action( 'gdpr_premium_update_alert' ); ?>
|
33 |
+
|
34 |
+
<div id="moove-gdpr-setting-error-settings_scripts_empty" class="error settings-error notice is-dismissible" style="display:none;">
|
35 |
+
<p>
|
36 |
+
<strong><?php esc_html_e( 'You need to insert the relevant script for the settings to be saved!', 'gdpr-cookie-compliance' ); ?></strong>
|
37 |
+
</p>
|
38 |
+
<button type="button" class="notice-dismiss">
|
39 |
+
<span class="screen-reader-text"><?php esc_html_e( 'Dismiss this notice.', 'gdpr-cookie-compliance' ); ?></span>
|
40 |
+
</button>
|
41 |
+
</div>
|
42 |
+
|
43 |
+
<?php
|
44 |
+
|
45 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
46 |
+
wp_verify_nonce( 'gdpr_nonce', 'gdpr_cookie_compliance_nonce' );
|
47 |
+
$current_tab = isset( $_GET['tab'] ) ? sanitize_text_field( wp_unslash( $_GET['tab'] ) ) : '';
|
48 |
+
if ( isset( $current_tab ) && '' !== $current_tab ) :
|
49 |
+
$active_tab = $current_tab;
|
50 |
+
else :
|
51 |
+
$active_tab = 'branding';
|
52 |
+
endif; // end if.
|
53 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
54 |
+
$modal_options = get_option( $option_name );
|
55 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
56 |
+
|
57 |
+
|
58 |
+
|
59 |
+
if ( $wpml_lang ) :
|
60 |
+
$_current_user = wp_get_current_user();
|
61 |
+
$show_language_alert = isset( $modal_options[ 'gdpr_hide_language_notice_' . $_current_user->ID ] ) && 1 === intval( $modal_options[ 'gdpr_hide_language_notice_' . $_current_user->ID ] ) ? 'display: none;' : 'display: inline-block;';
|
62 |
+
?>
|
63 |
+
<div class="gdpr-cookie-alert" style="<?php echo esc_attr( $show_language_alert ); ?>">
|
64 |
+
<h4><?php esc_html_e( 'We have detected that you have a multi-language setup.', 'gdpr-cookie-compliance' ); ?></h4>
|
65 |
+
<p>
|
66 |
+
<?php /* translators: %s: version number */ ?>
|
67 |
+
<?php printf( esc_html__( 'You are currently editing: %s version', 'gdpr-cookie-compliance' ), '<strong>' . esc_attr( gdpr_get_display_language_by_locale( str_replace( '_', '', $wpml_lang ) ) ) . '</strong>' ); ?>
|
68 |
+
<span class="gdpr-dismiss" title="<?php esc_html_e( 'dismiss notice', 'gdpr-cookie-compliance' ); ?>" data-adminajax="<?php echo esc_url( admin_url( 'admin-ajax.php' ) ); ?>" data-uid="<?php echo intval( $_current_user->ID ); ?>">×</span>
|
69 |
+
</div>
|
70 |
+
<!-- .gdpr-cookie-alert -->
|
71 |
+
<?php endif; ?>
|
72 |
+
<br />
|
73 |
+
<div class="gdpr-tab-section-cnt">
|
74 |
+
<h2 class="nav-tab-wrapper">
|
75 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=branding' ) ); ?>" class="nav-tab <?php echo 'branding' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
76 |
+
<?php esc_html_e( 'Branding', 'gdpr-cookie-compliance' ); ?>
|
77 |
+
</a>
|
78 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=banner-settings' ) ); ?>" class="nav-tab <?php echo 'banner-settings' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
79 |
+
<?php esc_html_e( 'Banner Settings', 'gdpr-cookie-compliance' ); ?>
|
80 |
+
</a>
|
81 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=floating-button' ) ); ?>" class="nav-tab <?php echo 'floating-button' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
82 |
+
<?php esc_html_e( 'Floating Button', 'gdpr-cookie-compliance' ); ?>
|
83 |
+
</a>
|
84 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=general-settings' ) ); ?>" class="nav-tab <?php echo 'general-settings' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
85 |
+
<?php esc_html_e( 'General Settings', 'gdpr-cookie-compliance' ); ?>
|
86 |
+
</a>
|
87 |
+
<?php
|
88 |
+
$nav_label = isset( $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_privacy_overview_tab_title' . $wpml_lang ] : __( 'Privacy Overview', 'gdpr-cookie-compliance' );
|
89 |
+
?>
|
90 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=privacy-overview' ) ); ?>" class="nav-tab <?php echo 'privacy-overview' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
91 |
+
<?php echo esc_attr( $nav_label ); ?>
|
92 |
+
</a>
|
93 |
+
<?php
|
94 |
+
$nav_label = isset( $modal_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] : __( 'Strictly Necessary Cookies', 'gdpr-cookie-compliance' );
|
95 |
+
?>
|
96 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=strictly-necessary-cookies' ) ); ?>" class="nav-tab <?php echo 'strictly-necessary-cookies' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
97 |
+
<?php echo esc_attr( $nav_label ); ?>
|
98 |
+
</a>
|
99 |
+
|
100 |
+
<?php
|
101 |
+
$nav_label = isset( $modal_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] : __( '3rd Party Cookies', 'gdpr-cookie-compliance' );
|
102 |
+
?>
|
103 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=third-party-cookies' ) ); ?>" class="nav-tab <?php echo 'third-party-cookies' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
104 |
+
<?php echo esc_attr( $nav_label ); ?>
|
105 |
+
</a>
|
106 |
+
|
107 |
+
<?php
|
108 |
+
$nav_label = isset( $modal_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_advanced_cookies_tab_title' . $wpml_lang ] : __( 'Additional Cookies', 'gdpr-cookie-compliance' );
|
109 |
+
?>
|
110 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=advanced-cookies' ) ); ?>" class="nav-tab <?php echo 'advanced-cookies' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
111 |
+
<?php echo esc_attr( $nav_label ); ?>
|
112 |
+
</a>
|
113 |
+
<?php
|
114 |
+
$nav_label = isset( $modal_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] ) && $modal_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] ? $modal_options[ 'moove_gdpr_cookie_policy_tab_nav_label' . $wpml_lang ] : __( 'Cookie Policy', 'gdpr-cookie-compliance' );
|
115 |
+
?>
|
116 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=cookie-policy' ) ); ?>" class="nav-tab <?php echo 'cookie-policy' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
117 |
+
<?php echo esc_attr( $nav_label ); ?>
|
118 |
+
</a>
|
119 |
+
|
120 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=help' ) ); ?>" class="nav-tab <?php echo 'help' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
121 |
+
<?php esc_html_e( 'Help, Hooks, Filters & Shortcodes', 'gdpr-cookie-compliance' ); ?>
|
122 |
+
</a>
|
123 |
+
|
124 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=video-tutorial' ) ); ?>" class="nav-tab <?php echo 'video-tutorial' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
125 |
+
<?php esc_html_e( 'Video Tutorial', 'gdpr-cookie-compliance-addon' ); ?>
|
126 |
+
</a>
|
127 |
+
|
128 |
+
<a href="<?php echo esc_attr( admin_url( '?page=moove-gdpr&tab=licence' ) ); ?>" class="nav-tab <?php echo 'licence' === $active_tab ? 'nav-tab-active' : ''; ?>">
|
129 |
+
<?php esc_html_e( 'Licence Manager', 'gdpr-cookie-compliance-addon' ); ?>
|
130 |
+
</a>
|
131 |
+
|
132 |
+
<?php do_action( 'gdpr_settings_tab_nav_extensions', $active_tab ); ?>
|
133 |
+
</h2>
|
134 |
+
|
135 |
+
<div class="moove-gdpr-form-container <?php echo esc_attr( $active_tab ); ?>">
|
136 |
+
<?php
|
137 |
+
$view_cnt = new GDPR_View();
|
138 |
+
$tab_data = $view_cnt->load( 'moove.admin.settings.' . $active_tab, array() );
|
139 |
+
$content = apply_filters( 'gdpr_settings_tab_content', $tab_data, $active_tab );
|
140 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
141 |
+
?>
|
142 |
+
</div>
|
143 |
+
<!-- moove-form-container -->
|
144 |
+
</div>
|
145 |
+
<!-- .gdpr-tab-section-cnt -->
|
146 |
+
<?php
|
147 |
+
$view_cnt = new GDPR_View();
|
148 |
+
$content = $view_cnt->load( 'moove.admin.settings.plugin-boxes', array() );
|
149 |
+
apply_filters( 'gdpr_cc_keephtml', $content, true );
|
150 |
+
?>
|
151 |
+
<div class="moove-clearfix"></div>
|
152 |
+
<!-- .moove-clearfix -->
|
153 |
+
<div class="moove-gdpr-settings-branding">
|
154 |
+
<hr />
|
155 |
+
</div>
|
156 |
+
<!-- .moove-gdpr-settings-branding -->
|
157 |
+
</div>
|
158 |
+
<!-- .wrap -->
|
159 |
+
|
160 |
+
|
views/moove/admin/settings/settings_page.php
DELETED
@@ -1,159 +0,0 @@
|
|
1 |
-
<div class="gdpr-cookie-compliance-header-section">
|
2 |
-
<h2><?php _e('GDPR Cookie Compliance Plugin','gdpr-cookie-compliance'); ?> <span class="gdpr-plugin-version"><?php echo 'v'.MOOVE_GDPR_VERSION ?></span></h2>
|
3 |
-
<h4><?php _e('General Data Protection Regulation (GDPR) is a <a href="http://www.eugdpr.org/" target="_blank">European regulation</a> to strengthen and unify the data protection of EU citizens.','gdpr-cookie-compliance'); ?><br> </h4>
|
4 |
-
</div>
|
5 |
-
<!-- .gdpr-header-section -->
|
6 |
-
<script type="text/javascript" src="<?php echo moove_gdpr_get_plugin_directory_url(); ?>/dist/scripts/colorpicker.js"></script>
|
7 |
-
<div class="wrap moove-clearfix" id="moove_form_checker_wrap">
|
8 |
-
<h1></h1>
|
9 |
-
<div id="moove-gdpr-setting-error-settings_updated" class="updated settings-error notice is-dismissible" style="display:none;">
|
10 |
-
<p><strong><?php _e('Settings saved.','gdpr-cookie-compliance'); ?></strong></p>
|
11 |
-
<button type="button" class="notice-dismiss">
|
12 |
-
<span class="screen-reader-text"><?php _e('Dismiss this notice.','gdpr-cookie-compliance'); ?></span>
|
13 |
-
</button>
|
14 |
-
</div>
|
15 |
-
|
16 |
-
<?php do_action('gdpr_premium_update_alert'); ?>
|
17 |
-
|
18 |
-
<div id="moove-gdpr-setting-error-settings_scripts_empty" class="error settings-error notice is-dismissible" style="display:none;">
|
19 |
-
<p>
|
20 |
-
<strong><?php _e('You need to insert the relevant script for the settings to be saved!','gdpr-cookie-compliance'); ?></strong>
|
21 |
-
</p>
|
22 |
-
<button type="button" class="notice-dismiss">
|
23 |
-
<span class="screen-reader-text"><?php _e('Dismiss this notice.','gdpr-cookie-compliance'); ?></span>
|
24 |
-
</button>
|
25 |
-
</div>
|
26 |
-
|
27 |
-
<?php
|
28 |
-
|
29 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
30 |
-
$current_tab = isset( $_GET['tab'] ) ? sanitize_text_field( wp_unslash( $_GET['tab'] ) ) : '';
|
31 |
-
if( isset( $current_tab ) && $current_tab !== '' ) :
|
32 |
-
$active_tab = $current_tab;
|
33 |
-
else :
|
34 |
-
$active_tab = "branding";
|
35 |
-
endif; // end if
|
36 |
-
|
37 |
-
|
38 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
39 |
-
$modal_options = get_option( $option_name );
|
40 |
-
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
if ( $wpml_lang ) :
|
45 |
-
$current_user = wp_get_current_user();
|
46 |
-
$show_language_alert = isset( $modal_options['gdpr_hide_language_notice_' . $current_user->ID ] ) && intval( $modal_options['gdpr_hide_language_notice_' . $current_user->ID ] ) === 1 ? 'style="display: none;"' : 'style="display: inline-block;"';
|
47 |
-
?>
|
48 |
-
<div class="gdpr-cookie-alert" <?php echo $show_language_alert ?>>
|
49 |
-
<h4><?php _e('We have detected that you have a multi-language setup.','gdpr-cookie-compliance'); ?></h4>
|
50 |
-
<p><?php printf( esc_html__( 'You are currently editing: %s version', 'gdpr-cookie-compliance' ), '<strong>' . gdpr_get_display_language_by_locale( str_replace( '_', '', $wpml_lang ) ) . '</strong>'); ?>
|
51 |
-
<span class="gdpr-dismiss" title="<?php _e('dismiss notice','gdpr-cookie-compliance'); ?>" data-adminajax="<?php echo admin_url( 'admin-ajax.php' ); ?>" data-uid="<?php echo $current_user->ID; ?>">×</span>
|
52 |
-
</div>
|
53 |
-
<!-- .gdpr-cookie-alert -->
|
54 |
-
<?php
|
55 |
-
endif;
|
56 |
-
|
57 |
-
?>
|
58 |
-
|
59 |
-
<br />
|
60 |
-
|
61 |
-
<div class="gdpr-tab-section-cnt">
|
62 |
-
|
63 |
-
<h2 class="nav-tab-wrapper">
|
64 |
-
<a href="?page=moove-gdpr&tab=branding" class="nav-tab <?php echo $active_tab == 'branding' ? 'nav-tab-active' : ''; ?>">
|
65 |
-
<?php _e('Branding','gdpr-cookie-compliance'); ?>
|
66 |
-
</a>
|
67 |
-
|
68 |
-
<a href="?page=moove-gdpr&tab=banner_settings" class="nav-tab <?php echo $active_tab == 'banner_settings' ? 'nav-tab-active' : ''; ?>">
|
69 |
-
<?php _e('Banner Settings','gdpr-cookie-compliance'); ?>
|
70 |
-
</a>
|
71 |
-
|
72 |
-
<a href="?page=moove-gdpr&tab=floating_button" class="nav-tab <?php echo $active_tab == 'floating_button' ? 'nav-tab-active' : ''; ?>">
|
73 |
-
<?php _e('Floating Button','gdpr-cookie-compliance'); ?>
|
74 |
-
</a>
|
75 |
-
|
76 |
-
<a href="?page=moove-gdpr&tab=general_settings" class="nav-tab <?php echo $active_tab == 'general_settings' ? 'nav-tab-active' : ''; ?>">
|
77 |
-
<?php _e('General Settings','gdpr-cookie-compliance'); ?>
|
78 |
-
</a>
|
79 |
-
|
80 |
-
<?php
|
81 |
-
$nav_label = isset( $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_privacy_overview_tab_title'.$wpml_lang] : __('Privacy Overview','gdpr-cookie-compliance');
|
82 |
-
?>
|
83 |
-
<a href="?page=moove-gdpr&tab=privacy_overview" class="nav-tab <?php echo $active_tab == 'privacy_overview' ? 'nav-tab-active' : ''; ?>">
|
84 |
-
<?php echo $nav_label; ?>
|
85 |
-
</a>
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
<?php
|
90 |
-
$nav_label = isset( $modal_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] : __('Strictly Necessary Cookies','gdpr-cookie-compliance');
|
91 |
-
?>
|
92 |
-
<a href="?page=moove-gdpr&tab=strictly_necessary_cookies" class="nav-tab <?php echo $active_tab == 'strictly_necessary_cookies' ? 'nav-tab-active' : ''; ?>">
|
93 |
-
<?php echo $nav_label; ?>
|
94 |
-
</a>
|
95 |
-
|
96 |
-
<?php
|
97 |
-
$nav_label = isset( $modal_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] : __('3rd Party Cookies','gdpr-cookie-compliance');
|
98 |
-
?>
|
99 |
-
<a href="?page=moove-gdpr&tab=third_party_cookies" class="nav-tab <?php echo $active_tab == 'third_party_cookies' ? 'nav-tab-active' : ''; ?>">
|
100 |
-
<?php echo $nav_label; ?>
|
101 |
-
</a>
|
102 |
-
|
103 |
-
<?php
|
104 |
-
$nav_label = isset( $modal_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] ) && $modal_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] ? $modal_options['moove_gdpr_advanced_cookies_tab_title'.$wpml_lang] : __('Additional Cookies','gdpr-cookie-compliance');
|
105 |
-
?>
|
106 |
-
<a href="?page=moove-gdpr&tab=advanced_cookies" class="nav-tab <?php echo $active_tab == 'advanced_cookies' ? 'nav-tab-active' : ''; ?>">
|
107 |
-
<?php echo $nav_label; ?>
|
108 |
-
</a>
|
109 |
-
<?php
|
110 |
-
$nav_label = isset( $modal_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] ) && $modal_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] ? $modal_options['moove_gdpr_cookie_policy_tab_nav_label'.$wpml_lang] : __('Cookie Policy','gdpr-cookie-compliance');
|
111 |
-
?>
|
112 |
-
<a href="?page=moove-gdpr&tab=cookie_policy" class="nav-tab <?php echo $active_tab == 'cookie_policy' ? 'nav-tab-active' : ''; ?>">
|
113 |
-
<?php echo $nav_label; ?>
|
114 |
-
</a>
|
115 |
-
|
116 |
-
<a href="?page=moove-gdpr&tab=help" class="nav-tab <?php echo $active_tab == 'help' ? 'nav-tab-active' : ''; ?>">
|
117 |
-
<?php _e('Help, Hooks, Filters & Shortcodes','gdpr-cookie-compliance'); ?>
|
118 |
-
</a>
|
119 |
-
|
120 |
-
<a href="?page=moove-gdpr&tab=video-tutorial" class="nav-tab <?php echo $active_tab == 'video-tutorial' ? 'nav-tab-active' : ''; ?>">
|
121 |
-
<?php _e('Video Tutorial','gdpr-cookie-compliance-addon'); ?>
|
122 |
-
</a>
|
123 |
-
|
124 |
-
<a href="?page=moove-gdpr&tab=licence" class="nav-tab <?php echo $active_tab == 'licence' ? 'nav-tab-active' : ''; ?>">
|
125 |
-
<?php _e('Licence Manager','gdpr-cookie-compliance-addon'); ?>
|
126 |
-
</a>
|
127 |
-
|
128 |
-
|
129 |
-
<?php do_action('gdpr_settings_tab_nav_extensions', $active_tab); ?>
|
130 |
-
|
131 |
-
</h2>
|
132 |
-
|
133 |
-
<div class="moove-gdpr-form-container <?php echo $active_tab; ?>">
|
134 |
-
|
135 |
-
<?php
|
136 |
-
|
137 |
-
$view_cnt = new GDPR_View();
|
138 |
-
$tab_data = $view_cnt->load( 'moove.admin.settings.' . $active_tab , array() );
|
139 |
-
|
140 |
-
echo apply_filters( 'gdpr_settings_tab_content', $tab_data, $active_tab ); ?>
|
141 |
-
</div>
|
142 |
-
<!-- moove-form-container -->
|
143 |
-
</div>
|
144 |
-
<!-- .gdpr-tab-section-cnt -->
|
145 |
-
<?php
|
146 |
-
$view_cnt = new GDPR_View();
|
147 |
-
echo $view_cnt->load( 'moove.admin.settings.plugin_boxes', array() );
|
148 |
-
?>
|
149 |
-
<div class="moove-clearfix"></div>
|
150 |
-
<!-- .moove-clearfix -->
|
151 |
-
<div class="moove-gdpr-settings-branding">
|
152 |
-
<hr />
|
153 |
-
|
154 |
-
</div>
|
155 |
-
<!-- .moove-gdpr-settings-branding -->
|
156 |
-
</div>
|
157 |
-
<!-- .wrap -->
|
158 |
-
|
159 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
views/moove/admin/settings/stats.php
CHANGED
@@ -1,3 +1,13 @@
|
|
1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
<hr />
|
3 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Stats Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
?>
|
11 |
+
<h2><?php esc_html_e('GDPR Analytics','gdpr-cookie-compliance'); ?></h2>
|
12 |
<hr />
|
13 |
<?php do_action('gdpr_premium_section_ads'); ?>
|
views/moove/admin/settings/strictly-necessary-cookies.php
ADDED
@@ -0,0 +1,168 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Strictly Necessary Cookies Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
11 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
12 |
+
$gdpr_options = get_option( $option_name );
|
13 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
14 |
+
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
15 |
+
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
16 |
+
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
17 |
+
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
18 |
+
die( 'Security check' );
|
19 |
+
else :
|
20 |
+
if ( is_array( $_POST ) ) :
|
21 |
+
$value = 1;
|
22 |
+
if ( isset( $_POST['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $_POST['moove_gdpr_strictly_necessary_cookies_functionality'] ) ) :
|
23 |
+
$value = intval( $_POST['moove_gdpr_strictly_necessary_cookies_functionality'] );
|
24 |
+
endif;
|
25 |
+
|
26 |
+
$gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] = $value;
|
27 |
+
update_option( $option_name, $gdpr_options );
|
28 |
+
$gdpr_options = get_option( $option_name );
|
29 |
+
foreach ( $_POST as $form_key => $form_value ) :
|
30 |
+
if ( 'moove_gdpr_strict_necessary_cookies_tab_content' === $form_key ) :
|
31 |
+
$value = wp_unslash( $form_value );
|
32 |
+
$gdpr_options[ $form_key . $wpml_lang ] = $value;
|
33 |
+
update_option( $option_name, $gdpr_options );
|
34 |
+
$gdpr_options = get_option( $option_name );
|
35 |
+
elseif ( 'moove_gdpr_modal_strictly_secondary_notice' === $form_key ) :
|
36 |
+
$value = wpautop( wp_unslash( $form_value ) );
|
37 |
+
$gdpr_options[ $form_key . $wpml_lang ] = $value;
|
38 |
+
update_option( $option_name, $gdpr_options );
|
39 |
+
$gdpr_options = get_option( $option_name );
|
40 |
+
elseif ( 'moove_gdpr_strictly_necessary_cookies_warning' === $form_key ) :
|
41 |
+
$value = wp_unslash( $form_value );
|
42 |
+
$gdpr_options[ $form_key . $wpml_lang ] = $value;
|
43 |
+
update_option( $option_name, $gdpr_options );
|
44 |
+
$gdpr_options = get_option( $option_name );
|
45 |
+
elseif ( 'moove_gdpr_strictly_necessary_cookies_functionality' !== $form_key ) :
|
46 |
+
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
47 |
+
$gdpr_options[ $form_key ] = $value;
|
48 |
+
update_option( $option_name, $gdpr_options );
|
49 |
+
$gdpr_options = get_option( $option_name );
|
50 |
+
endif;
|
51 |
+
endforeach;
|
52 |
+
endif;
|
53 |
+
do_action( 'gdpr_cookie_filter_settings' );
|
54 |
+
?>
|
55 |
+
<script>
|
56 |
+
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
57 |
+
</script>
|
58 |
+
<?php
|
59 |
+
endif;
|
60 |
+
endif;
|
61 |
+
?>
|
62 |
+
<?php
|
63 |
+
$nav_label = isset( $gdpr_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] ? $gdpr_options[ 'moove_gdpr_strictly_necessary_cookies_tab_title' . $wpml_lang ] : __( 'Strictly Necessary Cookies', 'gdpr-cookie-compliance' );
|
64 |
+
?>
|
65 |
+
<h2><?php echo esc_attr( $nav_label ); ?></h2>
|
66 |
+
<hr />
|
67 |
+
<form action="<?php echo esc_url( admin_url( '?page=moove-gdpr&tab=strictly-necessary-cookies' ) ); ?>" method="post" id="moove_gdpr_tab_strictly_necessary_cookies">
|
68 |
+
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
69 |
+
<table class="form-table">
|
70 |
+
<tbody>
|
71 |
+
<tr>
|
72 |
+
<th scope="row">
|
73 |
+
<label for="moove_gdpr_strictly_necessary_cookies_functionality"><?php esc_html_e( 'Choose functionality', 'gdpr-cookie-compliance' ); ?></label>
|
74 |
+
</th>
|
75 |
+
<td>
|
76 |
+
|
77 |
+
<input name="moove_gdpr_strictly_necessary_cookies_functionality" type="radio" value="1" id="moove_gdpr_strictly_necessary_cookies_functionality_1" <?php echo isset( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? ( intval( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) === 1 ? 'checked' : '' ) : 'checked'; ?> class="on-off"> <label for="moove_gdpr_strictly_necessary_cookies_functionality_1"><?php esc_html_e( 'Optional (user selects their preferences)', 'gdpr-cookie-compliance' ); ?></label> <span class="separator"></span><br /><br />
|
78 |
+
|
79 |
+
<input name="moove_gdpr_strictly_necessary_cookies_functionality" type="radio" value="2" id="moove_gdpr_strictly_necessary_cookies_functionality_2" <?php echo isset( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? ( intval( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) === 2 ? 'checked' : '' ) : ''; ?> class="on-off"> <label for="moove_gdpr_strictly_necessary_cookies_functionality_2"><?php esc_html_e( 'Always enabled (user cannot disable it but can see the content)', 'gdpr-cookie-compliance' ); ?></label><br /><br />
|
80 |
+
|
81 |
+
<input name="moove_gdpr_strictly_necessary_cookies_functionality" type="radio" value="3" id="moove_gdpr_strictly_necessary_cookies_functionality_3" <?php echo isset( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? ( intval( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) === 3 ? 'checked' : '' ) : ''; ?> class="on-off"> <label for="moove_gdpr_strictly_necessary_cookies_functionality_3"><?php esc_html_e( 'Always enabled and content hidden from user', 'gdpr-cookie-compliance' ); ?></label><br /><br />
|
82 |
+
</td>
|
83 |
+
</tr>
|
84 |
+
<tr>
|
85 |
+
<th scope="row">
|
86 |
+
<label for="moove_gdpr_strictly_necessary_cookies_tab_title">
|
87 |
+
<?php esc_html_e( 'Tab Title', 'gdpr-cookie-compliance' ); ?>
|
88 |
+
</label>
|
89 |
+
</th>
|
90 |
+
<td>
|
91 |
+
<input name="moove_gdpr_strictly_necessary_cookies_tab_title<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_strictly_necessary_cookies_tab_title" value="<?php echo esc_attr( $nav_label ); ?>" class="regular-text">
|
92 |
+
</td>
|
93 |
+
</tr>
|
94 |
+
|
95 |
+
<tr>
|
96 |
+
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
97 |
+
<label for="moove_gdpr_strict_necessary_cookies_tab_content">
|
98 |
+
<?php esc_html_e( 'Tab Content', 'gdpr-cookie-compliance' ); ?>
|
99 |
+
</label>
|
100 |
+
</th>
|
101 |
+
</tr>
|
102 |
+
<tr class="moove_gdpr_table_form_holder">
|
103 |
+
<td colspan="2" scope="row" style="padding-left: 0;">
|
104 |
+
<?php
|
105 |
+
$content = isset( $gdpr_options[ 'moove_gdpr_strict_necessary_cookies_tab_content' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_strict_necessary_cookies_tab_content' . $wpml_lang ] ? wp_unslash( $gdpr_options[ 'moove_gdpr_strict_necessary_cookies_tab_content' . $wpml_lang ] ) : false;
|
106 |
+
if ( ! $content ) :
|
107 |
+
$content = $gdpr_default_content->moove_gdpr_get_strict_necessary_content();
|
108 |
+
endif;
|
109 |
+
|
110 |
+
$settings = array(
|
111 |
+
'media_buttons' => false,
|
112 |
+
'editor_height' => 150,
|
113 |
+
);
|
114 |
+
wp_editor( $content, 'moove_gdpr_strict_necessary_cookies_tab_content', $settings );
|
115 |
+
?>
|
116 |
+
</td>
|
117 |
+
</tr>
|
118 |
+
|
119 |
+
<tr>
|
120 |
+
<th scope="row" style="padding-bottom: 0;" colspan="2">
|
121 |
+
<label for="moove_gdpr_strictly_necessary_cookies_warning">
|
122 |
+
<?php esc_html_e( 'Tab Warning Message', 'gdpr-cookie-compliance' ); ?>
|
123 |
+
</label>
|
124 |
+
</th>
|
125 |
+
</tr>
|
126 |
+
<tr>
|
127 |
+
<td style="padding-top: 10px; padding-left: 0;" colspan="2">
|
128 |
+
<?php
|
129 |
+
$content = isset( $gdpr_options[ 'moove_gdpr_strictly_necessary_cookies_warning' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_strictly_necessary_cookies_warning' . $wpml_lang ] ? $gdpr_options[ 'moove_gdpr_strictly_necessary_cookies_warning' . $wpml_lang ] : $gdpr_default_content->moove_gdpr_get_strict_necessary_warning();
|
130 |
+
$settings = array(
|
131 |
+
'media_buttons' => false,
|
132 |
+
'editor_height' => 100,
|
133 |
+
);
|
134 |
+
wp_editor( $content, 'moove_gdpr_strictly_necessary_cookies_warning', $settings );
|
135 |
+
?>
|
136 |
+
<p class="description"><?php esc_html_e( 'This warning message will be displayed when user disables the Strictly Necessary Cookies.', 'gdpr-cookie-compliance' ); ?></p>
|
137 |
+
</td>
|
138 |
+
</tr>
|
139 |
+
|
140 |
+
<tr>
|
141 |
+
<th scope="row" style="padding-bottom: 0;" colspan="2">
|
142 |
+
<label for="moove_gdpr_modal_strictly_secondary_notice">
|
143 |
+
<?php esc_html_e( 'Strictly necessary required message.', 'gdpr-cookie-compliance' ); ?>
|
144 |
+
</label>
|
145 |
+
</th>
|
146 |
+
</tr>
|
147 |
+
<tr>
|
148 |
+
<td colspan="2" style="padding-left: 0;">
|
149 |
+
<?php
|
150 |
+
$content = isset( $gdpr_options[ 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ] ? $gdpr_options[ 'moove_gdpr_modal_strictly_secondary_notice' . $wpml_lang ] : $gdpr_default_content->moove_gdpr_get_secondary_notice();
|
151 |
+
$settings = array(
|
152 |
+
'media_buttons' => false,
|
153 |
+
'editor_height' => 100,
|
154 |
+
);
|
155 |
+
wp_editor( $content, 'moove_gdpr_modal_strictly_secondary_notice', $settings );
|
156 |
+
?>
|
157 |
+
<p class="description">
|
158 |
+
<?php esc_html_e( 'This warning message will be displayed if the Strictly necessary cookies are not enabled and the user try to enable the "Third Party" or "Additional cookies"', 'gdpr-cookie-compliance' ); ?>
|
159 |
+
</p>
|
160 |
+
</td>
|
161 |
+
</tr>
|
162 |
+
</tbody>
|
163 |
+
</table>
|
164 |
+
|
165 |
+
<hr />
|
166 |
+
<br />
|
167 |
+
<button type="submit" class="button button-primary"><?php esc_html_e( 'Save changes', 'gdpr-cookie-compliance' ); ?></button>
|
168 |
+
</form>
|
views/moove/admin/settings/strictly_necessary_cookies.php
DELETED
@@ -1,155 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
3 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
4 |
-
$gdpr_options = get_option( $option_name );
|
5 |
-
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
6 |
-
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
7 |
-
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
8 |
-
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
9 |
-
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
10 |
-
die( 'Security check' );
|
11 |
-
else :
|
12 |
-
if ( is_array( $_POST ) ) :
|
13 |
-
$value = 1;
|
14 |
-
if ( isset( $_POST['moove_gdpr_strictly_necessary_cookies_functionality'] ) && intval( $_POST['moove_gdpr_strictly_necessary_cookies_functionality'] ) ) :
|
15 |
-
$value = intval( $_POST['moove_gdpr_strictly_necessary_cookies_functionality'] );
|
16 |
-
endif;
|
17 |
-
|
18 |
-
$gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] = $value;
|
19 |
-
update_option( $option_name, $gdpr_options );
|
20 |
-
$gdpr_options = get_option( $option_name );
|
21 |
-
foreach ( $_POST as $form_key => $form_value ) :
|
22 |
-
if ( $form_key === 'moove_gdpr_strict_necessary_cookies_tab_content' ) :
|
23 |
-
$value = wp_unslash( $form_value );
|
24 |
-
$gdpr_options[$form_key.$wpml_lang] = $value;
|
25 |
-
update_option( $option_name, $gdpr_options );
|
26 |
-
$gdpr_options = get_option( $option_name );
|
27 |
-
elseif ( $form_key === 'moove_gdpr_modal_strictly_secondary_notice' ) :
|
28 |
-
$value = wpautop( wp_unslash( $form_value ) );
|
29 |
-
$gdpr_options[$form_key.$wpml_lang] = $value;
|
30 |
-
update_option( $option_name, $gdpr_options );
|
31 |
-
$gdpr_options = get_option( $option_name );
|
32 |
-
elseif ( $form_key === 'moove_gdpr_strictly_necessary_cookies_warning' ) :
|
33 |
-
$value = wp_unslash( $form_value );
|
34 |
-
$gdpr_options[$form_key.$wpml_lang] = $value;
|
35 |
-
update_option( $option_name, $gdpr_options );
|
36 |
-
$gdpr_options = get_option( $option_name );
|
37 |
-
elseif ( $form_key !== 'moove_gdpr_strictly_necessary_cookies_functionality' ) :
|
38 |
-
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
39 |
-
$gdpr_options[$form_key] = $value;
|
40 |
-
update_option( $option_name, $gdpr_options );
|
41 |
-
$gdpr_options = get_option( $option_name );
|
42 |
-
endif;
|
43 |
-
endforeach;
|
44 |
-
endif;
|
45 |
-
do_action('gdpr_cookie_filter_settings');
|
46 |
-
?>
|
47 |
-
<script>
|
48 |
-
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
49 |
-
</script>
|
50 |
-
<?php
|
51 |
-
endif;
|
52 |
-
endif;
|
53 |
-
?>
|
54 |
-
<?php
|
55 |
-
$nav_label = isset( $gdpr_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] ) && $gdpr_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] ? $gdpr_options['moove_gdpr_strictly_necessary_cookies_tab_title'.$wpml_lang] : __('Strictly Necessary Cookies','gdpr-cookie-compliance');
|
56 |
-
?>
|
57 |
-
<h2><?php echo $nav_label; ?></h2>
|
58 |
-
<hr />
|
59 |
-
<form action="?page=moove-gdpr&tab=strictly_necessary_cookies" method="post" id="moove_gdpr_tab_strictly_necessary_cookies">
|
60 |
-
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
61 |
-
<table class="form-table">
|
62 |
-
<tbody>
|
63 |
-
<tr>
|
64 |
-
<th scope="row">
|
65 |
-
<label for="moove_gdpr_strictly_necessary_cookies_functionality"><?php _e('Choose functionality','gdpr-cookie-compliance'); ?></label>
|
66 |
-
</th>
|
67 |
-
<td>
|
68 |
-
|
69 |
-
<input name="moove_gdpr_strictly_necessary_cookies_functionality" type="radio" value="1" id="moove_gdpr_strictly_necessary_cookies_functionality_1" <?php echo isset( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? ( intval( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) === 1 ? 'checked' : '' ) : 'checked'; ?> class="on-off"> <label for="moove_gdpr_strictly_necessary_cookies_functionality_1"><?php _e('Optional (user selects their preferences)','gdpr-cookie-compliance'); ?></label> <span class="separator"></span><br /><br />
|
70 |
-
|
71 |
-
<input name="moove_gdpr_strictly_necessary_cookies_functionality" type="radio" value="2" id="moove_gdpr_strictly_necessary_cookies_functionality_2" <?php echo isset( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? ( intval( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) === 2 ? 'checked' : '' ) : ''; ?> class="on-off"> <label for="moove_gdpr_strictly_necessary_cookies_functionality_2"><?php _e('Always enabled (user cannot disable it but can see the content)','gdpr-cookie-compliance'); ?></label><br /><br />
|
72 |
-
|
73 |
-
<input name="moove_gdpr_strictly_necessary_cookies_functionality" type="radio" value="3" id="moove_gdpr_strictly_necessary_cookies_functionality_3" <?php echo isset( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) ? ( intval( $gdpr_options['moove_gdpr_strictly_necessary_cookies_functionality'] ) === 3 ? 'checked' : '' ) : ''; ?> class="on-off"> <label for="moove_gdpr_strictly_necessary_cookies_functionality_3"><?php _e('Always enabled and content hidden from user','gdpr-cookie-compliance'); ?></label><br /><br />
|
74 |
-
</td>
|
75 |
-
</tr>
|
76 |
-
<tr>
|
77 |
-
<th scope="row">
|
78 |
-
<label for="moove_gdpr_strictly_necessary_cookies_tab_title"><?php _e('Tab Title','gdpr-cookie-compliance'); ?></label>
|
79 |
-
</th>
|
80 |
-
<td>
|
81 |
-
<input name="moove_gdpr_strictly_necessary_cookies_tab_title<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_strictly_necessary_cookies_tab_title" value="<?php echo $nav_label; ?>" class="regular-text">
|
82 |
-
</td>
|
83 |
-
</tr>
|
84 |
-
|
85 |
-
<tr>
|
86 |
-
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
87 |
-
<label for="moove_gdpr_strict_necessary_cookies_tab_content"><?php _e('Tab Content','gdpr-cookie-compliance'); ?></label>
|
88 |
-
</th>
|
89 |
-
</tr>
|
90 |
-
<tr class="moove_gdpr_table_form_holder">
|
91 |
-
<td colspan="2" scope="row" style="padding-left: 0;">
|
92 |
-
<?php
|
93 |
-
$content = isset( $gdpr_options['moove_gdpr_strict_necessary_cookies_tab_content'.$wpml_lang] ) && $gdpr_options['moove_gdpr_strict_necessary_cookies_tab_content'.$wpml_lang] ? wp_unslash( $gdpr_options['moove_gdpr_strict_necessary_cookies_tab_content'.$wpml_lang] ) : false;
|
94 |
-
if ( ! $content ) :
|
95 |
-
$content = $gdpr_default_content->moove_gdpr_get_strict_necessary_content();
|
96 |
-
endif;
|
97 |
-
?>
|
98 |
-
<?php
|
99 |
-
$settings = array (
|
100 |
-
'media_buttons' => false,
|
101 |
-
'editor_height' => 150,
|
102 |
-
);
|
103 |
-
wp_editor( $content, 'moove_gdpr_strict_necessary_cookies_tab_content', $settings );
|
104 |
-
?>
|
105 |
-
</td>
|
106 |
-
</tr>
|
107 |
-
|
108 |
-
<tr>
|
109 |
-
<th scope="row" style="padding-bottom: 0;" colspan="2">
|
110 |
-
<label for="moove_gdpr_strictly_necessary_cookies_warning"><?php _e('Tab Warning Message','gdpr-cookie-compliance'); ?></label>
|
111 |
-
</th>
|
112 |
-
</tr>
|
113 |
-
<tr>
|
114 |
-
<td style="padding-top: 10px; padding-left: 0;" colspan="2">
|
115 |
-
<?php $content = isset( $gdpr_options['moove_gdpr_strictly_necessary_cookies_warning'.$wpml_lang] ) && $gdpr_options['moove_gdpr_strictly_necessary_cookies_warning'.$wpml_lang] ? $gdpr_options['moove_gdpr_strictly_necessary_cookies_warning'.$wpml_lang] : $gdpr_default_content->moove_gdpr_get_strict_necessary_warning(); ?>
|
116 |
-
<?php
|
117 |
-
$settings = array (
|
118 |
-
'media_buttons' => false,
|
119 |
-
'editor_height' => 100,
|
120 |
-
);
|
121 |
-
wp_editor( $content, 'moove_gdpr_strictly_necessary_cookies_warning', $settings );
|
122 |
-
?>
|
123 |
-
<p class="description"><?php _e('This warning message will be displayed when user disables the Strictly Necessary Cookies.','gdpr-cookie-compliance'); ?></p>
|
124 |
-
</td>
|
125 |
-
</tr>
|
126 |
-
|
127 |
-
<tr>
|
128 |
-
<th scope="row" style="padding-bottom: 0;" colspan="2">
|
129 |
-
<label for="moove_gdpr_modal_strictly_secondary_notice"><?php _e('Strictly necessary required message.','gdpr-cookie-compliance'); ?></label>
|
130 |
-
</th>
|
131 |
-
</tr>
|
132 |
-
<tr>
|
133 |
-
<td colspan="2" style="padding-left: 0;">
|
134 |
-
<?php $content = isset( $gdpr_options['moove_gdpr_modal_strictly_secondary_notice'.$wpml_lang] ) && $gdpr_options['moove_gdpr_modal_strictly_secondary_notice'.$wpml_lang] ? $gdpr_options['moove_gdpr_modal_strictly_secondary_notice'.$wpml_lang] : $gdpr_default_content->moove_gdpr_get_secondary_notice() ; ?>
|
135 |
-
<?php
|
136 |
-
$settings = array (
|
137 |
-
'media_buttons' => false,
|
138 |
-
'editor_height' => 100,
|
139 |
-
);
|
140 |
-
wp_editor( $content, 'moove_gdpr_modal_strictly_secondary_notice', $settings );
|
141 |
-
?>
|
142 |
-
|
143 |
-
|
144 |
-
<p class="description"><?php _e('This warning message will be displayed if the Strictly necessary cookies are not enabled and the user try to enable the "Third Party" or "Additional cookies"','gdpr-cookie-compliance'); ?></p>
|
145 |
-
</td>
|
146 |
-
|
147 |
-
</tr>
|
148 |
-
|
149 |
-
</tbody>
|
150 |
-
</table>
|
151 |
-
|
152 |
-
<hr />
|
153 |
-
<br />
|
154 |
-
<button type="submit" class="button button-primary"><?php _e('Save changes','gdpr-cookie-compliance'); ?></button>
|
155 |
-
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
views/moove/admin/settings/third-party-cookies.php
ADDED
@@ -0,0 +1,280 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Third Party Cookies Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
$gdpr_default_content = new Moove_GDPR_Content();
|
11 |
+
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
12 |
+
$gdpr_options = get_option( $option_name );
|
13 |
+
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
14 |
+
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
15 |
+
$empty_scripts = false;
|
16 |
+
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
17 |
+
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
18 |
+
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
19 |
+
die( 'Security check' );
|
20 |
+
else :
|
21 |
+
if ( is_array( $_POST ) ) :
|
22 |
+
if ( isset( $_POST['moove_gdpr_third_party_cookies_enable'] ) ) :
|
23 |
+
$value = 1;
|
24 |
+
else :
|
25 |
+
$value = 0;
|
26 |
+
endif;
|
27 |
+
|
28 |
+
$gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] = 0;
|
29 |
+
if ( isset( $_POST['moove_gdpr_third_party_cookies_enable_first_visit'] ) ) :
|
30 |
+
$gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] = 1;
|
31 |
+
endif;
|
32 |
+
update_option( $option_name, $gdpr_options );
|
33 |
+
|
34 |
+
|
35 |
+
$gdpr_options['moove_gdpr_third_party_cookies_enable'] = $value;
|
36 |
+
update_option( $option_name, $gdpr_options );
|
37 |
+
$gdpr_options = get_option( $option_name );
|
38 |
+
|
39 |
+
foreach ( $_POST as $form_key => $form_value ) :
|
40 |
+
|
41 |
+
if ( 'moove_gdpr_performance_cookies_tab_content' === $form_key ) :
|
42 |
+
$value = wp_unslash( $form_value );
|
43 |
+
$gdpr_options[ $form_key . $wpml_lang ] = $value;
|
44 |
+
update_option( $option_name, $gdpr_options );
|
45 |
+
$gdpr_options = get_option( $option_name );
|
46 |
+
elseif ( 'moove_gdpr_third_party_header_scripts' === $form_key || 'moove_gdpr_third_party_body_scripts' === $form_key || 'moove_gdpr_third_party_footer_scripts' === $form_key ) :
|
47 |
+
$value = wp_unslash( $form_value );
|
48 |
+
$gdpr_options[ $form_key ] = maybe_serialize( $value );
|
49 |
+
update_option( $option_name, $gdpr_options );
|
50 |
+
$gdpr_options = get_option( $option_name );
|
51 |
+
elseif ( 'moove_gdpr_third_party_cookies_enable' !== $form_key && 'moove_gdpr_third_party_cookies_enable_first_visit' !== $form_key ) :
|
52 |
+
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
53 |
+
$gdpr_options[ $form_key ] = $value;
|
54 |
+
update_option( $option_name, $gdpr_options );
|
55 |
+
$gdpr_options = get_option( $option_name );
|
56 |
+
endif;
|
57 |
+
endforeach;
|
58 |
+
do_action( 'gdpr_ps_check_language_extensions', $empty_scripts, $_POST, 'third_party' );
|
59 |
+
do_action( 'gdpr_cookie_filter_settings' );
|
60 |
+
endif;
|
61 |
+
|
62 |
+
$gdpr_options = get_option( $option_name );
|
63 |
+
?>
|
64 |
+
|
65 |
+
<script>
|
66 |
+
jQuery('#moove-gdpr-setting-error-settings_scripts_empty').hide();
|
67 |
+
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
68 |
+
</script>
|
69 |
+
<?php
|
70 |
+
endif;
|
71 |
+
endif;
|
72 |
+
|
73 |
+
$nav_label = isset( $gdpr_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] ? $gdpr_options[ 'moove_gdpr_performance_cookies_tab_title' . $wpml_lang ] : __( '3rd Party Cookies', 'gdpr-cookie-compliance' );
|
74 |
+
?>
|
75 |
+
<h2><?php echo esc_attr( $nav_label ); ?></h2>
|
76 |
+
<hr />
|
77 |
+
<form action="<?php echo esc_url( admin_url( '?page=moove-gdpr&tab=third-party-cookies' ) ); ?>" method="post" id="moove_gdpr_tab_third_party_cookies">
|
78 |
+
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
79 |
+
<table class="form-table <?php echo $empty_scripts ? 'moove-gdpr-form-error' : ''; ?>">
|
80 |
+
<tbody>
|
81 |
+
<tr>
|
82 |
+
<th scope="row">
|
83 |
+
<label for="moove_gdpr_third_party_cookies_enable">
|
84 |
+
<?php esc_html_e( 'Turn', 'gdpr-cookie-compliance' ); ?>
|
85 |
+
</label>
|
86 |
+
</th>
|
87 |
+
<td>
|
88 |
+
<!-- GDPR Rounded switch -->
|
89 |
+
<label class="gdpr-checkbox-toggle">
|
90 |
+
<input type="checkbox" name="moove_gdpr_third_party_cookies_enable" id="moove_gdpr_third_party_cookies_enable" <?php echo isset( $gdpr_options['moove_gdpr_third_party_cookies_enable'] ) ? ( intval( $gdpr_options['moove_gdpr_third_party_cookies_enable'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_third_party_cookies_enable'] ) ? 'checked' : '' ) ) : ''; ?> >
|
91 |
+
<span class="gdpr-checkbox-slider" data-enable="<?php esc_html_e( 'On', 'gdpr-cookie-compliance' ); ?>" data-disable="<?php esc_html_e( 'Off', 'gdpr-cookie-compliance' ); ?>"></span>
|
92 |
+
</label>
|
93 |
+
</td>
|
94 |
+
</tr>
|
95 |
+
<tr>
|
96 |
+
<th scope="row">
|
97 |
+
<label for="moove_gdpr_third_party_cookies_enable_first_visit"><?php esc_html_e( 'Default status', 'gdpr-cookie-compliance' ); ?></label>
|
98 |
+
<p class="description"><?php esc_html_e( 'by default cookies should be', 'gdpr-cookie-compliance' ); ?>:</p>
|
99 |
+
<!-- .description -->
|
100 |
+
</th>
|
101 |
+
<td style="vertical-align: top; padding-top: 20px">
|
102 |
+
<!-- GDPR Rounded switch -->
|
103 |
+
<label class="gdpr-checkbox-toggle">
|
104 |
+
<input type="checkbox" name="moove_gdpr_third_party_cookies_enable_first_visit" id="moove_gdpr_third_party_cookies_enable_first_visit" <?php echo isset( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) ? ( intval( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) ? 'checked' : '' ) ) : ''; ?> >
|
105 |
+
<span class="gdpr-checkbox-slider" data-enable="<?php esc_html_e( 'Enabled', 'gdpr-cookie-compliance' ); ?>" data-disable="<?php esc_html_e( 'Disabled', 'gdpr-cookie-compliance' ); ?>"></span>
|
106 |
+
</label>
|
107 |
+
</td>
|
108 |
+
</tr>
|
109 |
+
|
110 |
+
<tr>
|
111 |
+
<th scope="row">
|
112 |
+
<label for="moove_gdpr_performance_cookies_tab_title">
|
113 |
+
<?php esc_html_e( 'Tab Title', 'gdpr-cookie-compliance' ); ?>
|
114 |
+
</label>
|
115 |
+
</th>
|
116 |
+
<td>
|
117 |
+
<input name="moove_gdpr_performance_cookies_tab_title<?php echo esc_attr( $wpml_lang ); ?>" type="text" id="moove_gdpr_performance_cookies_tab_title" value="<?php echo esc_attr( $nav_label ); ?>" class="regular-text">
|
118 |
+
</td>
|
119 |
+
</tr>
|
120 |
+
|
121 |
+
<tr>
|
122 |
+
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
123 |
+
<label for="moove_gdpr_performance_cookies_tab_content">
|
124 |
+
<?php esc_html_e( 'Tab Content', 'gdpr-cookie-compliance' ); ?>
|
125 |
+
</label>
|
126 |
+
</th>
|
127 |
+
</tr>
|
128 |
+
<tr class="moove_gdpr_table_form_holder">
|
129 |
+
<th colspan="2" scope="row">
|
130 |
+
<?php
|
131 |
+
$content = isset( $gdpr_options[ 'moove_gdpr_performance_cookies_tab_content' . $wpml_lang ] ) && $gdpr_options[ 'moove_gdpr_performance_cookies_tab_content' . $wpml_lang ] ? wp_unslash( $gdpr_options[ 'moove_gdpr_performance_cookies_tab_content' . $wpml_lang ] ) : false;
|
132 |
+
if ( ! $content ) :
|
133 |
+
$content = $gdpr_default_content->moove_gdpr_get_third_party_content();
|
134 |
+
endif;
|
135 |
+
|
136 |
+
$settings = array(
|
137 |
+
'media_buttons' => false,
|
138 |
+
'editor_height' => 150,
|
139 |
+
);
|
140 |
+
wp_editor( $content, 'moove_gdpr_performance_cookies_tab_content', $settings );
|
141 |
+
?>
|
142 |
+
</th>
|
143 |
+
</tr>
|
144 |
+
</tbody>
|
145 |
+
</table>
|
146 |
+
|
147 |
+
<div class="gdpr-script-tab-content">
|
148 |
+
<hr />
|
149 |
+
<h3><?php esc_html_e( 'Paste your codes and snippets below. They will be added to all pages if user enables these cookies.', 'gdpr-cookie-compliance' ); ?></h3>
|
150 |
+
<div class="alert script-error" style="display: none;"><?php esc_html_e( 'Please fill out at least one of these fields:', 'gdpr-cookie-compliance' ); ?></div>
|
151 |
+
|
152 |
+
<div class="gdpr-tab-code-section-nav">
|
153 |
+
<ul>
|
154 |
+
<li>
|
155 |
+
<a href="#third_party_head" class="gdpr-active">
|
156 |
+
<?php esc_html_e( 'Head Section', 'gdpr-cookie-compliance' ); ?>
|
157 |
+
</a>
|
158 |
+
</li>
|
159 |
+
<li>
|
160 |
+
<a href="#third_party_body">
|
161 |
+
<?php esc_html_e( 'Body Section', 'gdpr-cookie-compliance' ); ?>
|
162 |
+
</a>
|
163 |
+
</li>
|
164 |
+
<li>
|
165 |
+
<a href="#third_party_footer">
|
166 |
+
<?php esc_html_e( 'Footer Section', 'gdpr-cookie-compliance' ); ?>
|
167 |
+
</a>
|
168 |
+
</li>
|
169 |
+
<?php do_action( 'gdpr_tab_code_section_nav_extension', 'third_party' ); ?>
|
170 |
+
</ul>
|
171 |
+
</div>
|
172 |
+
<!-- .gdpr-tab-code-section-nav -->
|
173 |
+
<div class="gdpr-script-tabs-main-cnt">
|
174 |
+
|
175 |
+
<div class="gdpr-tab-code-section gdpr-active" id="third_party_head">
|
176 |
+
<h4 for="moove_gdpr_third_party_header_scripts"><?php esc_html_e( 'Add scripts that you would like to be inserted to the HEAD section of your pages when user accepts these cookies', 'gdpr-cookie-compliance' ); ?></h4>
|
177 |
+
<table>
|
178 |
+
<tbody>
|
179 |
+
<tr class="moove_gdpr_third_party_header_scripts">
|
180 |
+
<td scope="row" colspan="2" style="padding: 20px 0;">
|
181 |
+
<?php
|
182 |
+
$content = isset( $gdpr_options['moove_gdpr_third_party_header_scripts'] ) && $gdpr_options['moove_gdpr_third_party_header_scripts'] ? maybe_unserialize( $gdpr_options['moove_gdpr_third_party_header_scripts'] ) : '';
|
183 |
+
?>
|
184 |
+
<textarea name="moove_gdpr_third_party_header_scripts" id="moove_gdpr_third_party_header_scripts" class="large-text code" rows="13"><?php apply_filters( 'gdpr_cc_keephtml', $content, true ); ?></textarea>
|
185 |
+
<div class="gdpr-code"></div>
|
186 |
+
<!-- .gdpr-code -->
|
187 |
+
<p class="description" id="moove_gdpr_third_party_header_scripts-description">
|
188 |
+
<?php esc_html_e( 'For example, you can use it for Google Tag Manager script or any other 3rd party code snippets.', 'gdpr-cookie-compliance' ); ?>
|
189 |
+
</p>
|
190 |
+
</td>
|
191 |
+
</tr>
|
192 |
+
</tbody>
|
193 |
+
</table>
|
194 |
+
</div>
|
195 |
+
<!-- .gdpr-tab-code-section -->
|
196 |
+
|
197 |
+
<div class="gdpr-tab-code-section" id="third_party_body">
|
198 |
+
<h4 for="moove_gdpr_third_party_header_scripts"><?php esc_html_e( 'Add scripts that you would like to be inserted to the BODY section of your pages when user accepts these cookies', 'gdpr-cookie-compliance' ); ?></h4>
|
199 |
+
<table>
|
200 |
+
<tbody>
|
201 |
+
<tr class="moove_gdpr_third_party_body_scripts">
|
202 |
+
<td scope="row" colspan="2" style="padding: 20px 0;">
|
203 |
+
<?php
|
204 |
+
$content = isset( $gdpr_options['moove_gdpr_third_party_body_scripts'] ) && $gdpr_options['moove_gdpr_third_party_body_scripts'] ? maybe_unserialize( $gdpr_options['moove_gdpr_third_party_body_scripts'] ) : '';
|
205 |
+
?>
|
206 |
+
<textarea name="moove_gdpr_third_party_body_scripts" id="moove_gdpr_third_party_body_scripts" class="large-text code" rows="13"><?php apply_filters( 'gdpr_cc_keephtml', $content, true ); ?></textarea>
|
207 |
+
<div class="gdpr-code"></div>
|
208 |
+
<!-- .gdpr-code -->
|
209 |
+
<p class="description" id="moove_gdpr_third_party_body_scripts-description">
|
210 |
+
<?php esc_html_e( 'For example, you can use it for Google Tag Manager script or any other 3rd party code snippets.', 'gdpr-cookie-compliance' ); ?>
|
211 |
+
</p>
|
212 |
+
</td>
|
213 |
+
</tr>
|
214 |
+
</tbody>
|
215 |
+
</table>
|
216 |
+
</div>
|
217 |
+
<!-- .gdpr-tab-code-section -->
|
218 |
+
|
219 |
+
<div class="gdpr-tab-code-section" id="third_party_footer">
|
220 |
+
<h4 for="moove_gdpr_third_party_header_scripts"><?php esc_html_e( 'Add scripts that you would like to be inserted to the FOOTER section of your pages when user accepts these cookies', 'gdpr-cookie-compliance' ); ?></h4>
|
221 |
+
<table>
|
222 |
+
<tbody>
|
223 |
+
<tr class="moove_gdpr_third_party_footer_scripts">
|
224 |
+
<td scope="row" colspan="2" style="padding: 20px 0;">
|
225 |
+
<?php
|
226 |
+
$content = isset( $gdpr_options['moove_gdpr_third_party_footer_scripts'] ) && $gdpr_options['moove_gdpr_third_party_footer_scripts'] ? maybe_unserialize( $gdpr_options['moove_gdpr_third_party_footer_scripts'] ) : '';
|
227 |
+
?>
|
228 |
+
<textarea name="moove_gdpr_third_party_footer_scripts" id="moove_gdpr_third_party_footer_scripts" class="large-text code" rows="13"><?php apply_filters( 'gdpr_cc_keephtml', $content, true ); ?></textarea>
|
229 |
+
<div class="gdpr-code"></div>
|
230 |
+
<!-- .gdpr-code -->
|
231 |
+
<p class="description" id="moove_gdpr_third_party_footer_scripts-description">
|
232 |
+
<?php esc_html_e( 'For example, you can use it for Google Analytics script or any other 3rd party code snippets.', 'gdpr-cookie-compliance' ); ?>
|
233 |
+
</p>
|
234 |
+
</td>
|
235 |
+
</tr>
|
236 |
+
</tbody>
|
237 |
+
</table>
|
238 |
+
</div>
|
239 |
+
<!-- .gdpr-tab-code-section -->
|
240 |
+
|
241 |
+
<?php do_action( 'gdpr_tab_code_section_content_extension', 'third_party' ); ?>
|
242 |
+
</div>
|
243 |
+
<!-- .gdpr-script-tabs-main-cnt -->
|
244 |
+
</div>
|
245 |
+
<!-- .gdpr-script-tab-content -->
|
246 |
+
<br />
|
247 |
+
<hr />
|
248 |
+
<br />
|
249 |
+
<button type="submit" class="button button-primary">
|
250 |
+
<?php esc_html_e( 'Save changes', 'gdpr-cookie-compliance' ); ?>
|
251 |
+
</button>
|
252 |
+
<script type="text/javascript" src="<?php echo esc_url( moove_gdpr_get_plugin_directory_url() ); ?>/dist/scripts/codemirror.js"></script>
|
253 |
+
<script type="text/javascript">
|
254 |
+
window.onload = function() {
|
255 |
+
jQuery('.gdpr-tab-section-cnt textarea.code').each(function(){
|
256 |
+
if (typeof CodeMirror === "function") {
|
257 |
+
var element = jQuery(this).closest('tr').find('.gdpr-code')[0];
|
258 |
+
var id = jQuery(this).attr('id');
|
259 |
+
|
260 |
+
jQuery(this).css({
|
261 |
+
'opacity' : '0',
|
262 |
+
'height' : '0',
|
263 |
+
});
|
264 |
+
var editor = CodeMirror( element, {
|
265 |
+
mode: "text/html",
|
266 |
+
lineWrapping: true,
|
267 |
+
lineNumbers: true,
|
268 |
+
value: document.getElementById(id).value
|
269 |
+
});
|
270 |
+
editor.on('change',function(cMirror){
|
271 |
+
// get value right from instance
|
272 |
+
document.getElementById(id).innerHTML = cMirror.getValue();
|
273 |
+
});
|
274 |
+
} else {
|
275 |
+
jQuery('.gdpr-code').hide();
|
276 |
+
}
|
277 |
+
});
|
278 |
+
};
|
279 |
+
</script>
|
280 |
+
</form>
|
views/moove/admin/settings/third_party_cookies.php
DELETED
@@ -1,256 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
$gdpr_default_content = new Moove_GDPR_Content();
|
3 |
-
$option_name = $gdpr_default_content->moove_gdpr_get_option_name();
|
4 |
-
$gdpr_options = get_option( $option_name );
|
5 |
-
$wpml_lang = $gdpr_default_content->moove_gdpr_get_wpml_lang();
|
6 |
-
$gdpr_options = is_array( $gdpr_options ) ? $gdpr_options : array();
|
7 |
-
$empty_scripts = false;
|
8 |
-
if ( isset( $_POST ) && isset( $_POST['moove_gdpr_nonce'] ) ) :
|
9 |
-
$nonce = sanitize_key( $_POST['moove_gdpr_nonce'] );
|
10 |
-
if ( ! wp_verify_nonce( $nonce, 'moove_gdpr_nonce_field' ) ) :
|
11 |
-
die( 'Security check' );
|
12 |
-
else :
|
13 |
-
if ( is_array( $_POST ) ) :
|
14 |
-
if ( isset( $_POST['moove_gdpr_third_party_cookies_enable'] ) ) :
|
15 |
-
$value = 1;
|
16 |
-
else :
|
17 |
-
$value = 0;
|
18 |
-
endif;
|
19 |
-
|
20 |
-
$gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] = 0;
|
21 |
-
if ( isset( $_POST['moove_gdpr_third_party_cookies_enable_first_visit'] ) ) :
|
22 |
-
$gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] = 1;
|
23 |
-
endif;
|
24 |
-
update_option( $option_name, $gdpr_options );
|
25 |
-
|
26 |
-
|
27 |
-
$gdpr_options['moove_gdpr_third_party_cookies_enable'] = $value;
|
28 |
-
update_option( $option_name, $gdpr_options );
|
29 |
-
$gdpr_options = get_option( $option_name );
|
30 |
-
|
31 |
-
foreach ( $_POST as $form_key => $form_value ) :
|
32 |
-
|
33 |
-
if ( $form_key === 'moove_gdpr_performance_cookies_tab_content' ) :
|
34 |
-
$value = wp_unslash( $form_value );
|
35 |
-
$gdpr_options[$form_key.$wpml_lang] = $value;
|
36 |
-
update_option( $option_name, $gdpr_options );
|
37 |
-
$gdpr_options = get_option( $option_name );
|
38 |
-
elseif ( $form_key === 'moove_gdpr_third_party_header_scripts' || $form_key === 'moove_gdpr_third_party_body_scripts' || $form_key === 'moove_gdpr_third_party_footer_scripts' ) :
|
39 |
-
$value = wp_unslash( $form_value );
|
40 |
-
$gdpr_options[$form_key] = maybe_serialize( $value );
|
41 |
-
update_option( $option_name, $gdpr_options );
|
42 |
-
$gdpr_options = get_option( $option_name );
|
43 |
-
elseif ( $form_key !== 'moove_gdpr_third_party_cookies_enable' && $form_key !== 'moove_gdpr_third_party_cookies_enable_first_visit' ) :
|
44 |
-
$value = sanitize_text_field( wp_unslash( $form_value ) );
|
45 |
-
$gdpr_options[$form_key] = $value;
|
46 |
-
update_option( $option_name, $gdpr_options );
|
47 |
-
$gdpr_options = get_option( $option_name );
|
48 |
-
endif;
|
49 |
-
endforeach;
|
50 |
-
|
51 |
-
|
52 |
-
do_action( 'gdpr_ps_check_language_extensions', $empty_scripts, $_POST, 'third_party' );
|
53 |
-
do_action('gdpr_cookie_filter_settings');
|
54 |
-
endif;
|
55 |
-
|
56 |
-
$gdpr_options = get_option( $option_name );
|
57 |
-
?>
|
58 |
-
|
59 |
-
<script>
|
60 |
-
jQuery('#moove-gdpr-setting-error-settings_scripts_empty').hide();
|
61 |
-
jQuery('#moove-gdpr-setting-error-settings_updated').show();
|
62 |
-
</script>
|
63 |
-
<?php
|
64 |
-
endif;
|
65 |
-
endif;
|
66 |
-
|
67 |
-
?>
|
68 |
-
<?php
|
69 |
-
$nav_label = isset( $gdpr_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] ) && $gdpr_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] ? $gdpr_options['moove_gdpr_performance_cookies_tab_title'.$wpml_lang] : __('3rd Party Cookies','gdpr-cookie-compliance');
|
70 |
-
?>
|
71 |
-
<h2><?php echo $nav_label; ?></h2>
|
72 |
-
<hr />
|
73 |
-
<form action="?page=moove-gdpr&tab=third_party_cookies" method="post" id="moove_gdpr_tab_third_party_cookies">
|
74 |
-
<?php wp_nonce_field( 'moove_gdpr_nonce_field', 'moove_gdpr_nonce' ); ?>
|
75 |
-
<table class="form-table <?php echo $empty_scripts ? 'moove-gdpr-form-error' : ''; ?>">
|
76 |
-
<tbody>
|
77 |
-
<tr>
|
78 |
-
<th scope="row">
|
79 |
-
<label for="moove_gdpr_third_party_cookies_enable"><?php _e('Turn','gdpr-cookie-compliance'); ?></label>
|
80 |
-
</th>
|
81 |
-
<td>
|
82 |
-
<!-- GDPR Rounded switch -->
|
83 |
-
<label class="gdpr-checkbox-toggle">
|
84 |
-
<input type="checkbox" name="moove_gdpr_third_party_cookies_enable" id="moove_gdpr_third_party_cookies_enable" <?php echo isset( $gdpr_options['moove_gdpr_third_party_cookies_enable'] ) ? ( intval( $gdpr_options['moove_gdpr_third_party_cookies_enable'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_third_party_cookies_enable'] ) ? 'checked' : '' ) ) : ''; ?> >
|
85 |
-
<span class="gdpr-checkbox-slider" data-enable="<?php _e('On','gdpr-cookie-compliance'); ?>" data-disable="<?php _e('Off','gdpr-cookie-compliance'); ?>"></span>
|
86 |
-
</label>
|
87 |
-
</td>
|
88 |
-
</tr>
|
89 |
-
|
90 |
-
<tr>
|
91 |
-
<th scope="row">
|
92 |
-
<label for="moove_gdpr_third_party_cookies_enable_first_visit"><?php _e('Default status','gdpr-cookie-compliance'); ?></label>
|
93 |
-
<p class="description"><?php _e('by default cookies should be','gdpr-cookie-compliance'); ?>:</p>
|
94 |
-
<!-- .description -->
|
95 |
-
</th>
|
96 |
-
<td style="vertical-align: top; padding-top: 20px">
|
97 |
-
<!-- GDPR Rounded switch -->
|
98 |
-
<label class="gdpr-checkbox-toggle">
|
99 |
-
<input type="checkbox" name="moove_gdpr_third_party_cookies_enable_first_visit" id="moove_gdpr_third_party_cookies_enable_first_visit" <?php echo isset( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) ? ( intval( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) === 1 ? 'checked' : ( ! isset( $gdpr_options['moove_gdpr_third_party_cookies_enable_first_visit'] ) ? 'checked' : '' ) ) : ''; ?> >
|
100 |
-
<span class="gdpr-checkbox-slider" data-enable="<?php _e('Enabled','gdpr-cookie-compliance'); ?>" data-disable="<?php _e('Disabled','gdpr-cookie-compliance'); ?>"></span>
|
101 |
-
</label>
|
102 |
-
</td>
|
103 |
-
</tr>
|
104 |
-
|
105 |
-
<tr>
|
106 |
-
<th scope="row">
|
107 |
-
<label for="moove_gdpr_performance_cookies_tab_title"><?php _e('Tab Title','gdpr-cookie-compliance'); ?></label>
|
108 |
-
</th>
|
109 |
-
<td>
|
110 |
-
<input name="moove_gdpr_performance_cookies_tab_title<?php echo $wpml_lang; ?>" type="text" id="moove_gdpr_performance_cookies_tab_title" value="<?php echo $nav_label; ?>" class="regular-text">
|
111 |
-
</td>
|
112 |
-
</tr>
|
113 |
-
|
114 |
-
<tr>
|
115 |
-
<th scope="row" colspan="2" style="padding-bottom: 0;">
|
116 |
-
<label for="moove_gdpr_performance_cookies_tab_content"><?php _e('Tab Content','gdpr-cookie-compliance'); ?></label>
|
117 |
-
</th>
|
118 |
-
</tr>
|
119 |
-
<tr class="moove_gdpr_table_form_holder">
|
120 |
-
<th colspan="2" scope="row">
|
121 |
-
<?php
|
122 |
-
$content = isset( $gdpr_options['moove_gdpr_performance_cookies_tab_content'.$wpml_lang] ) && $gdpr_options['moove_gdpr_performance_cookies_tab_content'.$wpml_lang] ? wp_unslash( $gdpr_options['moove_gdpr_performance_cookies_tab_content'.$wpml_lang] ) : false;
|
123 |
-
if ( ! $content ) :
|
124 |
-
$content = $gdpr_default_content->moove_gdpr_get_third_party_content();
|
125 |
-
endif;
|
126 |
-
?>
|
127 |
-
<?php
|
128 |
-
$settings = array (
|
129 |
-
'media_buttons' => false,
|
130 |
-
'editor_height' => 150,
|
131 |
-
);
|
132 |
-
wp_editor( $content, 'moove_gdpr_performance_cookies_tab_content', $settings );
|
133 |
-
?>
|
134 |
-
</th>
|
135 |
-
</tr>
|
136 |
-
</tbody>
|
137 |
-
</table>
|
138 |
-
|
139 |
-
<div class="gdpr-script-tab-content">
|
140 |
-
<hr />
|
141 |
-
<h3><?php _e('Paste your codes and snippets below. They will be added to all pages if user enables these cookies.','gdpr-cookie-compliance'); ?></h3>
|
142 |
-
<div class="alert script-error" style="display: none;"><?php _e('Please fill out at least one of these fields:','gdpr-cookie-compliance'); ?></div>
|
143 |
-
|
144 |
-
<div class="gdpr-tab-code-section-nav">
|
145 |
-
<ul>
|
146 |
-
<li>
|
147 |
-
<a href="#third_party_head" class="gdpr-active"><?php _e('Head Section','gdpr-cookie-compliance'); ?></a>
|
148 |
-
</li>
|
149 |
-
<li>
|
150 |
-
<a href="#third_party_body"><?php _e('Body Section','gdpr-cookie-compliance'); ?></a>
|
151 |
-
</li>
|
152 |
-
<li>
|
153 |
-
<a href="#third_party_footer"><?php _e('Footer Section','gdpr-cookie-compliance'); ?></a>
|
154 |
-
</li>
|
155 |
-
<?php do_action('gdpr_tab_code_section_nav_extension', 'third_party'); ?>
|
156 |
-
</ul>
|
157 |
-
</div>
|
158 |
-
<!-- .gdpr-tab-code-section-nav -->
|
159 |
-
<div class="gdpr-script-tabs-main-cnt">
|
160 |
-
|
161 |
-
<div class="gdpr-tab-code-section gdpr-active" id="third_party_head">
|
162 |
-
<h4 for="moove_gdpr_third_party_header_scripts"><?php _e('Add scripts that you would like to be inserted to the HEAD section of your pages when user accepts these cookies','gdpr-cookie-compliance'); ?></h4>
|
163 |
-
<table>
|
164 |
-
<tbody>
|
165 |
-
<tr class="moove_gdpr_third_party_header_scripts">
|
166 |
-
<td scope="row" colspan="2" style="padding: 20px 0;">
|
167 |
-
<?php $content = isset( $gdpr_options['moove_gdpr_third_party_header_scripts'] ) && $gdpr_options['moove_gdpr_third_party_header_scripts'] ? maybe_unserialize( $gdpr_options['moove_gdpr_third_party_header_scripts'] ) : '';
|
168 |
-
?>
|
169 |
-
<textarea name="moove_gdpr_third_party_header_scripts" id="moove_gdpr_third_party_header_scripts" class="large-text code" rows="13"><?php echo $content; ?></textarea>
|
170 |
-
<div class="gdpr-code"></div>
|
171 |
-
<!-- .gdpr-code -->
|
172 |
-
<p class="description" id="moove_gdpr_third_party_header_scripts-description"><?php _e('For example, you can use it for Google Tag Manager script or any other 3rd party code snippets.','gdpr-cookie-compliance'); ?></p>
|
173 |
-
</td>
|
174 |
-
</tr>
|
175 |
-
</tbody>
|
176 |
-
</table>
|
177 |
-
</div>
|
178 |
-
<!-- .gdpr-tab-code-section -->
|
179 |
-
|
180 |
-
<div class="gdpr-tab-code-section" id="third_party_body">
|
181 |
-
<h4 for="moove_gdpr_third_party_header_scripts"><?php _e('Add scripts that you would like to be inserted to the BODY section of your pages when user accepts these cookies','gdpr-cookie-compliance'); ?></h4>
|
182 |
-
<table>
|
183 |
-
<tbody>
|
184 |
-
<tr class="moove_gdpr_third_party_body_scripts">
|
185 |
-
<td scope="row" colspan="2" style="padding: 20px 0;">
|
186 |
-
<?php $content = isset( $gdpr_options['moove_gdpr_third_party_body_scripts'] ) && $gdpr_options['moove_gdpr_third_party_body_scripts'] ? maybe_unserialize( $gdpr_options['moove_gdpr_third_party_body_scripts'] ) : '';
|
187 |
-
?>
|
188 |
-
<textarea name="moove_gdpr_third_party_body_scripts" id="moove_gdpr_third_party_body_scripts" class="large-text code" rows="13"><?php echo $content; ?></textarea>
|
189 |
-
<div class="gdpr-code"></div>
|
190 |
-
<!-- .gdpr-code -->
|
191 |
-
<p class="description" id="moove_gdpr_third_party_body_scripts-description"><?php _e('For example, you can use it for Google Tag Manager script or any other 3rd party code snippets.','gdpr-cookie-compliance'); ?></p>
|
192 |
-
</td>
|
193 |
-
</tr>
|
194 |
-
</tbody>
|
195 |
-
</table>
|
196 |
-
</div>
|
197 |
-
<!-- .gdpr-tab-code-section -->
|
198 |
-
|
199 |
-
<div class="gdpr-tab-code-section" id="third_party_footer">
|
200 |
-
<h4 for="moove_gdpr_third_party_header_scripts"><?php _e('Add scripts that you would like to be inserted to the FOOTER section of your pages when user accepts these cookies','gdpr-cookie-compliance'); ?></h4>
|
201 |
-
<table>
|
202 |
-
<tbody>
|
203 |
-
<tr class="moove_gdpr_third_party_footer_scripts">
|
204 |
-
<td scope="row" colspan="2" style="padding: 20px 0;">
|
205 |
-
<?php $content = isset( $gdpr_options['moove_gdpr_third_party_footer_scripts'] ) && $gdpr_options['moove_gdpr_third_party_footer_scripts'] ? maybe_unserialize( $gdpr_options['moove_gdpr_third_party_footer_scripts'] ) : '';
|
206 |
-
?>
|
207 |
-
<textarea name="moove_gdpr_third_party_footer_scripts" id="moove_gdpr_third_party_footer_scripts" class="large-text code" rows="13"><?php echo $content; ?></textarea>
|
208 |
-
<div class="gdpr-code"></div>
|
209 |
-
<!-- .gdpr-code -->
|
210 |
-
<p class="description" id="moove_gdpr_third_party_footer_scripts-description"><?php _e('For example, you can use it for Google Analytics script or any other 3rd party code snippets.','gdpr-cookie-compliance'); ?></p>
|
211 |
-
</td>
|
212 |
-
</tr>
|
213 |
-
</tbody>
|
214 |
-
</table>
|
215 |
-
</div>
|
216 |
-
<!-- .gdpr-tab-code-section -->
|
217 |
-
|
218 |
-
<?php do_action('gdpr_tab_code_section_content_extension', 'third_party'); ?>
|
219 |
-
</div>
|
220 |
-
<!-- .gdpr-script-tabs-main-cnt -->
|
221 |
-
</div>
|
222 |
-
<!-- .gdpr-script-tab-content -->
|
223 |
-
<br />
|
224 |
-
<hr />
|
225 |
-
<br />
|
226 |
-
<button type="submit" class="button button-primary"><?php _e('Save changes','gdpr-cookie-compliance'); ?></button>
|
227 |
-
|
228 |
-
<script type="text/javascript" src="<?php echo moove_gdpr_get_plugin_directory_url(); ?>/dist/scripts/codemirror.js"></script>
|
229 |
-
<script type="text/javascript">
|
230 |
-
window.onload = function() {
|
231 |
-
jQuery('.gdpr-tab-section-cnt textarea.code').each(function(){
|
232 |
-
if (typeof CodeMirror === "function") {
|
233 |
-
var element = jQuery(this).closest('tr').find('.gdpr-code')[0];
|
234 |
-
var id = jQuery(this).attr('id');
|
235 |
-
|
236 |
-
jQuery(this).css({
|
237 |
-
'opacity' : '0',
|
238 |
-
'height' : '0',
|
239 |
-
});
|
240 |
-
var editor = CodeMirror( element, {
|
241 |
-
mode: "text/html",
|
242 |
-
lineWrapping: true,
|
243 |
-
lineNumbers: true,
|
244 |
-
value: document.getElementById(id).value
|
245 |
-
});
|
246 |
-
editor.on('change',function(cMirror){
|
247 |
-
// get value right from instance
|
248 |
-
document.getElementById(id).innerHTML = cMirror.getValue();
|
249 |
-
});
|
250 |
-
} else {
|
251 |
-
jQuery('.gdpr-code').hide();
|
252 |
-
}
|
253 |
-
});
|
254 |
-
};
|
255 |
-
</script>
|
256 |
-
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
views/moove/admin/settings/video-tutorial.php
CHANGED
@@ -1,6 +1,16 @@
|
|
1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
<hr />
|
3 |
<div class="gdpr-video-tutorial-content">
|
4 |
-
|
5 |
</div>
|
6 |
-
<!-- .gdpr-video-tutorial-content -->
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Third Party Cookies Doc Comment
|
4 |
+
*
|
5 |
+
* @category Views
|
6 |
+
* @package gdpr-cookie-compliance
|
7 |
+
* @author Gaspar Nemes
|
8 |
+
*/
|
9 |
+
|
10 |
+
?>
|
11 |
+
<h2><?php esc_html_e( 'Video Tutorial', 'gdpr-cookie-compliance-addon' ); ?></h2>
|
12 |
<hr />
|
13 |
<div class="gdpr-video-tutorial-content">
|
14 |
+
<iframe src="https://player.vimeo.com/video/255655268" width="640" height="360" frameborder="0" title="GDPR Cookie Compliance - WordPress Plugin by Moove Agency" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>
|
15 |
</div>
|
16 |
+
<!-- .gdpr-video-tutorial-content -->
|