Cookiebot | GDPR Compliant Cookie Consent and Notice - Version 4.2.1

Version Description

Download this release

Release Info

Developer cookiebot
Plugin Icon 128x128 Cookiebot | GDPR Compliant Cookie Consent and Notice
Version 4.2.1
Comparing to
See all releases

Code changes from version 4.1.1 to 4.2.1

Files changed (86) hide show
  1. README.md +1 -1
  2. assets/css/backend/addons_page.css +347 -0
  3. assets/css/backend/cookiebot_admin_main.css +324 -0
  4. assets/css/backend/dashboard_page.css +279 -0
  5. assets/css/backend/debug_info.css +52 -0
  6. assets/css/backend/multiple_page.css +142 -0
  7. assets/css/backend/settings-page.css +206 -0
  8. assets/css/backend/support_page.css +123 -0
  9. assets/fonts/Inter-VariableFont.woff2 +0 -0
  10. assets/img/cb-wp.png +0 -0
  11. assets/img/europe.png +0 -0
  12. assets/img/existing-account.png +0 -0
  13. assets/img/extra/sale-black.jpg +0 -0
  14. assets/img/icons/check.svg +3 -0
  15. assets/img/icons/clock.svg +3 -0
  16. assets/img/icons/dashboard.svg +3 -0
  17. assets/img/icons/debug.svg +3 -0
  18. assets/img/icons/down.svg +3 -0
  19. assets/img/icons/link.svg +3 -0
  20. assets/img/icons/plugins.svg +3 -0
  21. assets/img/icons/settings.svg +3 -0
  22. assets/img/icons/support.svg +3 -0
  23. assets/img/new-account.png +0 -0
  24. assets/img/usa.png +0 -0
  25. assets/js/backend/multiple-page.js +91 -0
  26. assets/js/backend/network-settings-page.js +12 -0
  27. assets/js/backend/prior-consent-settings.js +16 -0
  28. assets/js/backend/settings-page.js +42 -2
  29. assets/js/backend/support-page.js +11 -0
  30. cookiebot.php +4 -4
  31. logo.svg +39 -0
  32. readme.txt +127 -95
  33. src/addons/config/Settings_Config.php +61 -22
  34. src/addons/controller/addons/Base_Cookiebot_Addon.php +4 -3
  35. src/addons/controller/addons/add_to_any/Add_To_Any.php +3 -3
  36. src/addons/controller/addons/caos_host_analyticsjs_local/CAOS_Host_Analyticsjs_Local_Version_1_97.php +1 -1
  37. src/addons/controller/addons/caos_host_analyticsjs_local/CAOS_Host_Analyticsjs_Local_Version_4_2_6.php +1 -1
  38. src/addons/controller/addons/custom_facebook_feed_pro/Custom_Facebook_Feed_Pro.php +1 -1
  39. src/addons/controller/addons/embed_autocorrect/Embed_Autocorrect.php +15 -14
  40. src/addons/controller/addons/facebook_for_woocommerce/Facebook_For_Woocommerce.php +1 -1
  41. src/addons/controller/addons/ga_google_analytics/Ga_Google_Analytics.php +1 -1
  42. src/addons/controller/addons/jetpack/Jetpack.php +1 -0
  43. src/addons/controller/addons/jetpack/widget/Base_Jetpack_Widget.php +3 -3
  44. src/addons/controller/addons/jetpack/widget/Visitor_Cookies_Jetpack_Widget.php +2 -0
  45. src/addons/controller/addons/litespeed_cache/Litespeed_Cache.php +1 -1
  46. src/addons/controller/addons/wp_google_analytics_events/Wp_Google_Analytics_Events.php +1 -0
  47. src/addons/controller/addons/wp_mautic/Wp_Mautic.php +1 -1
  48. src/addons/controller/addons/wp_rocket/Wp_Rocket.php +1 -1
  49. src/addons/controller/addons/wpforms/Wpforms.php +1 -1
  50. src/lib/Cookiebot_WP.php +14 -1
  51. src/lib/Supported_Regions.php +264 -0
  52. src/settings/Menu_Settings.php +13 -10
  53. src/settings/Network_Menu_Settings.php +14 -7
  54. src/settings/pages/Dashboard_Page.php +71 -0
  55. src/settings/pages/Debug_Page.php +19 -2
  56. src/settings/pages/Gtm_Page.php +1 -17
  57. src/settings/pages/Multiple_Page.php +81 -0
  58. src/settings/pages/Settings_Page.php +5 -14
  59. src/settings/pages/Settings_Page_Interface.php +0 -1
  60. src/settings/pages/Support_Page.php +32 -1
  61. src/settings/templates/Header.php +35 -0
  62. src/settings/templates/Main_Tabs.php +21 -0
  63. src/view/admin/settings/dashboard-page.php +113 -0
  64. src/view/admin/settings/debug-page.php +60 -27
  65. src/view/admin/settings/gtm-page.php +50 -65
  66. src/view/admin/settings/iab-page.php +17 -30
  67. src/view/admin/settings/multiple-configuration/page.php +87 -0
  68. src/view/admin/settings/network-settings-page.php +268 -283
  69. src/view/admin/settings/prior-consent/available-addons/tab-header.php +7 -0
  70. src/view/admin/settings/prior-consent/available-addons/tab.php +19 -18
  71. src/view/admin/settings/prior-consent/jetpack-widgets/tab-header.php +18 -1
  72. src/view/admin/settings/prior-consent/jetpack-widgets/tab.php +1 -1
  73. src/view/admin/settings/prior-consent/other-addons/embed-autocorrect-extra-addon-options.php +3 -3
  74. src/view/admin/settings/prior-consent/page.php +60 -44
  75. src/view/admin/settings/prior-consent/partials/extra-information.php +1 -1
  76. src/view/admin/settings/prior-consent/partials/info-tab-header.php +8 -0
  77. src/view/admin/settings/prior-consent/partials/placeholder-submitbox-default.php +1 -1
  78. src/view/admin/settings/prior-consent/partials/placeholder-submitboxes.php +7 -7
  79. src/view/admin/settings/prior-consent/unavailable-addons/field.php +1 -1
  80. src/view/admin/settings/prior-consent/unavailable-addons/tab-header.php +8 -1
  81. src/view/admin/settings/settings-page.php +423 -555
  82. src/view/admin/settings/support-page.php +213 -133
  83. src/view/admin/templates/header.php +20 -0
  84. src/view/admin/templates/main-tabs.php +55 -0
  85. src/view/frontend/scripts/cookiebot-js.php +2 -2
  86. src/view/frontend/scripts/google-consent-mode-js.php +14 -3
README.md CHANGED
@@ -1,4 +1,4 @@
1
- # Cookiebot WordPress Plugin
2
  Cookiebot Wordpress plugin is a plugin that make other plugins compatible with Cookiebot.
3
  The addons hook into the original plugin and render the cookie setting tags as advised by the Cookiebot guidelines at https://www.cookiebot.com/goto/help/.
4
 
1
+ # Cookiebot CMP WordPress Plugin
2
  Cookiebot Wordpress plugin is a plugin that make other plugins compatible with Cookiebot.
3
  The addons hook into the original plugin and render the cookie setting tags as advised by the Cookiebot guidelines at https://www.cookiebot.com/goto/help/.
4
 
assets/css/backend/addons_page.css ADDED
@@ -0,0 +1,347 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .cb-settings__header {
2
+ display: grid;
3
+ grid-template-columns: 3fr 1fr;
4
+ align-items: start;
5
+ }
6
+
7
+ .cb-settings__header .cb-main__page_title {
8
+ margin: 0;
9
+ }
10
+
11
+ .cb-settings__header p.submit {
12
+ text-align: right;
13
+ margin: 0;
14
+ padding: 0;
15
+ }
16
+
17
+ .cb-settings__header p.submit #submit {
18
+ background-color: rgba(0, 0, 0, 0.16);
19
+ color: #666666;
20
+ padding: 10px 20px;
21
+ font-size: 16px;
22
+ border: none;
23
+ pointer-events: none;
24
+ }
25
+
26
+ .cb-settings__header p.submit #submit.enabled{
27
+ background-color: #076646;
28
+ color: #ffffff;
29
+ pointer-events: initial;
30
+ }
31
+
32
+ .cb-settings__tabs {
33
+ display: grid;
34
+ grid-template-columns: repeat(4, minmax(180px, max-content));
35
+ margin: 25px 0 50px;
36
+ border-bottom: 1px solid #e1e1e1;
37
+ }
38
+
39
+ .cb-settings__tabs__item {
40
+ display: grid;
41
+ float: none;
42
+ background: transparent;
43
+ margin: 0;
44
+ padding: 15px 10px;
45
+ align-items: center;
46
+ border: none;
47
+ border-bottom: 3px solid transparent;
48
+ color: #141414;
49
+ font-size: 16px;
50
+ font-weight: 600;
51
+ text-align: center;
52
+ line-height: initial;
53
+ cursor: pointer;
54
+ }
55
+
56
+ .cb-settings__tabs__item.nav-tab-active:hover {
57
+ background: transparent;
58
+ color: #141414;
59
+ border-bottom-width: 3px;
60
+ }
61
+
62
+ .cb-settings__tabs__item.nav-tab-active, .cb-settings__tabs__item:hover {
63
+ color: #141414;
64
+ border-color: #1032cf;
65
+ }
66
+
67
+ .cb-settings__tabs__content--item .submit {
68
+ padding: 0;
69
+ margin: 0;
70
+ text-align: right;
71
+ }
72
+
73
+ .cb-settings__tabs__content--item #submit {
74
+ background-color: rgba(0, 0, 0, 0.16);
75
+ color: #666666;
76
+ padding: 10px 20px;
77
+ font-size: 16px;
78
+ border: none;
79
+ pointer-events: none;
80
+ }
81
+
82
+ .cb-settings__tabs__content--item #submit.enabled{
83
+ background-color: #076646;
84
+ color: #ffffff;
85
+ pointer-events: initial;
86
+ }
87
+
88
+ .cb-addons__tab__header {
89
+ display: grid;
90
+ grid-row-gap: 20px;
91
+ margin-bottom: 50px;
92
+ }
93
+
94
+ .cb-addons__tab__title {
95
+ font-size: 22px;
96
+ font-weight: 700;
97
+ margin: 0 0 20px;
98
+ }
99
+
100
+ .cb-addons__tab__text {
101
+ font-size: 16px;
102
+ line-height: 24px;
103
+ }
104
+
105
+ .cb-addons__header__column--inner {
106
+ background-color: #efefef;
107
+ border-radius: 15px;
108
+ padding: 25px;
109
+ }
110
+
111
+ .cb-addons__header__column.submit-column {
112
+ display: grid;
113
+ grid-template-columns: 1fr 1fr;
114
+ }
115
+
116
+ .cb-addons__tab__subtitle {
117
+ font-size: 15px;
118
+ margin: 0;
119
+ }
120
+
121
+ .form-table th {
122
+ width: 50%;
123
+ }
124
+
125
+ .plugin-title {
126
+ font-size: 20px;
127
+ font-weight: 600;
128
+ line-height: 29px;
129
+ }
130
+
131
+ .extra_information p {
132
+ font-size: 15px;
133
+ font-weight: 400;
134
+ line-height: 24px;
135
+ color: #141414;
136
+ }
137
+
138
+ .postbox.cookiebot-addon {
139
+ border: none;
140
+ background-color: #F2F2F2;
141
+ padding: 25px;
142
+ border-radius: 15px;
143
+ }
144
+
145
+ .postbox.cookiebot-addon > p {
146
+ font-size: 16px;
147
+ line-height: 24px;
148
+ }
149
+
150
+ .cookiebot-addon-enable {
151
+ padding-bottom: 20px;
152
+ border-bottom: 1px solid #d3d3d3;
153
+ margin-bottom: 20px;
154
+ }
155
+
156
+ .cookiebot-addon-enable label.switch-checkbox {
157
+ font-size: 16px;
158
+ line-height: 20px;
159
+ font-weight: 500;
160
+ color: #141414;
161
+ }
162
+
163
+ .cookiebot-addon .cookiebot-addon-text {
164
+ font-size: 16px;
165
+ line-height: 20px;
166
+ font-weight: 500;
167
+ color: #141414;
168
+ }
169
+
170
+ .cookiebot-addon .cookietypes {
171
+ margin-bottom: 30px;
172
+ }
173
+
174
+ .cookiebot-addon .cookietypes li {
175
+ margin: 20px 0px;
176
+ }
177
+
178
+ .cookiebot-addon .cookiebot-addon-placeholder {
179
+ margin: 20px 0 25px;
180
+ }
181
+
182
+ .cookiebot-addon .placeholder {
183
+ padding: 16px 24px;
184
+ background: rgba(255, 255, 255, 0.5);
185
+ border-radius: 8px;
186
+ }
187
+
188
+ .placeholder_title {
189
+ display: block;
190
+ font-size: 16px;
191
+ line-height: 20px;
192
+ font-weight: 500;
193
+ color: #141414;
194
+ margin-bottom: 16px;
195
+ }
196
+
197
+ select.placeholder_select_language {
198
+ width: 100%;
199
+ border: 2px solid #d3d3d3;
200
+ border-radius: 7px;
201
+ padding: 8px 15px;
202
+ max-width: initial;
203
+ margin-bottom: 25px;
204
+ }
205
+
206
+ .placeholder_textarea {
207
+ width: 100%;
208
+ border: 2px solid #d3d3d3;
209
+ border-radius: 7px;
210
+ padding: 8px 15px;
211
+ }
212
+
213
+ /**
214
+ * Help Tip
215
+ */
216
+ .help-tip {
217
+ color: #666;
218
+ display: inline-block;
219
+ font-size: 1.5em;
220
+ font-style: normal;
221
+ height: 16px;
222
+ line-height: 16px;
223
+ position: relative;
224
+ vertical-align: middle;
225
+ width: 16px
226
+ }
227
+
228
+ .help-tip::after {
229
+ font-family: Dashicons;
230
+ speak: none;
231
+ font-weight: 400;
232
+ font-variant: normal;
233
+ text-transform: none;
234
+ line-height: 1;
235
+ -webkit-font-smoothing: antialiased;
236
+ margin: 0;
237
+ text-indent: 0;
238
+ position: absolute;
239
+ top: 0;
240
+ left: 0;
241
+ width: 100%;
242
+ height: 100%;
243
+ text-align: center;
244
+ content: "";
245
+ cursor: help
246
+ }
247
+
248
+ #tiptip_holder{
249
+ position: absolute;
250
+ top: 0;
251
+ }
252
+
253
+ #tiptip_holder.tip_top {
254
+ padding-bottom: 5px
255
+ }
256
+
257
+ #tiptip_holder.tip_top #tiptip_arrow_inner {
258
+ margin-top: -7px;
259
+ margin-left: -6px;
260
+ border-top-color: #333
261
+ }
262
+
263
+ #tiptip_holder.tip_bottom {
264
+ padding-top: 5px
265
+ }
266
+
267
+ #tiptip_holder.tip_bottom #tiptip_arrow_inner {
268
+ margin-top: -5px;
269
+ margin-left: -6px;
270
+ border-bottom-color: #333
271
+ }
272
+
273
+ #tiptip_holder.tip_right {
274
+ padding-left: 5px
275
+ }
276
+
277
+ #tiptip_holder.tip_right #tiptip_arrow_inner {
278
+ margin-top: -6px;
279
+ margin-left: -5px;
280
+ border-right-color: #333
281
+ }
282
+
283
+ #tiptip_holder.tip_left {
284
+ padding-right: 5px
285
+ }
286
+
287
+ #tiptip_holder.tip_left #tiptip_arrow_inner {
288
+ margin-top: -6px;
289
+ margin-left: -7px;
290
+ border-left-color: #333
291
+ }
292
+
293
+ #tiptip_content, .chart-tooltip, .wc_error_tip {
294
+ color: #fff;
295
+ font-size: .8em;
296
+ max-width: 300px;
297
+ background: #333;
298
+ text-align: center;
299
+ border-radius: 3px;
300
+ padding: .618em 1em;
301
+ -webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, .2);
302
+ box-shadow: 0 1px 3px rgba(0, 0, 0, .2)
303
+ }
304
+
305
+ #tiptip_content code, .chart-tooltip code, .wc_error_tip code {
306
+ padding: 1px;
307
+ background: #888
308
+ }
309
+
310
+ #tiptip_arrow, #tiptip_arrow_inner {
311
+ position: absolute;
312
+ border-color: transparent;
313
+ border-style: solid;
314
+ border-width: 6px;
315
+ height: 0;
316
+ width: 0
317
+ }
318
+
319
+ /**
320
+ Show advanced options
321
+ */
322
+ .show_advanced_options {
323
+ margin: 15px 0 10px 0;
324
+ }
325
+ .advanced_options {
326
+ display: none;
327
+ padding: 16px 24px;
328
+ background: rgba(255, 255, 255, 0.5);
329
+ border-radius: 8px;
330
+ margin-top: 25px;
331
+ }
332
+ .advanced_options label {
333
+ vertical-align: top;
334
+ display: block;
335
+ font-size: 16px;
336
+ line-height: 20px;
337
+ font-weight: 500;
338
+ color: #141414;
339
+ margin-bottom: 16px;
340
+ }
341
+ #embed_regex {
342
+ width: 100%;
343
+ border: 2px solid #d3d3d3;
344
+ border-radius: 7px;
345
+ padding: 8px 15px;
346
+ margin-bottom: 15px;
347
+ }
assets/css/backend/cookiebot_admin_main.css ADDED
@@ -0,0 +1,324 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ @font-face {
2
+ font-family: 'Inter';
3
+ src: url('/wp-content/plugins/cookiebot/assets/fonts/Inter-VariableFont.woff2') format('woff2-variations');
4
+ font-weight: 300 900;
5
+ font-stretch: 100%;
6
+ font-style: normal;
7
+ font-display: swap;
8
+ }
9
+
10
+ #wpcontent {
11
+ padding-left: 0;
12
+ font-family: Inter;
13
+ background-color: #ffffff;
14
+ }
15
+
16
+ .cb-wrapper {
17
+ width: 100%;
18
+ max-width: 1366px;
19
+ margin: 0 auto;
20
+ }
21
+
22
+ .cb-header {
23
+ padding: 15px 25px;
24
+ border-bottom: 1px solid #d3d3d3;
25
+ }
26
+
27
+ .cb-body {
28
+ padding: 50px 25px 0;
29
+ }
30
+
31
+ .cb-body .cb-wrapper {
32
+ display: grid;
33
+ grid-template-columns: .9fr 3.1fr;
34
+ grid-column-gap: 30px;
35
+ align-items: start;
36
+ }
37
+
38
+ .cb-main__tabs {
39
+ display: grid;
40
+ grid-row-gap: 10px;
41
+ }
42
+
43
+ .cb-main__tabs_item {
44
+ border-radius: 7px;
45
+ }
46
+
47
+ .cb-main__tabs_item.active-item, .cb-main__tabs_item:hover {
48
+ background-color: #ECEFFE;
49
+ }
50
+
51
+ .cb-main__tabs_item a {
52
+ font-size: 15px;
53
+ color: #141414;
54
+ padding: 10px 15px;
55
+ text-decoration: none;
56
+ display: grid;
57
+ grid-template-columns: 1fr 8fr;
58
+ grid-column-gap: 5px;
59
+ align-items: center;
60
+ font-weight: 600;
61
+ }
62
+
63
+ .cb-main__tabs_item:hover a, .cb-main__tabs_item.active-item a {
64
+ color: #1032cf;
65
+ }
66
+
67
+ .cb-main__tabs__icon{
68
+ margin-right: 8px;
69
+ display: block;
70
+ width: 28px;
71
+ height: 28px;
72
+ background-color: #141414;
73
+ transition: background-color .25s ease;
74
+ -webkit-mask-size: contain;
75
+ mask-size: contain;
76
+ -webkit-mask-repeat: no-repeat;
77
+ mask-repeat: no-repeat;
78
+ -webkit-mask-position: center;
79
+ mask-position: center;
80
+ }
81
+
82
+ .cb-main__tabs_item:hover .cb-main__tabs__icon, .cb-main__tabs_item.active-item .cb-main__tabs__icon{
83
+ background-color: #1032cf;
84
+ }
85
+
86
+ .dashboard-icon {
87
+ -webkit-mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/dashboard.svg);
88
+ mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/dashboard.svg);
89
+ }
90
+
91
+ .settings-icon {
92
+ -webkit-mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/settings.svg);
93
+ mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/settings.svg);
94
+ }
95
+
96
+ .plugins-icon {
97
+ -webkit-mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/plugins.svg);
98
+ mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/plugins.svg);
99
+ }
100
+
101
+ .support-icon {
102
+ -webkit-mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/support.svg);
103
+ mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/support.svg);
104
+ }
105
+
106
+ .debug-icon {
107
+ -webkit-mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/debug.svg);
108
+ mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/debug.svg);
109
+ }
110
+
111
+ .cb-main__page_title {
112
+ font-size: 55px;
113
+ line-height: 65px;
114
+ font-weight: 700;
115
+ margin: 0 0 30px;
116
+ }
117
+
118
+ .cb-btn {
119
+ display: inline-block;
120
+ margin-top: 18px;
121
+ text-decoration: none;
122
+ padding: 15px;
123
+ font-size: 15px;
124
+ font-weight: 500;
125
+ border-radius: 7px;
126
+ border: none;
127
+ cursor: pointer;
128
+ }
129
+
130
+ .cb-btn.hidden {
131
+ display: none;
132
+ }
133
+
134
+ .cb-main-btn {
135
+ background-color: #1032cf;
136
+ color: #ffffff;
137
+ }
138
+
139
+ .cb-main-btn:hover {
140
+ background-color: #091b70;
141
+ color: #ffffff;
142
+ }
143
+
144
+ .cb-white-btn {
145
+ background-color: #ffffff;
146
+ color: #141414;
147
+ }
148
+
149
+ .cb-white-btn:hover {
150
+ color: #666666;
151
+ }
152
+
153
+ .cb-link-btn {
154
+ background-color: transparent;
155
+ color: #1032cf;
156
+ padding: 0;
157
+ }
158
+
159
+ .cb-link-btn:hover {
160
+ color: #091b70;
161
+ }
162
+
163
+ .cb-right-btn {
164
+ text-align: right;
165
+ }
166
+
167
+ .cb-success-btn {
168
+ background-color: #076646;
169
+ color: #ffffff;
170
+ text-align: center;
171
+ }
172
+
173
+ .cb-main__video {
174
+ position: relative;
175
+ width: 100%;
176
+ height: 0;
177
+ padding-bottom: 53%;
178
+ }
179
+
180
+ .cb-main__video iframe {
181
+ position: absolute;
182
+ width: 100%;
183
+ height: 100%;
184
+ }
185
+
186
+ input[type="text"] {
187
+ width: 100%;
188
+ border: 2px solid #d3d3d3;
189
+ border-radius: 7px;
190
+ padding: 8px 15px;
191
+ }
192
+
193
+ select#cookiebot-language {
194
+ width: 100%;
195
+ border: 2px solid #d3d3d3;
196
+ border-radius: 7px;
197
+ padding: 8px 15px;
198
+ max-width: initial;
199
+ }
200
+
201
+ input[type="radio"] {
202
+ width: 22px;
203
+ height: 22px;
204
+ border: 2px solid #141414;
205
+ }
206
+
207
+ input[type=radio]:checked::before {
208
+ width: 14px;
209
+ height: 14px;
210
+ margin: 2px;
211
+ background-color: #1032cf;
212
+ line-height: initial;
213
+ }
214
+
215
+ input[type="checkbox"] {
216
+ width: 22px;
217
+ height: 22px;
218
+ border: 2px solid #141414;
219
+ }
220
+
221
+ input[type=checkbox]:checked:before {
222
+ content: '';
223
+ width: 26px;
224
+ height: 26px;
225
+ margin: -4px;
226
+ line-height: initial;
227
+ background-color: #1032cf;
228
+ -webkit-mask-image: url("data:image/svg+xml;utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M14.83%204.89l1.34.94-5.81%208.38H9.02L5.78%209.67l1.34-1.25%202.57%202.4z%27%20fill%3D%27%233582c4%27%2F%3E%3C%2Fsvg%3E");
229
+ mask-image: url("data:image/svg+xml;utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M14.83%204.89l1.34.94-5.81%208.38H9.02L5.78%209.67l1.34-1.25%202.57%202.4z%27%20fill%3D%27%233582c4%27%2F%3E%3C%2Fsvg%3E");
230
+ -webkit-mask-size: contain;
231
+ mask-size: contain;
232
+ }
233
+
234
+ textarea {
235
+ width: 100%;
236
+ border: 2px solid #d3d3d3;
237
+ border-radius: 7px;
238
+ padding: 8px 15px;
239
+ }
240
+
241
+ .switch-checkbox {
242
+ display: flex;
243
+ align-items: center;
244
+ }
245
+
246
+ .switch-checkbox input[type=checkbox]{
247
+ height: 0;
248
+ width: 0;
249
+ visibility: hidden;
250
+ border: none;
251
+ min-width: initial;
252
+ float: left;
253
+ }
254
+
255
+ .switch-checkbox .switcher {
256
+ cursor: pointer;
257
+ width: 70px;
258
+ height: 40px;
259
+ margin-right: 10px;
260
+ background-color: #141414;
261
+ display: inline-block;
262
+ border-radius: 100px;
263
+ position: relative;
264
+ transition: 0.3s;
265
+ }
266
+
267
+ .switch-checkbox .switcher:after {
268
+ content: '';
269
+ position: absolute;
270
+ top: 5px;
271
+ left: 5px;
272
+ width: 30px;
273
+ height: 30px;
274
+ background-color: #fff;
275
+ border-radius: 90px;
276
+ transition: 0.3s;
277
+ }
278
+
279
+ .switch-checkbox input[type=checkbox]:checked + .switcher {
280
+ background-color: #1032cf;
281
+ }
282
+
283
+ .switch-checkbox input[type=checkbox]:checked + .switcher:after {
284
+ left: calc(100% - 5px);
285
+ transform: translateX(-100%);
286
+ }
287
+
288
+ .switch-checkbox .switcher:active:after {
289
+ width: 30px;
290
+ }
291
+
292
+ .cb-submit__msg {
293
+ box-sizing: border-box;
294
+ width: 468px;
295
+ position: fixed;
296
+ bottom: 50px;
297
+ right: 75px;
298
+ background-color: #076646;
299
+ color: #ffffff;
300
+ padding: 24px 72px;
301
+ font-size: 15px;
302
+ line-height: 24px;
303
+ font-weight: 600;
304
+ box-shadow: 0px 8px 24px rgba(0, 0, 0, 0.25);
305
+ border-radius: 8px;
306
+ cursor: pointer;
307
+ z-index: 20;
308
+ }
309
+
310
+ .cb-submit__msg:before {
311
+ content: url(/wp-content/plugins/cookiebot/assets/img/icons/check.svg);
312
+ position: absolute;
313
+ left: 30px;
314
+ top: 25px;
315
+ }
316
+
317
+ .cb-submit__msg:after {
318
+ content: '✕';
319
+ position: absolute;
320
+ right: 30px;
321
+ font-weight: 700;
322
+ font-family: monospace;
323
+ font-size: 23px;
324
+ }
assets/css/backend/dashboard_page.css ADDED
@@ -0,0 +1,279 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .cb-main__content {
2
+ display: grid;
3
+ grid-template-columns: repeat(1, minmax(100px, 1fr));
4
+ grid-template-rows: repeat(3, minmax(100px, 1fr));
5
+ grid-column-gap: 30px;
6
+ grid-row-gap: 30px;
7
+ }
8
+
9
+ .cb-main__content.sync-account {
10
+ grid-template-rows: initial;
11
+ }
12
+
13
+ .cb-main__dashboard__card--container {
14
+ display: grid;
15
+ grid-template-columns: 1fr 1fr;
16
+ grid-column-gap: 30px;
17
+ }
18
+
19
+ .cb-main__content.sync-account .cb-main__dashboard__card--container:first-of-type {
20
+ grid-template-columns: 1fr;
21
+ grid-row-gap: 30px;
22
+ }
23
+
24
+ .cb-main__dashboard__card {
25
+ width: 100%;
26
+ display: grid;
27
+ }
28
+
29
+ .cb-main__card__inner {
30
+ display: grid;
31
+ align-self: stretch;
32
+ position: relative;
33
+ padding: 25px;
34
+ border-radius: 25px;
35
+ overflow: hidden;
36
+ }
37
+
38
+ .cb-main__card__inner.legislations_card {
39
+ border-radius: initial;
40
+ grid-row-gap: 7px;
41
+ align-self: start;
42
+ padding: 0;
43
+ }
44
+
45
+ .cb-main__card__inner.account_card {
46
+ position: relative;
47
+ background-image: url(/wp-content/plugins/cookiebot/assets/img/existing-account.png);
48
+ background-size: cover;
49
+ background-position: center center;
50
+ }
51
+
52
+ .cb-main__card__inner.account_card:before {
53
+ content: '';
54
+ position: absolute;
55
+ width: 100%;
56
+ height: 100%;
57
+ background: rgb(0,205,172);
58
+ background: -moz-linear-gradient(58deg, rgba(0,205,172,1) 0%, rgba(16,50,207,1) 100%);
59
+ background: -webkit-linear-gradient(58deg, rgba(0,205,172,1) 0%, rgba(16,50,207,1) 100%);
60
+ background: linear-gradient(58deg, rgba(0,205,172,1) 0%, rgba(16,50,207,1) 100%);
61
+ filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#00cdac",endColorstr="#1032cf",GradientType=1);
62
+ z-index: 0;
63
+ opacity: .7;
64
+ }
65
+
66
+ .cb-main__card__inner.new_card {
67
+ position: relative;
68
+ background-image: url(/wp-content/plugins/cookiebot/assets/img/new-account.png);
69
+ background-size: cover;
70
+ background-position: center center;
71
+ }
72
+
73
+ .cb-main__card__inner.new_card:before {
74
+ content: '';
75
+ position: absolute;
76
+ width: 100%;
77
+ height: 100%;
78
+ background: rgb(16,50,207);
79
+ background: -moz-linear-gradient(0deg, rgba(16,50,207,1) 20%, rgba(16,50,207,0) 100%);
80
+ background: -webkit-linear-gradient(0deg, rgba(16,50,207,1) 20%, rgba(16,50,207,0) 100%);
81
+ background: linear-gradient(0deg, rgba(16,50,207,1) 20%, rgba(16,50,207,0) 100%);
82
+ filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#1032cf",endColorstr="#1032cf",GradientType=1);
83
+ z-index: 0;
84
+ opacity: .7;
85
+ }
86
+
87
+ .cb-main__card__inner.start_card {
88
+ background-color: #efefef;
89
+ }
90
+
91
+ .cb-main__card__content {
92
+ align-self: end;
93
+ z-index: 1;
94
+ }
95
+
96
+ .cb-main__card__title {
97
+ color: #ffffff;
98
+ font-size: 30px;
99
+ line-height: 32px;
100
+ margin: 0;
101
+ width: 100%;
102
+ max-width: 300px;
103
+ }
104
+
105
+ .start_card .cb-main__card__title {
106
+ color: #141414;
107
+ }
108
+
109
+ .cb-main__content.sync-account .cb-main__card__title {
110
+ max-width: 100%;
111
+ }
112
+
113
+ .cb-main__card__subtitle {
114
+ margin: 0;
115
+ }
116
+
117
+ .cb-main__success__text {
118
+ width: 100%;
119
+ max-width: 420px;
120
+ font-size: 16px;
121
+ line-height: 24px;
122
+ }
123
+
124
+ .cb-wp {
125
+ z-index: 1;
126
+ align-self: end;
127
+ justify-self: center;
128
+ }
129
+
130
+ .cb-main__card__label {
131
+ display: inline-block;
132
+ padding: 4px 7px;
133
+ margin: 0 0 10px;
134
+ border-radius: 5px;
135
+ font-size: 12px;
136
+ font-weight: 700;
137
+ }
138
+
139
+ .new_card .cb-main__card__label {
140
+ background-color: #00008d;
141
+ color: #ffffff;
142
+ }
143
+
144
+ .start_card .cb-main__card__label {
145
+ background-color: #00C6FB;
146
+ color: #141414;
147
+ }
148
+
149
+ .cb-main__card__success {
150
+ display: grid;
151
+ grid-template-columns: 1fr 4fr;
152
+ grid-column-gap: 15px;
153
+ align-items: center;
154
+ margin-top: 15px;
155
+ }
156
+
157
+ .cb-main__card__success .cb-btn.cb-success-btn {
158
+ margin-top: 0;
159
+ }
160
+
161
+ .cb-main__video {
162
+ margin-bottom: 25px;
163
+ }
164
+
165
+ .cb-main__legislation__item {
166
+ display: grid;
167
+ grid-template-columns: 1fr 0fr 3fr 2fr;
168
+ background-color: #efefef;
169
+ border-radius: 6px;
170
+ padding: 20px;
171
+ align-items: center;
172
+ }
173
+
174
+ .cb-main__legislation__name {
175
+ font-size: 16px;
176
+ font-weight: 700;
177
+ margin-right: 7px;
178
+ }
179
+
180
+ .cb-main__legislation__region {
181
+ font-weight: 600;
182
+ color: #666666;
183
+ }
184
+
185
+ .cb-link-btn.legislation-link {
186
+ margin: 0;
187
+ text-align: right;
188
+ }
189
+
190
+ .cb-main__dashboard__promo {
191
+ position: relative;
192
+ border-radius: 25px;
193
+ overflow: hidden;
194
+ }
195
+
196
+ .cb-main__dashboard__promo--inner {
197
+ position: relative;
198
+ padding: 50px 65px 20px;
199
+ background: rgb(10,20,62);
200
+ background: -moz-linear-gradient(90deg, rgba(10,20,62,1) 50%, rgba(10,20,62,0.5046393557422969) 100%);
201
+ background: -webkit-linear-gradient(90deg, rgba(10,20,62,1) 50%, rgba(10,20,62,0.5046393557422969) 100%);
202
+ background: linear-gradient(90deg, rgba(10,20,62,1) 50%, rgba(10,20,62,0.5046393557422969) 100%);
203
+ filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#0a143e",endColorstr="#0a143e",GradientType=1);
204
+ z-index: 1;
205
+ height: 100%;
206
+ }
207
+
208
+ .cb-main__dashboard__promo:before {
209
+ content: '';
210
+ position: absolute;
211
+ width: 50%;
212
+ height: 100%;
213
+ background-image: url(/wp-content/plugins/cookiebot/assets/img/extra/sale-black.jpg);
214
+ background-position: -40px center;
215
+ background-size: auto 100%;
216
+ top: 0;
217
+ right: 0;
218
+ z-index: 0;
219
+ }
220
+
221
+ .cb-dashboard__promo--label {
222
+ color: #F4C20E;
223
+ font-size: 15px;
224
+ line-height: 24px;
225
+ font-weight: 700;
226
+ display: grid;
227
+ grid-template-columns: 0fr 1fr;
228
+ }
229
+
230
+ .time-icon {
231
+ margin-right: 8px;
232
+ width: 25px;
233
+ height: 25px;
234
+ transition: background-color .25s ease;
235
+ -webkit-mask-size: contain;
236
+ mask-size: contain;
237
+ -webkit-mask-repeat: no-repeat;
238
+ mask-repeat: no-repeat;
239
+ -webkit-mask-position: center;
240
+ mask-position: center;
241
+ -webkit-mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/clock.svg);
242
+ mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/clock.svg);
243
+ background-color: #F4C20E;
244
+ }
245
+
246
+ .cb-dashboard__promo--title {
247
+ color: #FFFFFF;
248
+ font-size: 58px;
249
+ line-height: 60px;
250
+ text-transform: uppercase;
251
+ margin: 10px 0;
252
+ width: 100%;
253
+ max-width: 790px;
254
+ }
255
+
256
+ .cb-dashboard__promo--title .highlight {
257
+ color: #17EFA6;
258
+ background: none;
259
+ }
260
+
261
+ .cb-btn.cb-promo-btn {
262
+ background-color: #17EFA6;
263
+ color: #141414;
264
+ width: 100%;
265
+ max-width: 298px;
266
+ box-shadow: 0px 4px 52px rgb(23 239 166 / 40%);
267
+ border-radius: 4px;
268
+ text-align: center;
269
+ padding: 20px;
270
+ }
271
+
272
+ .promo-condition {
273
+ font-size: 13px;
274
+ line-height: 18px;
275
+ font-weight: 500;
276
+ color: #ffffff;
277
+ width: 100%;
278
+ max-width: 550px;
279
+ }
assets/css/backend/debug_info.css ADDED
@@ -0,0 +1,52 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .cb-debug__content {
2
+ display: grid;
3
+ grid-template-columns: 1fr 1fr;
4
+ grid-column-gap: 18px;
5
+ margin-bottom: 50px;
6
+ }
7
+
8
+ .cb-debug__info__card {
9
+ padding: 25px 20px 0;
10
+ }
11
+
12
+ .cb-debug__info__title {
13
+ font-size: 22px;
14
+ font-weight: 700;
15
+ margin: 0 0 20px;
16
+ }
17
+
18
+ .cb-debug__info__text {
19
+ font-size: 16px;
20
+ line-height: 24px;
21
+ }
22
+
23
+ .cb-debug__support__inner {
24
+ background-color: #efefef;
25
+ border-radius: 15px;
26
+ padding: 25px;
27
+ }
28
+
29
+ .cb-debug__support__title {
30
+ font-size: 15px;
31
+ margin: 0;
32
+ }
33
+
34
+ .cb-debug__code__container {
35
+ width: 100%;
36
+ border: 3px solid #d3d3d3;
37
+ border-radius: 8px;
38
+ overflow: hidden;
39
+ }
40
+
41
+ .cb-debug__code__container textarea {
42
+ width: calc(100% - 40px);
43
+ height: calc(100% - 40px);
44
+ border: none;
45
+ margin: 20px;
46
+ max-height: 430px;
47
+ background: transparent;
48
+ }
49
+
50
+ .cb-debug__code__container textarea:focus, .cb-debug__code__container textarea:active {
51
+ box-shadow: none;
52
+ }
assets/css/backend/multiple_page.css ADDED
@@ -0,0 +1,142 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .cb-region__table {
2
+ display: grid;
3
+ grid-row-gap: 7px;
4
+ }
5
+
6
+ .cb-region__table__header {
7
+ display: grid;
8
+ grid-template-columns: 1fr 1fr;
9
+ grid-column-gap: 15px;
10
+ padding: 0 24px;
11
+ }
12
+
13
+ .cb-region__table__header--title {
14
+ font-size: 13px;
15
+ line-height: 18px;
16
+ color: #666666;
17
+ font-weight: 700;
18
+ }
19
+
20
+ .cb-region__table__item {
21
+ display: grid;
22
+ grid-template-columns: 1fr 1fr;
23
+ grid-column-gap: 15px;
24
+ background-color: #f2f2f2;
25
+ border-radius: 4px;
26
+ padding: 8px 24px;
27
+ }
28
+
29
+ .cb-region__item__region--primary {
30
+ font-size: 15px;
31
+ line-height: 24px;
32
+ font-weight: 400;
33
+ color: #141414;
34
+ }
35
+
36
+ .cb-region__item__region {
37
+ position: relative;
38
+ }
39
+
40
+ .cb-region__region__selector {
41
+ position: relative;
42
+ width: 100%;
43
+ background-color: #ffffff;
44
+ color: #141414;
45
+ border: 2px solid #d3d3d3;
46
+ border-radius: 7px;
47
+ padding: 8px 15px;
48
+ box-sizing: border-box;
49
+ font-size: 15px;
50
+ font-weight: 600;
51
+ line-height: 27px;
52
+ min-height: 30px;
53
+ cursor: pointer;
54
+ }
55
+
56
+ .cb-region__region__selector:after {
57
+ content: url(/wp-content/plugins/cookiebot/assets/img/icons/down.svg);
58
+ position: absolute;
59
+ top: 7px;
60
+ right: 12px;
61
+ }
62
+
63
+ .selected-regions-item {
64
+ display: inline-block;
65
+ padding: 1px 5px;
66
+ font-size: 13px;
67
+ line-height: initial;
68
+ background: blue;
69
+ color: #ffffff;
70
+ border-radius: 15px;
71
+ margin-right: 4px;
72
+ }
73
+
74
+ .cb-region__region__list {
75
+ position: absolute;
76
+ bottom: 0;
77
+ width: 100%;
78
+ max-height: 220px;
79
+ overflow: hidden;
80
+ background-color: #ffffff;
81
+ box-shadow: 0px 8px 24px rgb(0 0 0 / 25%);
82
+ border-radius: 8px;
83
+ box-sizing: border-box;
84
+ }
85
+
86
+ .cb-region__list__container {
87
+ position: relative;
88
+ width: calc(100% - 4px);
89
+ max-height: 216px;
90
+ margin: 2px;
91
+ box-sizing: border-box;
92
+ overflow-y: scroll;
93
+ z-index: 1;
94
+ }
95
+
96
+ .cb-region__region__item {
97
+ position: relative;
98
+ font-size: 15px;
99
+ font-weight: 600;
100
+ line-height: 24px;
101
+ padding: 10px 15px;
102
+ margin-bottom: 3px;
103
+ border-radius: 8px;
104
+ cursor: pointer;
105
+ }
106
+
107
+ .cb-region__region__item:hover {
108
+ background-color: #f2f2f2;
109
+ color: #1032CF;
110
+ }
111
+
112
+ .cb-region__region__item.selected-region {
113
+ background-color: #ECEFFE;
114
+ color: #1032CF;
115
+ }
116
+
117
+ .cb-region__region__item.selected-region:after {
118
+ content: '';
119
+ position: absolute;
120
+ top: 10px;
121
+ right: 15px;
122
+ width: 20px;
123
+ height: 20px;
124
+ background-color: #1032cf;
125
+ -webkit-mask-size: contain;
126
+ mask-size: contain;
127
+ -webkit-mask-repeat: no-repeat;
128
+ mask-repeat: no-repeat;
129
+ -webkit-mask-position: center;
130
+ mask-position: center;
131
+ -webkit-mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/check.svg);
132
+ mask-image: url(/wp-content/plugins/cookiebot/assets/img/icons/check.svg);
133
+ }
134
+
135
+ .cb-region__veil {
136
+ position: fixed;
137
+ top: 0;
138
+ bottom: 0;
139
+ right: 0;
140
+ left: 0;
141
+ z-index: 0;
142
+ }
assets/css/backend/settings-page.css CHANGED
@@ -11,4 +11,210 @@
11
 
12
  .cookiebot_fieldset_header.active::after {
13
  content: "\f142";
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
14
  }
11
 
12
  .cookiebot_fieldset_header.active::after {
13
  content: "\f142";
14
+ }
15
+
16
+ .cb-settings__header {
17
+ display: grid;
18
+ grid-template-columns: 3fr 1fr;
19
+ align-items: start;
20
+ }
21
+
22
+ .cb-settings__header .cb-main__page_title {
23
+ margin: 0;
24
+ }
25
+
26
+ .cb-settings__header p.submit {
27
+ text-align: right;
28
+ margin: 0;
29
+ padding: 0;
30
+ }
31
+
32
+ .cb-settings__header p.submit #submit {
33
+ background-color: rgba(0, 0, 0, 0.16);
34
+ color: #666666;
35
+ padding: 10px 20px;
36
+ font-size: 16px;
37
+ border: none;
38
+ pointer-events: none;
39
+ }
40
+
41
+ .cb-settings__header p.submit #submit.enabled{
42
+ background-color: #076646;
43
+ color: #ffffff;
44
+ pointer-events: initial;
45
+ }
46
+
47
+ .cb-settings__tabs {
48
+ display: grid;
49
+ grid-template-columns: repeat(6, 1fr);
50
+ margin: 25px 0 50px;
51
+ border-bottom: 1px solid #e1e1e1;
52
+ }
53
+
54
+ .cb-settings__tabs__item {
55
+ display: grid;
56
+ padding: 15px 10px;
57
+ align-items: center;
58
+ border-bottom: 3px solid transparent;
59
+ color: #141414;
60
+ font-size: 16px;
61
+ font-weight: 600;
62
+ text-align: center;
63
+ cursor: pointer;
64
+ }
65
+
66
+ .cb-settings__tabs__item.active-item, .cb-settings__tabs__item:hover {
67
+ border-color: #1032cf;
68
+ }
69
+
70
+ .cb-settings__tabs__content--item {
71
+ display: none;
72
+ }
73
+
74
+ .cb-settings__tabs__content--item.active-item {
75
+ display: block;
76
+ }
77
+
78
+ .cb-general__new__account, .cb-general__consent__mode, .cb-general__prior__consent {
79
+ background-color: #f1f1f1;
80
+ border-radius: 15px;
81
+ padding: 40px;
82
+ margin-bottom: 50px;
83
+ }
84
+
85
+ .cb-general__info__title {
86
+ font-size: 27px;
87
+ font-weight: 700;
88
+ line-height: 30px;
89
+ margin: 0;
90
+ }
91
+
92
+ .cb-general__info__text {
93
+ width: 100%;
94
+ max-width: 620px;
95
+ font-size: 16px;
96
+ line-height: 24px;
97
+ }
98
+
99
+ .new-account-actions .cb-btn:first-of-type {
100
+ margin-right: 20px;
101
+ }
102
+
103
+ .cb-settings__config__item {
104
+ display: grid;
105
+ grid-template-columns: 1fr 1fr;
106
+ margin-bottom: 50px;
107
+ }
108
+
109
+ .cb-settings__config__content {
110
+ padding-right: 40px;
111
+ }
112
+
113
+ .cb-settings__config__subtitle {
114
+ font-size: 20px;
115
+ margin: 0;
116
+ }
117
+
118
+ .cb-settings__config__data__inner {
119
+ background-color: #f1f1f1;
120
+ border-radius: 15px;
121
+ padding: 30px;
122
+ }
123
+
124
+ .cb-settings__data__subtitle {
125
+ font-size: 15px;
126
+ margin: 0 0 15px;
127
+ }
128
+
129
+ #show_add_language_guide {
130
+ display: block;
131
+ }
132
+
133
+ .cb-settings__config__data__inner label {
134
+ display: block;
135
+ font-size: 16px;
136
+ line-height: 20px;
137
+ font-weight: 500;
138
+ color: #141414;
139
+ }
140
+
141
+ .cb-settings__config__data__inner label.switch-checkbox {
142
+ display: flex;
143
+ }
144
+
145
+ .cb-settings__config__data__inner label:not(:first-of-type) {
146
+ margin-top: 20px;
147
+ }
148
+
149
+ .recommended-item:after {
150
+ content: 'Recommended';
151
+ font-size: 13px;
152
+ background-color: #0e1848;
153
+ color: #ffffff;
154
+ padding: 3px 7px;
155
+ border-radius: 5px;
156
+ }
157
+
158
+ .cb-settings__config__item.secondary__item {
159
+ border-left: 4px solid #1032cf;
160
+ }
161
+
162
+ .cb-settings__config__item.secondary__item .cb-settings__config__content {
163
+ padding-left: 90px;
164
+ }
165
+
166
+ .cb-general__info__note {
167
+ font-size: 13px;
168
+ font-style: oblique;
169
+ }
170
+
171
+ .disabled__item {
172
+ filter: grayscale(1);
173
+ opacity: .5;
174
+ pointer-events: none;
175
+ }
176
+
177
+ .cb-prior__tab__selector {
178
+ position: relative;
179
+ display: grid;
180
+ grid-template-columns: 1fr 1fr;
181
+ align-items: center;
182
+ justify-items: center;
183
+ width: 100%;
184
+ max-width: 360px;
185
+ margin: 0 auto;
186
+ border: 2px solid #e3e3e3;
187
+ border-radius: 150px;
188
+ }
189
+
190
+ .cb-prior__tab__selector:before {
191
+ position: absolute;
192
+ content: '';
193
+ width: calc(50% - 6px);
194
+ height: calc(100% - 6px);
195
+ background: #1032cf;
196
+ border-radius: 150px;
197
+ left: 3px;
198
+ z-index: 0;
199
+ }
200
+
201
+ .cb-prior__tab__item {
202
+ width: 100%;
203
+ text-align: center;
204
+ padding: 15px;
205
+ font-size: 15px;
206
+ font-weight: 500;
207
+ z-index: 1;
208
+ }
209
+
210
+ .cb-prior__tab__item.active-item {
211
+ color: #ffffff;
212
+ }
213
+
214
+ .cb-prior__tab__content__item {
215
+ display: none;
216
+ }
217
+
218
+ .cb-prior__tab__content__item.active-item {
219
+ display: block;
220
  }
assets/css/backend/support_page.css ADDED
@@ -0,0 +1,123 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .cb-support__content {
2
+ display: grid;
3
+ grid-template-columns: 1fr 1fr;
4
+ grid-column-gap: 18px;
5
+ margin-bottom: 50px;
6
+ }
7
+
8
+ .cb-support__info__card {
9
+ padding: 25px 20px 0;
10
+ }
11
+
12
+ .cb-support__info__title {
13
+ font-size: 22px;
14
+ font-weight: 700;
15
+ margin: 0 0 20px;
16
+ }
17
+
18
+ .cb-support__info__text {
19
+ font-size: 16px;
20
+ line-height: 24px;
21
+ }
22
+
23
+ .cb-support__video__inner {
24
+ background-color: #efefef;
25
+ border-radius: 15px;
26
+ padding: 25px;
27
+ }
28
+
29
+ .cb-support__video__title {
30
+ font-size: 15px;
31
+ margin: 0;
32
+ }
33
+
34
+ .cb-main__video {
35
+ margin-top: 25px;
36
+ margin-bottom: 0;
37
+ }
38
+
39
+ .cb-faq__container {
40
+ border-radius: 8px;
41
+ background-color: #efefef;
42
+ padding: 24px 24px 0;
43
+ }
44
+
45
+ .cb-faq__container:not(:first-of-type) {
46
+ margin-top: 4px;
47
+ }
48
+
49
+ .cb-faq__question {
50
+ margin: 0;
51
+ border-bottom: 1px solid transparent;
52
+ padding-bottom: 16px;
53
+ display: flex;
54
+ justify-content: space-between;
55
+ align-items: center;
56
+ cursor: pointer;
57
+ font-size: 16px;
58
+ font-weight: 600;
59
+ line-height: 1.6em;
60
+ letter-spacing: .1px;
61
+ transition: color .25s ease;
62
+ }
63
+
64
+ .cb-faq__container.cb-faq--opened .cb-faq__question {
65
+ color: #1032cf;
66
+ border-bottom: 1px solid #d3d3d3;
67
+ }
68
+
69
+ .cb-faq__toggle {
70
+ display: inline-block;
71
+ position: relative;
72
+ min-width: 24px;
73
+ height: 24px;
74
+ margin-left: 10px;
75
+ }
76
+
77
+ .cb-faq__toggle:after, .cb-faq__toggle:before {
78
+ content: "";
79
+ width: 14px;
80
+ height: 2px;
81
+ background-color: #141414;
82
+ display: inline-block;
83
+ position: absolute;
84
+ left: 5px;
85
+ top: 11px;
86
+ transition: color .25s ease;
87
+ }
88
+
89
+ .cb-faq__toggle:after {
90
+ transform: rotate(90deg);
91
+ transition: transform .25s ease,color .25s ease;
92
+ }
93
+
94
+ .cb-faq__container.cb-faq--opened .cb-faq__toggle:after {
95
+ transform: rotate(0deg);
96
+ }
97
+
98
+ .cb-faq__container.cb-faq--opened .cb-faq__toggle:after, .cb-faq__container.cb-faq--opened .cb-faq__toggle:before {
99
+ background-color: #1032cf;
100
+ }
101
+
102
+ .cb-faq__answer {
103
+ overflow: hidden;
104
+ height: 0;
105
+ transition: height .25s ease;
106
+ }
107
+
108
+ .cb-faq__container.cb-faq--opened .cb-faq__answer {
109
+ height: initial;
110
+ padding-bottom: 24px;
111
+ }
112
+
113
+ .cb-faq__code {
114
+ padding: 0 10px;
115
+ font-family: monospace;
116
+ overflow-wrap: initial;
117
+ overflow-x: auto;
118
+ background-image: linear-gradient(white 50%, rgb(215 221 250) 50%);
119
+ background-size: 1em 2.85em;
120
+ background-origin: content-box;
121
+ display: inline-block;
122
+ width: 100%;
123
+ }
assets/fonts/Inter-VariableFont.woff2 ADDED
Binary file
assets/img/cb-wp.png ADDED
Binary file
assets/img/europe.png ADDED
Binary file
assets/img/existing-account.png ADDED
Binary file
assets/img/extra/sale-black.jpg ADDED
Binary file
assets/img/icons/check.svg ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <svg width="19" height="14" viewBox="0 0 19 14" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M6.29508 10.8749L2.12508 6.70492L0.705078 8.11492L6.29508 13.7049L18.2951 1.70492L16.8851 0.294922L6.29508 10.8749Z" fill="#ffffff"/>
3
+ </svg>
assets/img/icons/clock.svg ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <svg width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M10.49 0C4.97 0 0.5 4.48 0.5 10C0.5 15.52 4.97 20 10.49 20C16.02 20 20.5 15.52 20.5 10C20.5 4.48 16.02 0 10.49 0ZM10.5 18C6.08 18 2.5 14.42 2.5 10C2.5 5.58 6.08 2 10.5 2C14.92 2 18.5 5.58 18.5 10C18.5 14.42 14.92 18 10.5 18ZM11 5H9.5V11L14.75 14.15L15.5 12.92L11 10.25V5Z" fill="#F4C20E"/>
3
+ </svg>
assets/img/icons/dashboard.svg ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <svg width="19" height="18" viewBox="0 0 19 18" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M16.5 2V4H12.5V2H16.5ZM6.5 2V8H2.5V2H6.5ZM16.5 10V16H12.5V10H16.5ZM6.5 14V16H2.5V14H6.5ZM18.5 0H10.5V6H18.5V0ZM8.5 0H0.5V10H8.5V0ZM18.5 8H10.5V18H18.5V8ZM8.5 12H0.5V18H8.5V12Z" fill="#141414"/>
3
+ </svg>
assets/img/icons/debug.svg ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <svg width="19" height="22" viewBox="0 0 19 22" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M16.5 2H12.32C11.9 0.84 10.8 0 9.5 0C8.2 0 7.1 0.84 6.68 2H2.5C1.4 2 0.5 2.9 0.5 4V20C0.5 21.1 1.4 22 2.5 22H16.5C17.6 22 18.5 21.1 18.5 20V4C18.5 2.9 17.6 2 16.5 2ZM9.5 2C10.05 2 10.5 2.45 10.5 3C10.5 3.55 10.05 4 9.5 4C8.95 4 8.5 3.55 8.5 3C8.5 2.45 8.95 2 9.5 2ZM16.5 20H2.5V4H4.5V7H14.5V4H16.5V20Z" fill="#141414"/>
3
+ </svg>
assets/img/icons/down.svg ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <svg width="12" height="8" viewBox="0 0 12 8" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M10.59 0.590088L6 5.17009L1.41 0.590088L0 2.00009L6 8.00009L12 2.00009L10.59 0.590088Z" fill="#141414"/>
3
+ </svg>
assets/img/icons/link.svg ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <svg width="19" height="18" viewBox="0 0 19 18" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M16.5 16H2.5V2H9.5V0H2.5C1.39 0 0.5 0.9 0.5 2V16C0.5 17.1 1.39 18 2.5 18H16.5C17.6 18 18.5 17.1 18.5 16V9H16.5V16ZM11.5 0V2H15.09L5.26 11.83L6.67 13.24L16.5 3.41V7H18.5V0H11.5Z" fill="black"/>
3
+ </svg>
assets/img/icons/plugins.svg ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <svg width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M9.25 2.25C9.53 2.25 9.75 2.47 9.75 2.75V4.75H15.75V10.75H17.75C18.03 10.75 18.25 10.97 18.25 11.25C18.25 11.53 18.03 11.75 17.75 11.75H15.75V17.75H13.63C12.95 16 11.24 14.75 9.25 14.75C7.26 14.75 5.55 16 4.87 17.75H2.75V15.63C4.5 14.95 5.75 13.24 5.75 11.25C5.75 9.26 4.51 7.55 2.76 6.87L2.75 4.75H8.75V2.75C8.75 2.47 8.97 2.25 9.25 2.25ZM9.25 0.25C7.87 0.25 6.75 1.37 6.75 2.75H2.75C1.65 2.75 0.76 3.65 0.76 4.75V8.55H1.05C2.54 8.55 3.75 9.76 3.75 11.25C3.75 12.74 2.54 13.95 1.05 13.95H0.75V17.75C0.75 18.85 1.65 19.75 2.75 19.75H6.55V19.45C6.55 17.96 7.76 16.75 9.25 16.75C10.74 16.75 11.95 17.96 11.95 19.45V19.75H15.75C16.85 19.75 17.75 18.85 17.75 17.75V13.75C19.13 13.75 20.25 12.63 20.25 11.25C20.25 9.87 19.13 8.75 17.75 8.75V4.75C17.75 3.65 16.85 2.75 15.75 2.75H11.75C11.75 1.37 10.63 0.25 9.25 0.25Z" fill="#141414"/>
3
+ </svg>
assets/img/icons/settings.svg ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <svg width="19" height="18" viewBox="0 0 19 18" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M0.5 14V16H6.5V14H0.5ZM0.5 2V4H10.5V2H0.5ZM10.5 18V16H18.5V14H10.5V12H8.5V18H10.5ZM4.5 6V8H0.5V10H4.5V12H6.5V6H4.5ZM18.5 10V8H8.5V10H18.5ZM12.5 6H14.5V4H18.5V2H14.5V0H12.5V6Z" fill="#141414"/>
3
+ </svg>
assets/img/icons/support.svg ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <svg width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M10.5 0C4.98 0 0.5 4.48 0.5 10C0.5 15.52 4.98 20 10.5 20C16.02 20 20.5 15.52 20.5 10C20.5 4.48 16.02 0 10.5 0ZM17.96 7.12L15.18 8.27C14.67 6.91 13.6 5.83 12.23 5.33L13.38 2.55C15.48 3.35 17.15 5.02 17.96 7.12ZM10.5 13C8.84 13 7.5 11.66 7.5 10C7.5 8.34 8.84 7 10.5 7C12.16 7 13.5 8.34 13.5 10C13.5 11.66 12.16 13 10.5 13ZM7.63 2.54L8.8 5.32C7.42 5.82 6.33 6.91 5.82 8.29L3.04 7.13C3.85 5.02 5.52 3.35 7.63 2.54ZM3.04 12.87L5.82 11.72C6.33 13.1 7.41 14.18 8.79 14.68L7.62 17.46C5.52 16.65 3.85 14.98 3.04 12.87ZM13.38 17.46L12.23 14.68C13.6 14.17 14.68 13.09 15.18 11.71L17.96 12.88C17.15 14.98 15.48 16.65 13.38 17.46Z" fill="#141414"/>
3
+ </svg>
assets/img/new-account.png ADDED
Binary file
assets/img/usa.png ADDED
Binary file
assets/js/backend/multiple-page.js ADDED
@@ -0,0 +1,91 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /**
2
+ * Load init function when the page is ready
3
+ *
4
+ * @since 1.8.0
5
+ */
6
+ jQuery( document ).ready( init );
7
+
8
+ function init() {
9
+ showMultipleConfig();
10
+ selectRegion();
11
+ toggleRegionSelector();
12
+ }
13
+
14
+ function showMultipleConfig() {
15
+ jQuery('#multiple-config').on('change', function(){
16
+ if(jQuery(this).is(':checked')){
17
+ jQuery('.cb-multiple__container').removeClass('hidden');
18
+ }else{
19
+ jQuery('.cb-multiple__container').addClass('hidden');
20
+ }
21
+ });
22
+ }
23
+
24
+ function toggleRegionSelector() {
25
+ const region_list = jQuery('.cb-region__region__list');
26
+ jQuery('.cb-region__region__selector').on('click', function(){
27
+ region_list.removeClass('hidden');
28
+ });
29
+
30
+ jQuery('.cb-region__veil').on('click', function(){
31
+ region_list.addClass('hidden');
32
+ });
33
+ }
34
+
35
+ function selectRegion() {
36
+ jQuery('.cb-region__region__item').on('click', function(){
37
+ let code = jQuery(this).data('region');
38
+ let name = jQuery(this).text();
39
+ if(jQuery(this).hasClass('selected-region')){
40
+ jQuery(this).removeClass('selected-region');
41
+ toggleCode(code,name);
42
+ }else{
43
+ jQuery(this).addClass('selected-region');
44
+ toggleCode(code,name);
45
+ }
46
+ });
47
+ }
48
+
49
+ function toggleCode(code,name) {
50
+ const regionInput = jQuery('#second-banner-regions');
51
+ const regionVal = jQuery('#second-banner-regions').val();
52
+ const ccpaInput = jQuery('#ccpa-compatibility');
53
+ const submitBtn = jQuery('p.submit #submit');
54
+ const selectedBox = jQuery('.selected-regions');
55
+ let regionList = regionVal.split(', ');
56
+
57
+ if(regionList[0]==='')
58
+ regionList = [];
59
+
60
+ if(regionList.indexOf(code)!==-1){
61
+ regionList.splice(regionList.indexOf(code),1);
62
+ if(code==='US-06')
63
+ ccpaInput.val('');
64
+ }else{
65
+ regionList.push(code);
66
+ if(code==='US-06')
67
+ ccpaInput.val('1');
68
+ }
69
+
70
+ let itemSelector = '#'+code;
71
+ let selected = jQuery(itemSelector);
72
+
73
+ if(selected.length<=0){
74
+ let newItem = document.createElement('div');
75
+ newItem.classList.add('selected-regions-item');
76
+ newItem.id = code;
77
+ newItem.innerText = name;
78
+ selectedBox.append(newItem);
79
+ }else{
80
+ selected.remove();
81
+ }
82
+
83
+ const newRegions = regionList.join(', ');
84
+ if(newRegions.length<=0){
85
+ jQuery('.default-none').removeClass('hidden');
86
+ }else{
87
+ jQuery('.default-none').addClass('hidden');
88
+ }
89
+ regionInput.val(newRegions);
90
+ submitBtn.addClass('enabled');
91
+ }
assets/js/backend/network-settings-page.js CHANGED
@@ -3,10 +3,12 @@ jQuery( document ).ready( function ( $ ) {
3
  $( 'input[type=radio][name=cookiebot-cookie-blocking-mode]' ).on( 'change', function () {
4
  if ( this.value === 'auto' && cookieBlockingMode !== this.value ) {
5
  $( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 0.4 )
 
6
  $( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', true )
7
  }
8
  if ( this.value === 'manual' && cookieBlockingMode !== this.value ) {
9
  $( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 1 )
 
10
  $( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', false )
11
  }
12
  cookieBlockingMode = this.value
@@ -15,4 +17,14 @@ jQuery( document ).ready( function ( $ ) {
15
  $( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 0.4 )
16
  $( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', true )
17
  }
 
 
 
 
 
 
 
 
 
 
18
  } )
3
  $( 'input[type=radio][name=cookiebot-cookie-blocking-mode]' ).on( 'change', function () {
4
  if ( this.value === 'auto' && cookieBlockingMode !== this.value ) {
5
  $( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 0.4 )
6
+ $( '#declaration-tag').addClass('disabled__item');
7
  $( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', true )
8
  }
9
  if ( this.value === 'manual' && cookieBlockingMode !== this.value ) {
10
  $( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 1 )
11
+ $( '#declaration-tag, #cookie-popup').removeClass('disabled__item');
12
  $( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', false )
13
  }
14
  cookieBlockingMode = this.value
17
  $( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 0.4 )
18
  $( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', true )
19
  }
20
+
21
+ jQuery('.cb-submit__msg').on('click',function(){
22
+ jQuery(this).addClass('hidden');
23
+ });
24
+
25
+ jQuery(':input').change(
26
+ function(){
27
+ jQuery('p.submit #submit').addClass('enabled');
28
+ }
29
+ );
30
  } )
assets/js/backend/prior-consent-settings.js CHANGED
@@ -19,6 +19,8 @@ function init() {
19
  show_advanced_options();
20
  edit_embed_regex();
21
  set_default_embed_regex();
 
 
22
  }
23
 
24
  /**
@@ -229,3 +231,17 @@ function set_default_embed_regex() {
229
  }
230
  );
231
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
19
  show_advanced_options();
20
  edit_embed_regex();
21
  set_default_embed_regex();
22
+ closeSubmitMsg();
23
+ submitEnable();
24
  }
25
 
26
  /**
231
  }
232
  );
233
  }
234
+
235
+ function closeSubmitMsg() {
236
+ jQuery('.cb-submit__msg').on('click',function(){
237
+ jQuery(this).addClass('hidden');
238
+ });
239
+ }
240
+
241
+ function submitEnable() {
242
+ jQuery(':input').change(
243
+ function(){
244
+ jQuery('p.submit #submit').addClass('enabled');
245
+ }
246
+ );
247
+ }
assets/js/backend/settings-page.js CHANGED
@@ -9,6 +9,9 @@ function init() {
9
  language_toggle();
10
  advanced_settings_toggle();
11
  cookie_blocking_mode();
 
 
 
12
  }
13
 
14
  function language_toggle() {
@@ -58,11 +61,13 @@ function cookie_blocking_mode() {
58
 
59
  jQuery( 'input[type=radio][name=cookiebot-cookie-blocking-mode]' ).on( 'change', function () {
60
  if ( this.value === 'auto' && cookieBlockingMode !== this.value ) {
61
- jQuery( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 0.4 )
 
62
  jQuery( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', true )
63
  }
64
  if ( this.value === 'manual' && cookieBlockingMode !== this.value ) {
65
- jQuery( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 1 )
 
66
  jQuery( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', false )
67
  }
68
  cookieBlockingMode = this.value
@@ -71,4 +76,39 @@ function cookie_blocking_mode() {
71
  jQuery( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 0.4 )
72
  jQuery( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', true )
73
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
74
  }
9
  language_toggle();
10
  advanced_settings_toggle();
11
  cookie_blocking_mode();
12
+ activeSettingsTab();
13
+ closeSubmitMsg();
14
+ submitEnable();
15
  }
16
 
17
  function language_toggle() {
61
 
62
  jQuery( 'input[type=radio][name=cookiebot-cookie-blocking-mode]' ).on( 'change', function () {
63
  if ( this.value === 'auto' && cookieBlockingMode !== this.value ) {
64
+ jQuery( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 0.4 );
65
+ jQuery( '#declaration-tag, #cookie-popup').addClass('disabled__item');
66
  jQuery( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', true )
67
  }
68
  if ( this.value === 'manual' && cookieBlockingMode !== this.value ) {
69
+ jQuery( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 1 );
70
+ jQuery( '#declaration-tag, #cookie-popup').removeClass('disabled__item');
71
  jQuery( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', false )
72
  }
73
  cookieBlockingMode = this.value
76
  jQuery( '#cookiebot-setting-async, #cookiebot-setting-hide-popup' ).css( 'opacity', 0.4 )
77
  jQuery( 'input[type=radio][name=cookiebot-script-tag-uc-attribute], input[name=cookiebot-nooutput]' ).prop( 'disabled', true )
78
  }
79
+ }
80
+
81
+ function activeSettingsTab() {
82
+ jQuery('.cb-settings__tabs__item').on('click', function(){
83
+ let currentTab = jQuery('.cb-settings__tabs__item.active-item').data('tab');
84
+ let tab = jQuery(this).data('tab');
85
+ let tabSelector = '#'+tab;
86
+ jQuery('.cb-settings__tabs__item.active-item, .cb-settings__tabs__content--item.active-item').removeClass('active-item');
87
+ jQuery(this).addClass('active-item');
88
+ jQuery(tabSelector).addClass('active-item');
89
+
90
+ window.history.replaceState(null, null, '?page=cookiebot_settings&tab='+tab );
91
+ let referrer = jQuery('input[name="_wp_http_referer"]');
92
+ let referrerVal = referrer.val();
93
+ if(referrerVal.indexOf('tab=')!==-1) {
94
+ referrerVal = referrerVal.replace(currentTab,tab);
95
+ }else{
96
+ referrerVal += '&tab=' + tab;
97
+ }
98
+ referrer.val(referrerVal);
99
+ });
100
+ }
101
+
102
+ function closeSubmitMsg() {
103
+ jQuery('.cb-submit__msg').on('click',function(){
104
+ jQuery(this).addClass('hidden');
105
+ });
106
+ }
107
+
108
+ function submitEnable() {
109
+ jQuery(':input').change(
110
+ function(){
111
+ jQuery('p.submit #submit').addClass('enabled');
112
+ }
113
+ );
114
  }
assets/js/backend/support-page.js ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ (() => {
2
+ const questionItem = document.querySelectorAll('.cb-faq__container');
3
+
4
+ for (let i = 0; i < questionItem.length; i++) {
5
+ questionItem[i].addEventListener('click', function() {
6
+ const active = document.querySelector('.cb-faq--opened');
7
+ active.classList.remove('cb-faq--opened');
8
+ questionItem[i].classList.toggle('cb-faq--opened');
9
+ });
10
+ }
11
+ })();
cookiebot.php CHANGED
@@ -1,11 +1,11 @@
1
  <?php
2
 
3
  /*
4
- Plugin Name: Cookiebot | GDPR/CCPA Compliant Cookie Consent and Control
5
  Plugin URI: https://cookiebot.com/
6
- Description: Cookiebot is a cloud-driven solution that automatically controls cookies and trackers, enabling full GDPR/ePrivacy and CCPA compliance for websites.
7
- Author: Cybot A/S
8
- Version: 4.1.1
9
  Author URI: http://cookiebot.com
10
  Text Domain: cookiebot
11
  Domain Path: /langs
1
  <?php
2
 
3
  /*
4
+ Plugin Name: Cookiebot CMP by Usercentrics | The reliable, flexible and easy to use consent solution
5
  Plugin URI: https://cookiebot.com/
6
+ Description: Cookiebot consent management platform (CMP) provides a plug-and-play cookie consent solution that enables compliance with the GDPR, LGPD, CCPA and other international regulations.
7
+ Author: Usercentrics A/S
8
+ Version: 4.2.1
9
  Author URI: http://cookiebot.com
10
  Text Domain: cookiebot
11
  Domain Path: /langs
logo.svg ADDED
@@ -0,0 +1,39 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <svg width="110" height="32" viewBox="0 0 110 32" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <g clip-path="url(#clip0_533_11180)">
3
+ <g clip-path="url(#clip1_533_11180)">
4
+ <path d="M32.0211 23.5454C31.6571 23.5255 31.2958 23.6163 30.9845 23.8058C30.6731 23.9953 30.4265 24.2746 30.277 24.607H30.2011V21.5928H29.0068V29.7065H30.1632V28.7587H30.258C30.4117 29.0919 30.6619 29.3712 30.9763 29.5605C31.2907 29.7498 31.6546 29.8403 32.0211 29.8203C33.4997 29.8203 34.5613 28.6449 34.5613 26.6733C34.5613 24.7018 33.4997 23.5454 32.0211 23.5454ZM31.7746 28.8155C30.7509 28.8155 30.1822 27.9435 30.1822 26.6544C30.1822 25.3653 30.732 24.5312 31.7746 24.5312C32.8552 24.5312 33.386 25.4411 33.386 26.6544C33.386 27.8677 32.8362 28.8155 31.7746 28.8155Z" fill="#141414"/>
5
+ <path d="M37.8215 28.3604H37.7647L36.2291 23.6401H34.959L37.196 29.8012L37.0443 30.1993C36.741 31.0144 36.3239 31.0713 35.6604 30.9007L35.376 31.8675C35.6384 31.9573 35.914 32.0022 36.1912 32.0002C37.177 32.0002 37.7836 31.4884 38.1438 30.5216L40.6462 23.6211H39.376L37.8215 28.3604Z" fill="#141414"/>
6
+ <path d="M49.4613 26.8436C49.4613 27.9431 48.703 28.7393 47.4708 28.7393C46.2386 28.7393 45.4803 27.9431 45.4803 26.8436V21.6113H44.248V26.9573C44.248 28.6635 45.5182 29.8767 47.4708 29.8767C49.4234 29.8767 50.6935 28.6635 50.6935 26.9573V21.6113H49.4613V26.8436Z" fill="#141414"/>
7
+ <path d="M55.1107 26.3127L54.1439 26.0852C53.4803 25.9335 53.177 25.7061 53.196 25.289C53.196 24.8151 53.7078 24.4928 54.3713 24.4928C55.1107 24.4928 55.4519 24.9099 55.5846 25.308L56.6652 25.1184C56.4187 24.1705 55.6794 23.5449 54.3713 23.5449C52.9875 23.5449 52.0206 24.2653 52.0206 25.3459C52.0206 26.2179 52.5514 26.7866 53.6889 27.0331L54.7126 27.2606C55.3003 27.3933 55.5657 27.6587 55.5657 28.0378C55.5657 28.5117 55.0538 28.8719 54.2766 28.8719C53.5751 28.8719 53.1202 28.5686 52.9685 27.962L51.8311 28.1326C52.0206 29.2132 52.9306 29.8198 54.2955 29.8198C55.7742 29.8198 56.7789 29.0425 56.7789 27.943C56.7789 27.0899 56.2292 26.5591 55.1107 26.3127Z" fill="#141414"/>
8
+ <path d="M60.3428 23.5449C58.6366 23.5449 57.5371 24.834 57.5371 26.7108C57.5371 28.5876 58.6366 29.8388 60.4376 29.8388C61.7646 29.8388 62.7124 29.1752 62.9778 28.1895L61.8594 27.9809C61.6508 28.5497 61.139 28.853 60.4565 28.853C59.4328 28.853 58.7504 28.1895 58.7314 27.0141H63.0537V26.5971C63.0347 24.398 61.7267 23.5449 60.3428 23.5449ZM58.7125 26.1421C58.7693 25.27 59.3949 24.5307 60.3428 24.5307C61.2906 24.5307 61.8594 25.2132 61.8783 26.1421H58.7125Z" fill="#141414"/>
9
+ <path d="M65.291 24.5881H65.2341V23.6213H64.0967V29.7066H65.291V25.991C65.291 25.1948 65.8976 24.626 66.7507 24.626C66.9617 24.6226 67.1722 24.6481 67.3763 24.7019V23.5644C67.2062 23.5479 67.0353 23.5416 66.8644 23.5455C66.5248 23.5263 66.1881 23.6175 65.9045 23.8054C65.621 23.9933 65.4057 24.2679 65.291 24.5881Z" fill="#141414"/>
10
+ <path d="M70.4471 24.5497C70.7587 24.5354 71.0653 24.6324 71.3119 24.8234C71.5585 25.0145 71.7291 25.287 71.7931 25.5923H72.9495C72.8168 24.3601 71.8121 23.5449 70.4282 23.5449C68.703 23.5449 67.6035 24.834 67.6035 26.6918C67.6035 28.5497 68.6651 29.8388 70.4471 29.8388C71.8879 29.8388 72.8168 28.9667 72.9495 27.7914H71.7931C71.7323 28.0983 71.5626 28.3729 71.3152 28.5645C71.0678 28.7562 70.7595 28.8519 70.4471 28.834C69.4424 28.834 68.7978 27.9999 68.7978 26.6729C68.7978 25.3459 69.4424 24.5497 70.4471 24.5497Z" fill="#141414"/>
11
+ <path d="M76.4756 23.5449C74.7884 23.5449 73.6699 24.834 73.6699 26.7108C73.6699 28.5876 74.7695 29.8388 76.5704 29.8388C77.8974 29.8388 78.8453 29.1752 79.1107 28.1895L77.9922 27.9809C77.7837 28.5497 77.2718 28.853 76.5894 28.853C75.5657 28.853 74.9022 28.1895 74.8642 27.0141H79.1865V26.5971C79.1676 24.398 77.8595 23.5449 76.4756 23.5449ZM74.8453 26.1421C74.9022 25.27 75.5277 24.5307 76.4756 24.5307C77.4235 24.5307 77.9922 25.2132 78.0112 26.1421H74.8453Z" fill="#141414"/>
12
+ <path d="M83.2242 23.5449C82.3142 23.5449 81.7076 23.962 81.4232 24.6065H81.3474V23.6208H80.21V29.7061H81.4043V26.0852C81.4043 25.1184 81.9919 24.5497 82.8261 24.5497C83.6223 24.5497 84.1152 25.0805 84.1152 25.9525V29.6871H85.3095V25.8198C85.2905 24.3411 84.4564 23.5449 83.2242 23.5449Z" fill="#141414"/>
13
+ <path d="M88.9121 28.7393C88.533 28.7393 88.1917 28.6066 88.1917 27.9242V24.5687H89.4429V23.6208H88.1917V22.1611H86.9974V23.6208H86.1064V24.5687H86.9974V28.1706C86.9974 29.2701 87.8316 29.8199 88.7794 29.8009C89.0445 29.8056 89.3081 29.7606 89.5567 29.6682L89.3481 28.6825C89.2056 28.7186 89.0592 28.7377 88.9121 28.7393Z" fill="#141414"/>
14
+ <path d="M91.6796 24.5881H91.6228V23.6213H90.4854V29.7066H91.6796V25.991C91.6796 25.1948 92.2863 24.626 93.1393 24.626C93.3503 24.6226 93.5608 24.6481 93.7649 24.7019V23.5644C93.5948 23.5479 93.4239 23.5416 93.2531 23.5455C92.9134 23.5263 92.5767 23.6175 92.2932 23.8054C92.0096 23.9933 91.7944 24.2679 91.6796 24.5881Z" fill="#141414"/>
15
+ <path d="M95.0727 21.2705C94.8797 21.2648 94.6921 21.3351 94.5503 21.4662C94.4085 21.5974 94.3238 21.7789 94.3145 21.9719C94.3176 22.0679 94.3398 22.1623 94.3797 22.2497C94.4197 22.3371 94.4766 22.4157 94.5471 22.481C94.6176 22.5462 94.7004 22.5968 94.7906 22.6298C94.8809 22.6628 94.9768 22.6776 95.0727 22.6733C95.1692 22.6804 95.2661 22.6675 95.3573 22.6355C95.4486 22.6034 95.5322 22.5529 95.6031 22.4871C95.6739 22.4213 95.7304 22.3415 95.7691 22.2529C95.8077 22.1642 95.8276 22.0686 95.8276 21.9719C95.8276 21.8752 95.8077 21.7795 95.7691 21.6908C95.7304 21.6022 95.6739 21.5225 95.6031 21.4566C95.5322 21.3908 95.4486 21.3403 95.3573 21.3083C95.2661 21.2762 95.1692 21.2634 95.0727 21.2705Z" fill="#141414"/>
16
+ <path d="M95.6797 23.6211H94.4854V29.7064H95.6797V23.6211Z" fill="#141414"/>
17
+ <path d="M99.5467 24.5497C99.8583 24.5354 100.165 24.6324 100.411 24.8234C100.658 25.0145 100.829 25.287 100.893 25.5923H102.049C101.916 24.3601 100.912 23.5449 99.5277 23.5449C97.8026 23.5449 96.7031 24.834 96.7031 26.6918C96.7031 28.5497 97.7647 29.8388 99.5467 29.8388C100.987 29.8388 101.916 28.9667 102.049 27.7914H100.893C100.832 28.0983 100.662 28.3729 100.415 28.5645C100.167 28.7562 99.8591 28.8519 99.5467 28.834C98.542 28.834 97.8974 27.9999 97.8974 26.6729C97.8974 25.3459 98.5609 24.5497 99.5467 24.5497Z" fill="#141414"/>
18
+ <path d="M106.049 26.3127L105.082 26.0852C104.419 25.9335 104.116 25.7061 104.134 25.289C104.134 24.8151 104.646 24.4928 105.31 24.4928C106.049 24.4928 106.39 24.9099 106.523 25.308L107.604 25.1184C107.357 24.1705 106.618 23.5449 105.31 23.5449C103.926 23.5449 102.959 24.2653 102.959 25.3459C102.959 26.2179 103.49 26.7866 104.627 27.0331L105.651 27.2606C106.239 27.3933 106.504 27.6587 106.504 28.0378C106.504 28.5117 105.992 28.8719 105.215 28.8719C104.514 28.8719 104.059 28.5686 103.907 27.962L102.77 28.1326C102.959 29.2132 103.869 29.8198 105.234 29.8198C106.713 29.8198 107.717 29.0425 107.717 27.943C107.717 27.0899 107.168 26.5591 106.049 26.3127Z" fill="#141414"/>
19
+ <path d="M54.9218 17.6494L49.8222 10.8627L54.7701 5.19442H50.7322L46.0687 10.7868V0.455078H42.7891V17.6684H46.0687V14.4835L47.5284 12.929L50.808 17.6684H54.9218V17.6494Z" fill="#141414"/>
20
+ <path d="M57.0821 3.94318H57.1389C57.6589 3.93393 58.155 3.72324 58.5228 3.35549C58.8906 2.98773 59.1012 2.49161 59.1105 1.97161C59.1012 1.45161 58.8906 0.955493 58.5228 0.587738C58.155 0.219984 57.6589 0.00929717 57.1389 4.83686e-05C56.6247 -0.00356331 56.1297 0.195215 55.7609 0.553457C55.392 0.9117 55.1788 1.40066 55.1674 1.91474V1.97161C55.1623 2.22713 55.208 2.48111 55.3018 2.71886C55.3955 2.95661 55.5354 3.17342 55.7135 3.35676C55.8915 3.5401 56.1042 3.68632 56.3391 3.78698C56.574 3.88763 56.8265 3.94072 57.0821 3.94318Z" fill="#141414"/>
21
+ <path d="M55.4336 17.8196H58.6184V5.3457H55.4336V17.8196Z" fill="#141414"/>
22
+ <path d="M101.898 14.6923C101.898 16.9861 103.13 18.1425 105.424 18.1425C106.374 18.186 107.314 17.9343 108.116 17.4222L107.471 14.9577C107.137 15.1862 106.738 15.2994 106.334 15.28H106.258C105.932 15.232 105.639 15.0581 105.44 14.7957C105.241 14.5333 105.154 14.2034 105.196 13.8771V8.22784H107.736V5.36528H105.196V1.91504H101.917V5.36528H99.8691V8.22784H101.917V14.6923H101.898Z" fill="#141414"/>
23
+ <path d="M77.139 16.1891C77.5974 16.7765 78.1844 17.2512 78.8548 17.5765C79.5251 17.9018 80.2611 18.0692 81.0063 18.0659C84.1153 18.0659 86.5039 15.6962 86.5039 11.5066C86.5039 7.41185 84.1343 4.9474 81.0063 4.9474C80.2615 4.94602 79.5261 5.11431 78.8561 5.4395C78.186 5.76468 77.5988 6.23822 77.139 6.82417V0.435547H73.8594V17.6488H77.139V16.1891ZM77.139 9.28863C77.4594 8.84684 77.8777 8.48518 78.3612 8.23194C78.8446 7.97871 79.3801 7.84077 79.9257 7.82891C81.8025 7.82891 83.0347 9.28863 83.0347 11.4308C83.0347 13.573 81.8025 15.0327 79.9257 15.0327C79.3853 15.0254 78.8536 14.8953 78.3708 14.6522C77.888 14.4092 77.4668 14.0596 77.139 13.6299V9.28863Z" fill="#141414"/>
24
+ <path d="M68.4564 14.351C67.7506 14.8222 66.8922 15.008 66.0547 14.8708C65.2172 14.7335 64.463 14.2835 63.9445 13.6117L71.9066 9.02401L71.5843 8.37946C69.537 4.87235 66.0109 3.697 62.8071 5.5169C62.7123 5.57378 62.6175 5.63065 62.5417 5.68752C61.8351 6.12381 61.2218 6.69553 60.7371 7.36978C60.2523 8.04402 59.9057 8.80749 59.7172 9.61622C59.5286 10.425 59.5019 11.263 59.6386 12.0821C59.7752 12.9012 60.0725 13.6852 60.5133 14.3889C60.6081 14.5596 60.7028 14.7112 60.7787 14.8629C61.2272 15.5621 61.8094 16.1659 62.4917 16.6397C63.174 17.1136 63.9431 17.4481 64.755 17.6242C65.5668 17.8003 66.4054 17.8145 67.2227 17.666C68.0401 17.5174 68.82 17.2091 69.518 16.7586C71.1062 15.8983 72.3361 14.5004 72.9872 12.8155L70.6934 11.678C70.2981 12.8117 69.5027 13.7622 68.4564 14.351ZM64.1152 7.73491C64.1341 7.71595 64.1531 7.71595 64.172 7.697C64.4918 7.4933 64.8492 7.35561 65.223 7.29205C65.5968 7.22849 65.9796 7.24034 66.3487 7.32689C66.7179 7.41344 67.066 7.57295 67.3726 7.79604C67.6793 8.01913 67.9382 8.30128 68.1341 8.62591L62.8829 11.678C62.5522 10.9867 62.4954 10.1958 62.724 9.46427C62.9526 8.73276 63.4496 8.11491 64.1152 7.73491Z" fill="#141414"/>
25
+ <path d="M15.7366 16.1518C15.1053 16.8271 14.3421 17.3656 13.4943 17.7341C12.6465 18.1025 11.7321 18.2931 10.8077 18.294C8.98011 18.2889 7.22936 17.5581 5.9406 16.2622C4.65184 14.9664 3.93065 13.2116 3.93568 11.384C3.94071 9.55642 4.67154 7.80566 5.96741 6.51691C7.26328 5.22815 9.01803 4.50696 10.8456 4.51199C12.642 4.51006 14.3662 5.21881 15.6418 6.48355C16.4127 5.41473 17.4263 4.54411 18.5992 3.94327C17.1454 2.33156 15.2348 1.2014 13.1221 0.703524C11.0095 0.205652 8.79529 0.363733 6.77481 1.15668C4.75433 1.94963 3.02363 3.33976 1.81356 5.14165C0.603481 6.94355 -0.0284565 9.07155 0.00202988 11.2418C-0.0181691 14.0894 1.09238 16.8286 3.08988 18.858C5.08738 20.8875 7.80857 22.0415 10.6561 22.0665H10.7319C12.2297 22.0551 13.7093 21.7363 15.0789 21.1298C16.4485 20.5232 17.6789 19.6419 18.694 18.5404C17.5573 17.9516 16.5514 17.1391 15.7366 16.1518Z" fill="#141414"/>
26
+ <path d="M21.8781 4.7205C20.141 4.74313 18.484 5.45489 17.2717 6.69921C16.0594 7.94353 15.391 9.61847 15.4136 11.3556C15.4363 13.0927 16.148 14.7497 17.3923 15.962C18.6367 17.1743 20.3116 17.8427 22.0487 17.82C22.0677 17.82 22.0677 17.82 22.0677 17.839C23.7913 17.821 25.4375 17.1205 26.6456 15.8911C27.8537 14.6616 28.5253 13.0034 28.5132 11.2797V11.185C28.504 10.3242 28.3249 9.47377 27.9861 8.68246C27.6474 7.89115 27.1556 7.17457 26.539 6.57388C25.9225 5.97319 25.1933 5.50024 24.3935 5.18218C23.5936 4.86412 22.7388 4.70722 21.8781 4.7205ZM22.0487 14.6921C21.1376 14.6793 20.2674 14.3117 19.6231 13.6674C18.9788 13.0231 18.6112 12.1529 18.5985 11.2418C18.5985 10.5594 18.8008 9.89237 19.1799 9.32498C19.5591 8.75759 20.0979 8.31537 20.7284 8.05423C21.3588 7.79309 22.0525 7.72476 22.7218 7.85789C23.3911 7.99102 24.0059 8.31962 24.4884 8.80215C24.9709 9.28467 25.2995 9.89944 25.4327 10.5687C25.5658 11.238 25.4975 11.9317 25.2363 12.5622C24.9752 13.1926 24.533 13.7315 23.9656 14.1106C23.3982 14.4897 22.7311 14.6921 22.0487 14.6921Z" fill="#141414"/>
27
+ <path d="M35.4904 4.7205C34.6303 4.73171 33.7808 4.91222 32.9904 5.25172C32.2 5.59123 31.4843 6.08308 30.884 6.69921C29.6717 7.94353 29.0033 9.61847 29.0259 11.3556C29.0486 13.0927 29.7603 14.7497 31.0046 15.962C32.249 17.1743 33.9239 17.8427 35.661 17.82C35.68 17.82 35.68 17.82 35.68 17.839C37.4036 17.821 39.0498 17.1205 40.2579 15.8911C41.466 14.6616 42.1376 13.0034 42.1255 11.2797V11.185C42.1163 10.3242 41.9372 9.47377 41.5984 8.68246C41.2597 7.89115 40.7679 7.17457 40.1513 6.57388C39.5348 5.97319 38.8056 5.50024 38.0058 5.18218C37.2059 4.86412 36.3511 4.70722 35.4904 4.7205ZM35.661 14.6921C34.749 14.6822 33.8772 14.3155 33.2322 13.6706C32.5873 13.0257 32.2206 12.1538 32.2108 11.2418C32.2108 10.5594 32.4131 9.89237 32.7922 9.32498C33.1714 8.75759 33.7102 8.31537 34.3407 8.05423C34.9711 7.79309 35.6648 7.72476 36.3341 7.85789C37.0034 7.99102 37.6182 8.31962 38.1007 8.80215C38.5832 9.28467 38.9118 9.89944 39.045 10.5687C39.1781 11.238 39.1098 11.9317 38.8486 12.5622C38.5875 13.1926 38.1453 13.7315 37.5779 14.1106C37.0105 14.4897 36.3434 14.6921 35.661 14.6921Z" fill="#141414"/>
28
+ <path d="M93.613 17.8197C94.4675 17.8165 95.3128 17.6445 96.1006 17.3138C96.8884 16.983 97.6031 16.5 98.2038 15.8923C98.8044 15.2846 99.2791 14.5643 99.6007 13.7727C99.9222 12.9811 100.084 12.1338 100.078 11.2794V11.1846C100.061 9.88935 99.6599 8.62821 98.9262 7.56065C98.1924 6.4931 97.1587 5.66708 95.9555 5.18704C94.7524 4.707 93.4339 4.59451 92.1668 4.86377C90.8997 5.13304 89.7409 5.77198 88.837 6.6998C87.933 7.62761 87.3245 8.80264 87.0883 10.0763C86.8521 11.35 86.9989 12.6651 87.5101 13.8553C88.0214 15.0455 88.874 16.0574 89.9603 16.7631C91.0466 17.4687 92.3178 17.8364 93.613 17.8197ZM93.7078 7.8102C94.6229 7.8102 95.5005 8.17371 96.1475 8.82075C96.7946 9.4678 97.1581 10.3454 97.1581 11.2604C97.1581 12.1755 96.7946 13.0531 96.1475 13.7001C95.5005 14.3472 94.6229 14.7107 93.7078 14.7107C92.7928 14.7107 91.9152 14.3472 91.2681 13.7001C90.6211 13.0531 90.2576 12.1755 90.2576 11.2604C90.2576 10.3454 90.6211 9.4678 91.2681 8.82075C91.9152 8.17371 92.7928 7.8102 93.7078 7.8102Z" fill="#141414"/>
29
+ </g>
30
+ </g>
31
+ <defs>
32
+ <clipPath id="clip0_533_11180">
33
+ <rect width="109.333" height="32" fill="white"/>
34
+ </clipPath>
35
+ <clipPath id="clip1_533_11180">
36
+ <rect width="109.333" height="32.0001" fill="white"/>
37
+ </clipPath>
38
+ </defs>
39
+ </svg>
readme.txt CHANGED
@@ -1,57 +1,47 @@
1
- # Cookiebot | GDPR/CCPA Compliant Cookie Consent and Control #
2
  * Contributors: cookiebot,phpgeekdk,aytac
3
- * Tags: cookie, compliance, eu, gdpr, europe, cookie consent, consent, ccpa
4
  * Requires at least: 4.4
5
- * Tested up to: 6.0.0
6
- * Stable tag: 4.1.1
7
  * Requires PHP: 5.6
8
  * License: GPLv2 or later
9
 
10
- Cookiebot is a cloud-driven solution that automatically controls cookies and trackers, enabling full GDPR/ePrivacy and CCPA compliance for websites.
11
-
12
  ## Description ##
13
 
14
- ### Trustworthy and simple cookie consent solution for GDPR/ePR and CCPA compliance ###
15
 
16
- Cookiebot is a cloud-driven solution that automatically controls cookies and trackers, enabling full GDPR/ePR and CCPA compliance and offering:
17
 
18
- * A highly customizable consent banner to handle consents and give the user the possibility to opt in and out of cookie categories, as required by the GDPR/ePR, CCPA and similar legislations around the world.
19
- * An automatically generated and updated cookie policy and cookie declaration, with purpose descriptions and categorization of your cookies (Necessary, Statistic, Preferences, Marketing).
20
- * A Do Not Sell My Personal Information link on the cookie declaration for end-users to opt out of having their data sold to third parties, as required by the CCPA – including the special opt-in banner for sites that have visitors under the age of 16, also in accordance with CCPA.
21
- * Monthly website scans, detecting all first- and third-party cookies and similar tracking on your site (e.g. HTML5 Local Storage, Flash Local Shared Object, Silverlight Isolated Storage, IndexedDB, ultrasound beacons, pixel tags etc.) as well as their provenance, duration and where the data is sent to.
22
- * The unique Cookiebot feature of automatic cookie blocking. All cookies and tracking are automatically held back right from the moment the user lands on the website and until the proper consent has been obtained, enabling compliance with the GDPR and the ePrivacy Directive.
23
- * An easy way to allow the user to change or withdraw their consent.
24
- * Supports 45 languages in consent banner and cookie declaration.
25
- * Secure storage of user consents in our cloud-driven environment. The user consents are downloadable and can be used as proof that the consent was given.
26
- * Execution of cookie-setting scripts without a page reload, if the user gives consent.
27
 
28
- Please read our FAQ at the bottom of the page for more information.
29
 
30
- https://youtube.com/watch?v=t1LJ6i1i9gA
31
 
32
- ### Will my website become compliant once I install Cookiebot? ###
33
 
34
- If you use our plugin version 3.0 or later and choose the automatic implementation, Cookiebot enables full compliance with the ‘prior consent’ requirement of the GDPR, the ePrivacy Directive (ePR) and similar legal instruments for protection of user data around the world.
35
 
36
- Cookiebot also enables compliance with the CCPA through the implementation of the Do Not Sell My Personal Information link on a website’s cookie declaration, as well as the opt-in banner required if your website targets visitors under the age of 16.
37
 
38
- The default consent banner has the strictest settings possible and is suitable for obtaining consent under both GDPR and the ePR. Make sure to adapt the consent banner content to fit your website. You should also check out [our GDPR checklist if you have users from the European Union](https://support.cookiebot.com/hc/en-us/sections/360000917513-Ready-for-25-May-2018-GDPR-enforcement-date-A-Cookiebot-checklist-). If you are using server-side cookies, please check the [“Server side usage” guide](https://www.cookiebot.com/en/developer/).
39
 
40
- However, being a customizable plugin, true compliance always depends on the website owner choosing a type of banner, wording and settings that are compliant with the local legislation and fits the specific website and company (data controller).
41
 
42
- **If you choose the manual implementation…**
43
 
44
- Then please make sure of the following:
45
 
46
- If you are using plugins that set cookies which require consent (which most do), you have to:
47
 
48
- * Ask the plugin developers if they are planning on becoming GDPR/CCPA compliant, or if they would like to integrate with Cookiebot.
49
- * [Check out our Github repository](https://github.com/CybotAS/CookiebotAddons), where we are developing integrations for Cookiebot, until the plugin developers choose to do this themselves, [or if WP Core enables such functionality](https://core.trac.wordpress.org/ticket/44043).
50
 
51
- Once Cookiebot is installed and we’ve scanned your site, you can check the [cookie report](https://manage.cookiebot.com/goto/reports) to identify all cookies being set on your website. If the cookies are coming from content that you have inserted manually, you can mark up that content [as described in our manual implementation guide step 4](https://cookiebot.com/goto/manual-implementation).
52
 
53
- Embedded videos and iframes which set cookies can be marked up as explained in our [Iframe cookie consent with YouTube example](https://support.cookiebot.com/hc/en-us/articles/360003790854-Iframe-cookie-consent-with-YouTube-example).
54
 
 
55
 
56
  ### Cookiebot Addons ####
57
  Add-ons are produced by an open-source community of developers. This is done to help make it easier for Wordpress users to implement ‘prior consent’ for cookies and trackers set by plugins that do not offer this as a built-in functionality.
@@ -64,140 +54,182 @@ If your favourite plugin isn't supported you're welcome to contribute or request
64
 
65
 
66
  ## Installation ##
67
- First, install the plugin on your WordPress site.
68
 
69
- Then, go to Settings -> Cookiebot and add your Cookiebot ID.
 
 
 
70
 
71
- If you haven't created one yet - or if you're not sure how to find it - follow the instructions on the page.
 
72
 
73
- Once your Cookiebot ID is added, the consent dialog will be displayed to the visitors of your site.
 
74
 
75
- [For more help, visit our support section, that contains various articles on how to set up Cookiebot properly](https://support.cookiebot.com/).
76
 
77
- **Installation video:**
78
 
79
- https://www.youtube.com/watch?v=t1LJ6i1i9gA
80
 
81
- **Implementing the cookie declaration:**
82
 
83
- https://youtu.be/OCXz2bt4H_w
84
 
85
- **Implementing prior consent:**
86
 
87
- Below is a video tutorial on how to manually implement prior consent i.e. holding back all cookies and trackers (other than those strictly necessary for the website to function) until the user has given a consent. The manual implementation guide (found in step 11 of the video) can be [found here](https://cookiebot.com/goto/manual-implementation).
88
- Please note that you can make use of our automatic cookie blocking functionality instead of manually having to mark up the cookie-setting scripts. To do so, update the plugin (version 3.0.0 or higher) and choose automatic cookie control in your Admin panel. 
89
 
90
- https://youtu.be/MeHycvV2QCQ
 
 
 
 
 
91
 
92
  ## Frequently Asked Questions ##
93
 
94
  ### Is Cookiebot free? ###
95
- Cookiebot is a freemium plugin, much like [Jetpack](https://wordpress.org/plugins/jetpack/) and [Monsterinsights](https://wordpress.org/plugins/google-analytics-for-wordpress/).
96
-
97
- Whether the free plan can suffice or you need a premium plan, depends on two things:
98
 
99
- **1. The size of your website, i.e. the number of subpages on your website.**
100
- In other words, you cannot choose whether you want a free plan or a premium plan, as this is determined by the amount of subpages on your website. You can [get a quote](https://www.cookiebot.com/goto/quote-input/) to see what plan you need for your website.
101
 
102
- **2. Your necessities, as the free plan does not include all features available in the premium plans.** The free plan does not include customization of banner and cookies declaration, multiple languages, e-mail reports, data-export, geo location, bulk consent, consent statistics, internal domain alias for development, test and staging.
 
103
 
104
- If more than 100 subpages are found during the initial website scan, you will be given a free one-month trial of Cookiebot with full functionality.
105
 
106
- See all details of [Cookiebot plans and pricing](https://www.cookiebot.com/goto/pricing/).
107
 
108
- ### What does Cookiebot count as pages?
109
- Your pricing plan is dependent on the number of subpages we have detected on your website.
110
 
111
- Some users mistakenly think that Cookiebot counts their **image files** as subpages, thus setting the users on a higher subscription plan.
 
112
 
113
- Cookiebot does **not count image files as subpages**. Depending on your theme, Wordpress may automatically create real pages for content placed in your media library, called Attachment pages. Because these pages can contain online trackers, Cookiebot includes them in your page count.
114
 
115
- To disable the Attachment page feature in Wordpress, please see the following guides:
116
 
117
  https://themeskills.com/disable-media-attachment-pages-wordpress/
118
  https://www.wpexplorer.com/disable-image-page/
119
 
120
  ### Cookie declaration ###
121
- The Cookiebot solution also includes an automatically updated cookie declaration about the cookies in use on your site.
122
 
123
  By implementing it, you ensure that your cookie declaration is specific and accurate at all times, as required by the GDPR. Also, the declaration automatically provides the mandatory options for the user to change or withdraw consent.
124
 
125
- For CCPA compliance, businesses will be able to display the CCPA required **Do Not Sell My Personal Information** link on their cookie declaration.
126
 
127
- To display your cookie declaration, create a new page on your website - and add the shortcode that the plugin provides to the page: [cookie_declaration]. Alternatively, you can incorporate it into e.g. your existing Privacy Policy.
128
 
129
- By default, the cookie declaration is displayed in the chosen Cookiebot language. You are able to override this setting with a "lang" attribute in the shortcode. Eg.: [cookie_declaration lang="de"] for a German version. Remember to add all used languages in the [Cookiebot Manager](https://manage.cookiebot.com).
130
 
131
- https://youtu.be/OCXz2bt4H_w
132
 
133
  ### Cookie-checker: What cookies are in use on my site? ###
134
- If you are in doubt about what cookies are in use on our site, you can start by trying our free compliance test:
135
 
136
  **[Test my site](https://www.cookiebot.com/)**
137
 
138
- The test scans up to five pages of your website and sends you a complete report of the cookies and online tracking on these pages, including information on their provenance, purpose and whether or not they are compliant with EU-legislation.
139
 
140
- If you want a complete overview of the cookies and online tracking going on on all of your website, sign up to the Cookiebot solution.
141
 
142
- ### What is the GDPR and the ePrivacy Directive? ###
143
- The GDPR is the General Data Protection Regulation, an EU-law enforced since May 2018, that protects EU citizens’ personal data globally and affects all organizations and websites that handle such data. If you have a website with users from the EU, and if your websites uses cookies (it probably does), then you need to make your use of cookies and tracking compliant with the GDPR.
144
 
145
- See the [EU homepage of the GDPR](https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=celex%3A32016R0679) for more information, and their infographic for businesses: [Data Protection: Better rules for small businesses](http://ec.europa.eu/justice/smedataprotect/index_en.htm)
146
 
147
- The ePrivacy Directive is another legal instrument of the EU that specifically aims to protect EU citizens’ online data such as data from online communication. It is in the process of becoming an actual Regulation such as the GDPR, which will probably happen in 2020.
 
148
 
149
- ### What is the CCPA? ###
150
- The California Consumer Privacy Act (CCPA) is a state-wide law that regulates how businesses all over the world are allowed to handle the personal information of California residents.
 
 
 
 
 
 
 
 
 
 
151
 
152
  You are liable for CCPA compliance if your business:
153
 
154
- * Sells the personal information of more than 50,000 California residents per year,
155
- * Has an annual gross revenue exceeding $25 million,
156
- * Derives more than 50 percent of its annual revenue from the selling of personal information of California residents.
157
 
158
- Cookies and other tracking technologies are classified as unique identifiers that form part of the CCPA’s definition of personal information.
159
 
160
- If your business has a website, you must know and disclose to consumers, at or before the point of collection, the data you collect and which third parties you share it with. This can be done through the Cookiebot cookie declaration that also features the required Do Not Sell My Personal Information link, so end-users can opt out of having their data sold.
161
 
162
- If your website is visited by consumers under the age of 16, you are required by the CCPA to first obtain their opt-in. This can be done through Cookiebots CCPA opt-in banner.
163
 
164
- Visit [Cookiebot](https://www.cookiebot.com/en/what-is-ccpa/) to read more about the CCPA, how to achieve CCPA compliance, and what the CCPA says about your website’s use of cookies.
165
 
166
  ### How do I make other plugins support Cookiebot? ###
167
- If your favourite plugin doesn't support Cookiebot you are always welcome to ask the author to add support for Cookiebot.
168
 
169
- Send an e-mail to the author of the plugin you want to support Cookiebot. Ask for adding support for Cookiebot. Cookiebot provides a helper function to check if there is an active, working version of Cookiebot on the website.
 
 
170
 
171
- The easiest way for a developer to implement Cookiebot support is following to add a check for Cookiebot where <script> tags are outputted to the visitor. This can be done following way
172
 
173
- $scriptTag = '<script>';
174
- if(function_exists('cookiebot_active') && cookiebot_active()) {
175
- $scriptTag = '<script'.cookiebot_assist('statistics').'>';
176
  }
177
 
178
- The developer of the plugin can see more details on [our Github repository](https://github.com/CybotAS/CookiebotAddons)
179
 
180
- ### Can I use Cookiebot with Google Tag Manager? ###
181
- Cookiebot works with GTM. There are two different options setting up GTM with Cookiebot:
 
 
 
 
 
 
 
 
 
 
182
 
183
- 1. Use the Google Tag Manager option in the plugin settings to enable GTM together with Cookiebot. Here you also have the option to enable Google Consent Mode for GTM.
184
- 2. Add the GTM script manually or by using another plugin to your site.
185
 
186
- Should you choose one of these methods, Cookiebot must not be implemented using GTM as this would result in Cookiebot being loaded twice.
 
 
187
 
188
  If you prefer the latter method, you should select ´Hide Cookie Popup´ in the Cookiebot WordPress plugin settings.
189
 
190
  [Please see our article on how to deploy Cookiebot with GTM](https://support.cookiebot.com/hc/en-us/articles/360003793854-Google-Tag-Manager-deployment).
191
 
 
 
 
 
192
  ### Does Cookiebot integrate with WP Consent API? ###
193
- Cookiebot is fully integrated with the WP Consent API. When your visitors give consent using Cookiebot, the consent will automatically be sent to the [WP Consent API](https://wordpress.org/plugins/wp-consent-api/).
194
 
195
- You are able to define the mapping between Cookiebot and the WP Consent API in the administration interface (Cookiebot WP plugin).
196
 
197
- ### Does Cookiebot work with translation plugins?
198
- Cookiebot is compatible with translation plugins when you set language to "Use WordPress Language".
199
 
200
  ## Changelog ##
 
 
 
 
 
 
 
 
 
 
201
  ### 4.1.1 - 2022-07-01 ###
202
  * Fixed undefined variable src when using instagram embed
203
 
@@ -466,4 +498,4 @@ Cookiebot is compatible with translation plugins when you set language to "Use W
466
 
467
  ## Copyright and Trademarks ##
468
 
469
- Cookiebot is a registered trademark of Cybot A/S
1
+ # Cookiebot CMP by Usercentrics | The reliable, flexible and easy to use consent solution #
2
  * Contributors: cookiebot,phpgeekdk,aytac
3
+ * Tags: cookie banner, cookies, GDPR, CCPA, cookie notice, dsgvo, ePrivacy, privacy compliance, cookie law, data privacy, cmp
4
  * Requires at least: 4.4
5
+ * Tested up to: 6.1.1
6
+ * Stable tag: 4.2.1
7
  * Requires PHP: 5.6
8
  * License: GPLv2 or later
9
 
 
 
10
  ## Description ##
11
 
12
+ ### RELIABLE, FLEXIBLE AND EASY TO USE COOKIE CONSENT SOLUTION FOR GDPR/ePR, CCPA/CPRA and IAB TCF compliance. ###
13
 
14
+ Cookiebot consent management platform (CMP) provides a **plug-and-play cookie consent solution** that enables compliance with the **GDPR, LGPD, CCPA and other international regulations**. It deploys industry-leading scanning technology and seamless integration with Google Consent Mode to help you **balance data privacy with data-driven business** on your domain.
15
 
16
+ The Cookiebot CMP delivers:
 
 
 
 
 
 
 
 
17
 
18
+ - highly **customizable cookie consent banner** that enables website visitors to opt in or out of cookie categories
19
 
20
+ - industry-leading scanning technology that **automatically detects all cookies and other trackers** on your website
21
 
22
+ - **automatically-generated cookie declaration** that can be used for your privacy policy page
23
 
24
+ - full **integration with Google Consent Mode** right out of the box
25
 
26
+ - automatic cookie blocking feature that blocks all cookies and trackers until user consent has been obtained, **enabling compliance with GDPR, ePR, CCPA/CPRA** and other international regulations
27
 
28
+ - easy to use widget that enables website visitors to **update their consent** at any time
29
 
30
+ - **secure storage of user consents** in our cloud-based environment
31
 
32
+ - downloadable user consent information to **comply with Data Subject Requests**
33
 
34
+ - cookie consent banner and cookie declaration **in over 40 languages**
35
 
36
+ [Find detailed information on the Cookiebot CMP functions here](https://www.cookiebot.com/en/functions/).
37
 
38
+ **Please read our FAQ at the bottom of the page for more information.**
 
39
 
40
+ **How to install the Cookiebot CMP Wordpress Plugin**
41
 
42
+ [youtube https://youtube.com/watch?v=eSVFnjoMKFk]
43
 
44
+ **NEED HELP?** [Visit our Help Center](https://support.cookiebot.com/hc/en-us)
45
 
46
  ### Cookiebot Addons ####
47
  Add-ons are produced by an open-source community of developers. This is done to help make it easier for Wordpress users to implement ‘prior consent’ for cookies and trackers set by plugins that do not offer this as a built-in functionality.
54
 
55
 
56
  ## Installation ##
 
57
 
58
+ To easily install the Cookiebot CMP, follow the steps below.
59
+
60
+
61
+ 1. Install the plugin on your WordPress website.
62
 
63
+ 2. Make sure that you have a Cookiebot CMP account. Don't have an account yet? Sign up [here](https://manage.cookiebot.com/en/signup/?utm_source=wordpress&utm_medium=organic&utm_campaign=banner).
64
+ If your website counts less than 100 subdomains, your Cookiebot CMP account is completely free. All the other subscriptions have a free 30-day-trial period.
65
 
66
+ 3. Link your Cookiebot CMP account to the plugin, go to "Settings" > "General Settings" in the WordPress Dashboard, and add your Domain Group ID.
67
+ Need help finding your Domain Group ID? [Learn here](https://support.cookiebot.com/hc/en-us/articles/4405643234194-Your-CBID-or-Domain-group-ID-and-where-to-find-it) where you can find it. Once your Domain Group ID is added in the WordPress Dashboard, the cookie consent banner will be visible on your website.
68
 
69
+ 4. Set the main language of your cookie consent banner
70
 
71
+ 5. Select your cookie-blocking mode. The [auto cookie-blocking mode](https://support.cookiebot.com/hc/en-us/articles/36000906310x0-How-does-Automatic-Cookie-Blocking-work-) will automatically block all cookies (except for ‘strictly necessary’ cookies) until a user has given consent. The [manual cookie-blocking mode](https://support.cookiebot.com/hc/en-us/articles/4405978132242-Manual-cookie-blocking) requests manual adjustments to the cookie-setting scripts.
72
 
 
73
 
74
+ To find out more about the setup and customizability of the Cookiebot CMP, please visit our [Help Center](https://support.cookiebot.com/).
75
 
76
+ **Recommended Videos**
77
 
78
+ How to install the Cookiebot CMP Wordpress Plugin
79
 
80
+ [youtube https://youtube.com/watch?v=eSVFnjoMKFk]
 
81
 
82
+ Implement the Cookie Declaration
83
+
84
+ [youtube https://youtube.com/watch?v=OCXz2bt4H_w]
85
+
86
+ ## Google Consent Mode ##
87
+ Google Consent Mode is enabled by default. It's an open API developed by Google that enables your website to run all Google services, such as Google Analytics, Google Tag Manager and Google Ads, based on the consent status of your end users. With Cookiebot CMP's integration with Google Consent Mode you can respect the privacy choices of end users with minimal impact on your website's ad-based revenue stream, analytics and more. [Learn more about Google Consent Mode](https://support.cookiebot.com/hc/en-us/articles/360016047000-Cookiebot-and-Google-Consent-Mode).
88
 
89
  ## Frequently Asked Questions ##
90
 
91
  ### Is Cookiebot free? ###
92
+ Cookiebot is a freemium plugin, much like Jetpack and Monsterinsights.
 
 
93
 
94
+ Whether the free plan is sufficient or you need a premium plan depends on two things:
 
95
 
96
+ 1. The size of your website, i.e. the number of subpages on your website.
97
+ You cannot choose whether you want a free plan or a premium plan, as this is determined by the number of subpages on your website. Get a quote to see which plan your site needs.
98
 
99
+ 2. The features you need. The free plan **does not include** all features available in the premium plans. The free plan does not include customization of banner and cookies declaration, multiple languages, email reports, data export, geolocation, bulk consent, consent statistics, internal domain alias for development, test and staging.
100
 
101
+ If more than 100 subpages are found during the initial website scan, you will be given a free one-month trial of Cookiebot CMP with full functionality.
102
 
103
+ See all details of Cookiebot CMP [plans and pricing](https://www.cookiebot.com/goto/pricing/).
 
104
 
105
+ ### What does Cookiebot count as pages? ###
106
+ Your pricing plan is dependent on the number of subpages the Cookiebot CMP detects on your website.
107
 
108
+ Cookiebot does not count image files as subpages, thus setting users to a higher subscription plan. Depending on your theme, WordPress may automatically create real pages for content placed in your media library, called Attachment pages. Because these pages can contain online trackers, Cookiebot CMP includes them in your page count.
109
 
110
+ To disable the Attachment page feature in WordPress, please see the following guides:
111
 
112
  https://themeskills.com/disable-media-attachment-pages-wordpress/
113
  https://www.wpexplorer.com/disable-image-page/
114
 
115
  ### Cookie declaration ###
116
+ Cookiebot CMP also includes an automatically updated cookie declaration for the cookies in use on your site.
117
 
118
  By implementing it, you ensure that your cookie declaration is specific and accurate at all times, as required by the GDPR. Also, the declaration automatically provides the mandatory options for the user to change or withdraw consent.
119
 
120
+ For CCPA and CPRA compliance, businesses will be able to display the required Do Not Sell Or Share My Personal Information link on their cookie declaration.
121
 
122
+ To display your cookie declaration, create a new page on your website and add the shortcode provided by the plugin to the page: [cookie_declaration]. Alternatively, you can incorporate it into your existing Privacy Policy.
123
 
124
+ By default, the cookie declaration is displayed in the selected Cookiebot CMP language. You are able to override this setting with a lang attribute in the shortcode. E.g.: [cookie_declaration lang=”de] for a German version. Remember to add all languages used in the [Cookiebot Manager](https://manage.cookiebot.com/en/login).
125
 
126
+ [youtube https://www.youtube.com/watch?v=OCXz2bt4H_w]
127
 
128
  ### Cookie-checker: What cookies are in use on my site? ###
129
+ If you are in doubt about what cookies are in use on our site, start with our free compliance test:
130
 
131
  **[Test my site](https://www.cookiebot.com/)**
132
 
133
+ The test scans up to five pages of your website and sends you a complete report of the cookies and online tracking on these pages, including information on their provenance, purpose and whether or not they are compliant with EU regulations.
134
 
135
+ If you want a complete overview of the cookies and online tracking on your website, sign up for the Cookiebot CMP solution.
136
 
137
+ ### How can I set up my cookie banner with Cookiebot CMP? ###
 
138
 
139
+ Please find here **[our step by step guide](https://support.cookiebot.com/hc/en-us/articles/4408356523282-Getting-started)** on how to set up your cookie banner.
140
 
141
+ ### How does Cookiebot CMP block cookies and trackers?###
142
+ Cookiebot CMP provides two modes to block cookies and trackers before consent has been given.
143
 
144
+ 1. **Auto cookie-blocking mode** will automatically block all cookies (except for ‘strictly necessary’ cookies) until a user has given consent. [Learn more about the auto cookie-blocking mode](https://support.cookiebot.com/hc/en-us/articles/360009063100-How-does-Automatic-Cookie-Blocking-work-).
145
+ 2. **Manual cookie-blocking mode** requests manual adjustments to the cookie-setting scripts. [Read more about the manual cookie-blocking mode](https://support.cookiebot.com/hc/en-us/articles/4405978132242-Manual-cookie-blocking).
146
+
147
+ ### What is the GDPR and the ePrivacy Directive? ####
148
+ The GDPR is the General Data Protection Regulation, an EU law enforced since May 2018. It protects EU citizens’ personal data globally and affects all organizations and websites that handle such data. If you have a website with users from the EU, and if your website uses cookies (it probably does), then you need to make your use of cookies and tracking compliant with the GDPR.
149
+
150
+ See the [EU GDPR homepage](https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=celex%3A32016R0679) for more information, or their infographic for businesses: [Data Protection: Better rules for small businesses](https://ec.europa.eu/justice/smedataprotect/index_en.htm).
151
+
152
+ The ePrivacy Directive is another EU legal instrument that specifically aims to protect EU citizens’ online data, such as data from online communication. It is in the process of becoming a full regulation like the GDPR.
153
+
154
+ ### What is the CCPA and CPRA? ###
155
+ The California Consumer Privacy Act (CCPA) is a state-wide law that regulates how businesses all over the world are allowed to handle the personal information of California residents. Starting from January 1, 2023 the California Privacy Rights Act (CPRA) comes into effect, amending and extending the CCPA.
156
 
157
  You are liable for CCPA compliance if your business:
158
 
159
+ Sells the personal information of more than 50,000 California residents per year (increased to 100,000 under the CPRA as of January 1st, 2023)
160
+ Has an annual gross revenue exceeding $25 million
161
+ Derives more than 50 percent of its annual revenue from the selling of personal information of California residents
162
 
163
+ Under the CPRA, compliance also applies to sharing as well as selling personal information. Cookies and other tracking technologies are classified as unique identifiers that form part of the CCPA’s definition of personal information.
164
 
165
+ If your business has a website, you must know and disclose to consumers, at or before the point of collection, the data you collect and which third parties you share it with. This can be done through the Cookiebot CMP cookie declaration that also features the required "Do Not Sell Or Share My Personal Information" link, so end users can opt out of having their data sold or shared.
166
 
167
+ If your website is visited by consumers under the age of 16, you are required by the CCPA and CPRA to first obtain their opt in. This can be done through Cookiebot CMP's CCPA opt-in banner.
168
 
169
+ Click [here](https://www.cookiebot.com/en/what-is-ccpa/) to find all the details about the CCPA and CPRA and how to achieve compliance.
170
 
171
  ### How do I make other plugins support Cookiebot? ###
 
172
 
173
+ If your favorite plugin doesn’t support Cookiebot CMP you are always welcome to ask the developer to add support for it.
174
+
175
+ Send an email to the plugin developer you want to support Cookiebot and request that support for Cookiebot CMP be added. Cookiebot provides a helper function to check if there is an active, working version of Cookiebot CMP on the website.
176
 
177
+ The easiest way for a developer to implement Cookiebot CMP support is following to add a check where tags are outputted to the visitor. This can be done following way:
178
 
179
+ $scriptTag = ”;
180
+ if(function_exists(cookiebot_active) && cookiebot_active()) {
181
+ $scriptTag = ‘<script’.cookiebot_assist(statistics).’>’;
182
  }
183
 
184
+ The developer of the plugin can see more details on our [Github repository](https://github.com/CybotAS/CookiebotWP).
185
 
186
+ ### Can my website become compliant once I install Cookiebot CMP? ###
187
+ If you use our plugin version 3.0 or later and choose the automatic implementation, Cookiebot enables full compliance with the ‘prior consent’ requirement of the GDPR, the ePrivacy Directive (ePR) and similar privacy regulations for protection of user data around the world. Cookiebot CMP also enables compliance with the CCPA and CPRA through the implementation of the "Do Not Sell Or Share My Personal Information" link on a website’s cookie declaration, as well as the opt-in banner required if your website targets visitors under the age of 16.
188
+
189
+ The default consent banner has the strictest settings possible and is suitable for obtaining consent under both GDPR and the ePR. Make sure to adapt the consent banner content to fit your website. Check out our [GDPR checklist](https://support.cookiebot.com/hc/en-us/sections/360000917513-Ready-for-25-May-2018-GDPR-enforcement-date-A-Cookiebot-checklist-) if you have website visitors from the EU. If you are using server-side cookies, please check the [Server-side usage guide](https://www.cookiebot.com/en/developer/).
190
+
191
+ Be aware that Cookiebot CMP is customizable and therefore true compliance always depends on the settings that you make within the plugin and Cookiebot Manager.
192
+
193
+ **Are you using the manual implementation?** Please make sure to check if you are using plugins that set cookies which require consent. If so, you have to:
194
+ 1. Ask the plugin developers if they are planning on becoming GDPR/CCPA compliant, or if they would like to integrate with Cookiebot CMP. Check out our [Github repository](https://github.com/CybotAS/CookiebotAddons), where we are developing integrations for Cookiebot CMP, until the plugin developers choose to do this themselves, or if [WP Core](https://core.trac.wordpress.org/ticket/44043) enables such functionality.
195
+ 2. Once Cookiebot CMP is installed, you can check the [cookie report](https://manage.cookiebot.com/goto/reports) to identify all cookies being set on your website. If the cookies are coming from content that you have inserted manually, you can mark up that content [as described in our manual implementation guide step 4](https://cookiebot.com/goto/manual-implementation). Embedded videos and iframes which set cookies can be marked up as explained in our [iframe cookie consent with YouTube example](https://support.cookiebot.com/hc/en-us/articles/360003790854-Iframe-cookie-consent-with-YouTube-example).
196
+
197
+ Disclaimer: These statements do not constitute legal advice, but only serve to support and inform you about the Cookiebot CMP product. Please consult a qualified lawyer should you have any legal questions.
198
 
199
+ ### Can I use Cookiebot with Google Tag Manager? ###
200
+ Cookiebot works with GTM. There are two different options for setting up GTM with Cookiebot CMP:
201
 
202
+ Use the Google Tag Manager option in the plugin settings to enable GTM with Cookiebot. Here you also have the option to enable Google Consent Mode for GTM.
203
+ Add the GTM script manually or by using another plugin for your site.
204
+ Should you choose one of these methods, Cookiebot CMP must not be implemented using GTM as this would result in Cookiebot being loaded twice.
205
 
206
  If you prefer the latter method, you should select ´Hide Cookie Popup´ in the Cookiebot WordPress plugin settings.
207
 
208
  [Please see our article on how to deploy Cookiebot with GTM](https://support.cookiebot.com/hc/en-us/articles/360003793854-Google-Tag-Manager-deployment).
209
 
210
+ ### Can I use Cookiebot CMP with Google Consent Mode? ###
211
+
212
+ Yes the Cookiebot consent management platform (CMP) and Google Consent Mode integrate seamlessly. You can find more information on the implementation of Google Consent Mode [here](https://support.cookiebot.com/hc/en-us/articles/360016047000-Cookiebot-and-Google-Consent-Mode).
213
+
214
  ### Does Cookiebot integrate with WP Consent API? ###
215
+ Cookiebot is fully integrated with the WP Consent API. When your visitors give consent using Cookiebot CMP, the consent will automatically be sent to the [WP Consent API](https://wordpress.org/plugins/wp-consent-api/).
216
 
217
+ You can define the mapping between Cookiebot and the WP Consent API in the administration interface (Cookiebot WP plugin).
218
 
219
+ ### Does Cookiebot work with translation plugins? ###
220
+ Cookiebot CMP is compatible with translation plugins when you set language to Use WordPress Language”.
221
 
222
  ## Changelog ##
223
+ ### 4.2.1 - 2022-11-28 ###
224
+ * PHP 5.6 compatibility fix
225
+ * Code formatting update
226
+
227
+ ### 4.2.0 - 2022-11-28 ###
228
+ * Added new UI design
229
+ * Added multiple configurations
230
+ * Fixed PHP8 warnings when saving network settings.
231
+ * Activate Google Consent Mode by default
232
+
233
  ### 4.1.1 - 2022-07-01 ###
234
  * Fixed undefined variable src when using instagram embed
235
 
498
 
499
  ## Copyright and Trademarks ##
500
 
501
+ Cookiebot CMP by Usercentrics is a registered trademark of Usercentrics A/S
src/addons/config/Settings_Config.php CHANGED
@@ -25,6 +25,8 @@ class Settings_Config {
25
  */
26
  protected $settings_service;
27
 
 
 
28
  /**
29
  * Settings_Config constructor.
30
  *
@@ -42,7 +44,7 @@ class Settings_Config {
42
  * @since 1.3.0
43
  */
44
  public function load() {
45
- add_action( 'admin_menu', array( $this, 'add_submenu' ) );
46
  add_action( 'admin_init', array( $this, 'register_settings' ) );
47
  add_action( 'admin_enqueue_scripts', array( $this, 'add_wp_admin_style_script' ) );
48
  add_action(
@@ -64,15 +66,15 @@ class Settings_Config {
64
  public function add_submenu() {
65
  add_submenu_page(
66
  'cookiebot',
67
- esc_html__( 'Prior Consent', 'cookiebot' ),
68
- esc_html__( 'Prior Consent', 'cookiebot' ),
69
  'manage_options',
70
  'cookiebot-addons',
71
  array(
72
  $this,
73
  'setting_page',
74
  ),
75
- 40
76
  );
77
  }
78
 
@@ -108,7 +110,13 @@ class Settings_Config {
108
  );
109
  wp_enqueue_style(
110
  'cookiebot_addons_custom_css',
111
- asset_url( 'css/admin_styles.css' ),
 
 
 
 
 
 
112
  null,
113
  Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION
114
  );
@@ -129,18 +137,49 @@ class Settings_Config {
129
  if ( isset( $_GET['tab'] ) && 'unavailable_addons' === $_GET['tab'] ) {
130
  $this->register_unavailable_addons();
131
  // phpcs:ignore WordPress.Security.NonceVerification.Recommended
 
 
 
132
  } elseif ( ( isset( $_GET['tab'] ) && 'jetpack' === $_GET['tab'] ) ) {
133
  $this->register_jetpack_addon();
134
  } else {
135
- $this->register_available_addons();
136
  }
137
 
138
  if ( $pagenow === 'options.php' ) {
139
  $this->register_jetpack_addon();
 
140
  }
141
  }
142
  }
143
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
144
  /**
145
  * Register available addons
146
  *
@@ -150,7 +189,7 @@ class Settings_Config {
150
  private function register_available_addons() {
151
  add_settings_section(
152
  'available_addons',
153
- 'Available plugins',
154
  array(
155
  $this,
156
  'header_available_addons',
@@ -202,7 +241,7 @@ class Settings_Config {
202
  private function register_jetpack_addon() {
203
  add_settings_section(
204
  'jetpack_addon',
205
- 'Jetpack',
206
  array(
207
  $this,
208
  'jetpack_addons_header_callback',
@@ -253,7 +292,7 @@ class Settings_Config {
253
  private function register_unavailable_addons() {
254
  add_settings_section(
255
  'unavailable_addons',
256
- 'Unavailable plugins',
257
  array(
258
  $this,
259
  'unavailable_addons_header_callback',
@@ -385,15 +424,7 @@ class Settings_Config {
385
  * @since 1.3.0
386
  */
387
  public function header_available_addons() {
388
- ?>
389
- <p>
390
- <?php esc_html_e( 'Below is a list of addons for Cookiebot. Addons help you make installed plugins GDPR compliant.', 'cookiebot' ); ?>
391
- <br/>
392
- <?php esc_html_e( 'These addons are available because you have the corresponding plugins installed and activated.', 'cookiebot' ); ?>
393
- <br/>
394
- <?php esc_html_e( 'Deactivate an addon if you want to handle GDPR compliance yourself, or through another plugin.', 'cookiebot' ); ?>
395
- </p>
396
- <?php
397
  }
398
 
399
  /**
@@ -523,20 +554,28 @@ class Settings_Config {
523
  * @since 1.3.0
524
  */
525
  public function setting_page() {
 
 
 
 
 
 
 
526
  $available_addons_tab = new Settings_Page_Tab(
527
  'available_addons',
528
- esc_html__( 'Available Addons', 'cookiebot' ),
529
  'cookiebot_available_addons',
530
  'cookiebot-addons'
531
  );
532
  $unavailable_addons_tab = new Settings_Page_Tab(
533
  'unavailable_addons',
534
- esc_html__( 'Unavailable Addons', 'cookiebot' ),
535
  'cookiebot_not_installed_options',
536
  'cookiebot-addons',
537
  false
538
  );
539
  $settings_page_tabs = array(
 
540
  $available_addons_tab,
541
  $unavailable_addons_tab,
542
  );
@@ -562,8 +601,8 @@ class Settings_Config {
562
  null
563
  );
564
  if ( ! $active_tab ) {
565
- $available_addons_tab->set_is_active( true );
566
- $active_tab = $available_addons_tab;
567
  }
568
  $view_args = array(
569
  'settings_page_tabs' => $settings_page_tabs,
25
  */
26
  protected $settings_service;
27
 
28
+ const ADMIN_SLUG = 'cookiebot-addons';
29
+
30
  /**
31
  * Settings_Config constructor.
32
  *
44
  * @since 1.3.0
45
  */
46
  public function load() {
47
+ add_action( 'admin_menu', array( $this, 'add_submenu' ), 2 );
48
  add_action( 'admin_init', array( $this, 'register_settings' ) );
49
  add_action( 'admin_enqueue_scripts', array( $this, 'add_wp_admin_style_script' ) );
50
  add_action(
66
  public function add_submenu() {
67
  add_submenu_page(
68
  'cookiebot',
69
+ esc_html__( 'Plugins', 'cookiebot' ),
70
+ esc_html__( 'Plugins', 'cookiebot' ),
71
  'manage_options',
72
  'cookiebot-addons',
73
  array(
74
  $this,
75
  'setting_page',
76
  ),
77
+ 2
78
  );
79
  }
80
 
110
  );
111
  wp_enqueue_style(
112
  'cookiebot_addons_custom_css',
113
+ asset_url( 'css/backend/addons_page.css' ),
114
+ null,
115
+ Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION
116
+ );
117
+ wp_enqueue_style(
118
+ 'cookiebot_admin_css',
119
+ asset_url( 'css/backend/cookiebot_admin_main.css' ),
120
  null,
121
  Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION
122
  );
137
  if ( isset( $_GET['tab'] ) && 'unavailable_addons' === $_GET['tab'] ) {
138
  $this->register_unavailable_addons();
139
  // phpcs:ignore WordPress.Security.NonceVerification.Recommended
140
+ } elseif ( ( isset( $_GET['tab'] ) && 'available_addons' === $_GET['tab'] ) ) {
141
+ $this->register_available_addons();
142
+ // phpcs:ignore WordPress.Security.NonceVerification.Recommended
143
  } elseif ( ( isset( $_GET['tab'] ) && 'jetpack' === $_GET['tab'] ) ) {
144
  $this->register_jetpack_addon();
145
  } else {
146
+ $this->register_addons_info();
147
  }
148
 
149
  if ( $pagenow === 'options.php' ) {
150
  $this->register_jetpack_addon();
151
+ $this->register_available_addons();
152
  }
153
  }
154
  }
155
 
156
+ /**
157
+ * Register addons info
158
+ *
159
+ * @throws Exception
160
+ * @since 1.3.0
161
+ */
162
+ private function register_addons_info() {
163
+ add_settings_section(
164
+ 'info_addons',
165
+ '',
166
+ array(
167
+ $this,
168
+ 'header_addons_info',
169
+ ),
170
+ 'cookiebot-addons'
171
+ );
172
+ }
173
+
174
+ /**
175
+ * Returns header for info tab
176
+ *
177
+ * @since 1.3.0
178
+ */
179
+ public function header_addons_info() {
180
+ include_view( 'admin/settings/prior-consent/partials/info-tab-header.php' );
181
+ }
182
+
183
  /**
184
  * Register available addons
185
  *
189
  private function register_available_addons() {
190
  add_settings_section(
191
  'available_addons',
192
+ '',
193
  array(
194
  $this,
195
  'header_available_addons',
241
  private function register_jetpack_addon() {
242
  add_settings_section(
243
  'jetpack_addon',
244
+ '',
245
  array(
246
  $this,
247
  'jetpack_addons_header_callback',
292
  private function register_unavailable_addons() {
293
  add_settings_section(
294
  'unavailable_addons',
295
+ '',
296
  array(
297
  $this,
298
  'unavailable_addons_header_callback',
424
  * @since 1.3.0
425
  */
426
  public function header_available_addons() {
427
+ include_view( 'admin/settings/prior-consent/available-addons/tab-header.php' );
 
 
 
 
 
 
 
 
428
  }
429
 
430
  /**
554
  * @since 1.3.0
555
  */
556
  public function setting_page() {
557
+ $addons_info_tab = new Settings_Page_Tab(
558
+ 'addons_info',
559
+ esc_html__( 'Info', 'cookiebot' ),
560
+ 'info_addons',
561
+ 'cookiebot-addons',
562
+ false
563
+ );
564
  $available_addons_tab = new Settings_Page_Tab(
565
  'available_addons',
566
+ esc_html__( 'Available Add-ons', 'cookiebot' ),
567
  'cookiebot_available_addons',
568
  'cookiebot-addons'
569
  );
570
  $unavailable_addons_tab = new Settings_Page_Tab(
571
  'unavailable_addons',
572
+ esc_html__( 'Unavailable Add-ons', 'cookiebot' ),
573
  'cookiebot_not_installed_options',
574
  'cookiebot-addons',
575
  false
576
  );
577
  $settings_page_tabs = array(
578
+ $addons_info_tab,
579
  $available_addons_tab,
580
  $unavailable_addons_tab,
581
  );
601
  null
602
  );
603
  if ( ! $active_tab ) {
604
+ $addons_info_tab->set_is_active( true );
605
+ $active_tab = $addons_info_tab;
606
  }
607
  $view_args = array(
608
  'settings_page_tabs' => $settings_page_tabs,
src/addons/controller/addons/Base_Cookiebot_Addon.php CHANGED
@@ -90,10 +90,10 @@ abstract class Base_Cookiebot_Addon {
90
  }
91
 
92
  /**
93
- * @param Settings_Service_Interface $settings
94
  * @param Script_Loader_Tag_Interface $script_loader_tag
95
- * @param Cookie_Consent_Interface $cookie_consent
96
- * @param Buffer_Output_Interface $buffer_output
97
  *
98
  * @return Base_Cookiebot_Addon
99
  * @throws Exception
@@ -192,6 +192,7 @@ abstract class Base_Cookiebot_Addon {
192
 
193
  /**
194
  * Returns checked cookie types
 
195
  * @return array
196
  *
197
  * @since 1.3.0
90
  }
91
 
92
  /**
93
+ * @param Settings_Service_Interface $settings
94
  * @param Script_Loader_Tag_Interface $script_loader_tag
95
+ * @param Cookie_Consent_Interface $cookie_consent
96
+ * @param Buffer_Output_Interface $buffer_output
97
  *
98
  * @return Base_Cookiebot_Addon
99
  * @throws Exception
192
 
193
  /**
194
  * Returns checked cookie types
195
+ *
196
  * @return array
197
  *
198
  * @since 1.3.0
src/addons/controller/addons/add_to_any/Add_To_Any.php CHANGED
@@ -66,7 +66,7 @@ class Add_To_Any extends Base_Cookiebot_Plugin_Addon {
66
  'cookiebot_addon_add_to_any_content',
67
  ),
68
  1000
69
- ); //Ensure it is executed as the last filter
70
 
71
  add_filter(
72
  'the_excerpt',
@@ -75,7 +75,7 @@ class Add_To_Any extends Base_Cookiebot_Plugin_Addon {
75
  'cookiebot_addon_add_to_any_content',
76
  ),
77
  1000
78
- ); //Ensure it is executed as the last filter
79
  }
80
 
81
  /**
@@ -93,7 +93,7 @@ class Add_To_Any extends Base_Cookiebot_Plugin_Addon {
93
  /**
94
  * Display a placeholder on elements with "addtoany_share_save_container" class name.
95
  *
96
- * @param string $content
97
  *
98
  * @return string
99
  */
66
  'cookiebot_addon_add_to_any_content',
67
  ),
68
  1000
69
+ ); // Ensure it is executed as the last filter
70
 
71
  add_filter(
72
  'the_excerpt',
75
  'cookiebot_addon_add_to_any_content',
76
  ),
77
  1000
78
+ ); // Ensure it is executed as the last filter
79
  }
80
 
81
  /**
93
  /**
94
  * Display a placeholder on elements with "addtoany_share_save_container" class name.
95
  *
96
+ * @param string $content
97
  *
98
  * @return string
99
  */
src/addons/controller/addons/caos_host_analyticsjs_local/CAOS_Host_Analyticsjs_Local_Version_1_97.php CHANGED
@@ -19,7 +19,7 @@ class CAOS_Host_Analyticsjs_Local_Version_1_97 extends Base_Cookiebot_Plugin_Add
19
  /* Priority need to be more than 0, so we are able to hook in before output begins */
20
  $script_priority = $this->cookiebot_addon_host_analyticsjs_local_priority();
21
  if ( $script_priority <= 0 ) {
22
- //Force priority to 2
23
  $script_priority = 2;
24
  update_option( 'sgal_enqueue_order', $script_priority );
25
  }
19
  /* Priority need to be more than 0, so we are able to hook in before output begins */
20
  $script_priority = $this->cookiebot_addon_host_analyticsjs_local_priority();
21
  if ( $script_priority <= 0 ) {
22
+ // Force priority to 2
23
  $script_priority = 2;
24
  update_option( 'sgal_enqueue_order', $script_priority );
25
  }
src/addons/controller/addons/caos_host_analyticsjs_local/CAOS_Host_Analyticsjs_Local_Version_4_2_6.php CHANGED
@@ -19,7 +19,7 @@ class CAOS_Host_Analyticsjs_Local_Version_4_2_6 extends Base_Cookiebot_Plugin_Ad
19
  /* Priority need to be more than 0 so we are able to hook in before output begins */
20
  $script_priority = $this->cookiebot_addon_host_analyticsjs_local_priority();
21
  if ( $script_priority <= 0 ) {
22
- //Force priority to 2
23
  $script_priority = 2;
24
  update_option( 'sgal_enqueue_order', $script_priority );
25
  }
19
  /* Priority need to be more than 0 so we are able to hook in before output begins */
20
  $script_priority = $this->cookiebot_addon_host_analyticsjs_local_priority();
21
  if ( $script_priority <= 0 ) {
22
+ // Force priority to 2
23
  $script_priority = 2;
24
  update_option( 'sgal_enqueue_order', $script_priority );
25
  }
src/addons/controller/addons/custom_facebook_feed_pro/Custom_Facebook_Feed_Pro.php CHANGED
@@ -19,7 +19,7 @@ class Custom_Facebook_Feed_Pro extends Base_Cookiebot_Plugin_Addon {
19
  */
20
  public function load_addon_configuration() {
21
 
22
- //Remove cff_js action and replace it with our own
23
  if ( has_action( 'wp_footer', 'cff_js' ) ) {
24
  /**
25
  * Consent not given - no cache
19
  */
20
  public function load_addon_configuration() {
21
 
22
+ // Remove cff_js action and replace it with our own
23
  if ( has_action( 'wp_footer', 'cff_js' ) ) {
24
  /**
25
  * Consent not given - no cache
src/addons/controller/addons/embed_autocorrect/Embed_Autocorrect.php CHANGED
@@ -40,7 +40,7 @@ class Embed_Autocorrect extends Base_Cookiebot_Other_Addon {
40
  */
41
  public function cookiebot_addon_embed_autocorrect() {
42
 
43
- //add filters to handle autocorrection in content
44
  add_filter(
45
  'the_content',
46
  array(
@@ -48,9 +48,9 @@ class Embed_Autocorrect extends Base_Cookiebot_Other_Addon {
48
  'cookiebot_addon_embed_autocorrect_content',
49
  ),
50
  1000
51
- ); //Ensure it is executed as the last filter
52
 
53
- //add filters to handle autocorrection in widget text
54
  add_filter(
55
  'widget_text',
56
  array(
@@ -58,9 +58,9 @@ class Embed_Autocorrect extends Base_Cookiebot_Other_Addon {
58
  'cookiebot_addon_embed_autocorrect_content',
59
  ),
60
  1000
61
- ); //Ensure it is executed as the last filter
62
 
63
- //add fitler to handle video shortcodes
64
  add_filter(
65
  'wp_video_shortcode',
66
  array(
@@ -70,7 +70,7 @@ class Embed_Autocorrect extends Base_Cookiebot_Other_Addon {
70
  1000
71
  );
72
 
73
- //add fitler to handle audio shortcodes
74
  add_filter(
75
  'wp_audio_shortcode',
76
  array(
@@ -140,15 +140,15 @@ class Embed_Autocorrect extends Base_Cookiebot_Other_Addon {
140
  * @todo refactor this function, reduce duplicate code, fix the behaviour in places where variables are "probably undefined"
141
  */
142
  public function cookiebot_addon_embed_autocorrect_content( $content ) {
143
- //Make sure Cookiebot is active and the user has enabled autocorrection
144
 
145
  preg_match_all( '|<div[^>]*id=\"fb-root\">.*?</blockquote>|si', $content, $matches );
146
  foreach ( $matches[0] as $match ) {
147
- //Find src.
148
  preg_match( '|<a href=\"([^\"]*)\">([^<]*)</a></p></blockquote>|', $match, $match_src );
149
  $src = $match_src[1];
150
 
151
- //Replace - and add cookie consent notice.
152
  $adjusted = str_replace(
153
  '<script>',
154
  '<script type="text/plain" data-cookieconsent="' . cookiebot_addons_output_cookie_types( $this->get_cookie_types() ) . '">',
@@ -186,7 +186,7 @@ class Embed_Autocorrect extends Base_Cookiebot_Other_Addon {
186
 
187
  preg_match_all( '|<blockquote[^>]*class=\"twitter-tweet\"[^>]*>.*?</script>|si', $content, $matches );
188
  foreach ( $matches[0] as $match ) {
189
- //Find src.
190
  preg_match( '|<a href=\"([^\"]*)\">([^<]*)</a></blockquote>|', $match, $match_src );
191
 
192
  if ( empty( $match_src ) ) {
@@ -195,7 +195,7 @@ class Embed_Autocorrect extends Base_Cookiebot_Other_Addon {
195
 
196
  $src = $match_src[1];
197
 
198
- //Replace - and add cookie consent notice.
199
  $adjusted = str_replace(
200
  '<script ',
201
  '<script type="text/plain" data-cookieconsent="' . cookiebot_addons_output_cookie_types( $this->get_cookie_types() ) . '" ',
@@ -231,7 +231,7 @@ class Embed_Autocorrect extends Base_Cookiebot_Other_Addon {
231
  }
232
  unset( $matches );
233
 
234
- //Match all speakerdeck, slideshare, screencast, reverbnation, mixcloud, kickstarter,
235
  // dailymoition, collegehumor, cloudup, animoto, videopress, youtube, vimeo and facebook iframes.
236
  preg_match_all(
237
  $this->get_regex(),
@@ -292,14 +292,14 @@ class Embed_Autocorrect extends Base_Cookiebot_Other_Addon {
292
  foreach ( $matches[0] as $match ) {
293
  preg_match( '/src\s*=\s*"(.+?)"/', $match, $src );
294
 
295
- //$matches[1] will have the text that matched the first captured parenthesized
296
  if ( isset( $src[1] ) ) {
297
  $src = $src[1];
298
  } else {
299
  $src = '';
300
  }
301
 
302
- //Replace - and add cookie consent notice.
303
  $adjusted = str_replace(
304
  ' src=',
305
  ' data-cookieconsent="' . cookiebot_addons_output_cookie_types( $this->get_cookie_types() ) . '" data-src=',
@@ -337,6 +337,7 @@ class Embed_Autocorrect extends Base_Cookiebot_Other_Addon {
337
 
338
  /**
339
  * Implementation of filter wp_video_shortcode - fixing code for cookiebot.
 
340
  * @throws Exception
341
  */
342
  public function cookiebot_addon_embed_autocorrect_handle_video(
40
  */
41
  public function cookiebot_addon_embed_autocorrect() {
42
 
43
+ // add filters to handle autocorrection in content
44
  add_filter(
45
  'the_content',
46
  array(
48
  'cookiebot_addon_embed_autocorrect_content',
49
  ),
50
  1000
51
+ ); // Ensure it is executed as the last filter
52
 
53
+ // add filters to handle autocorrection in widget text
54
  add_filter(
55
  'widget_text',
56
  array(
58
  'cookiebot_addon_embed_autocorrect_content',
59
  ),
60
  1000
61
+ ); // Ensure it is executed as the last filter
62
 
63
+ // add fitler to handle video shortcodes
64
  add_filter(
65
  'wp_video_shortcode',
66
  array(
70
  1000
71
  );
72
 
73
+ // add fitler to handle audio shortcodes
74
  add_filter(
75
  'wp_audio_shortcode',
76
  array(
140
  * @todo refactor this function, reduce duplicate code, fix the behaviour in places where variables are "probably undefined"
141
  */
142
  public function cookiebot_addon_embed_autocorrect_content( $content ) {
143
+ // Make sure Cookiebot is active and the user has enabled autocorrection
144
 
145
  preg_match_all( '|<div[^>]*id=\"fb-root\">.*?</blockquote>|si', $content, $matches );
146
  foreach ( $matches[0] as $match ) {
147
+ // Find src.
148
  preg_match( '|<a href=\"([^\"]*)\">([^<]*)</a></p></blockquote>|', $match, $match_src );
149
  $src = $match_src[1];
150
 
151
+ // Replace - and add cookie consent notice.
152
  $adjusted = str_replace(
153
  '<script>',
154
  '<script type="text/plain" data-cookieconsent="' . cookiebot_addons_output_cookie_types( $this->get_cookie_types() ) . '">',
186
 
187
  preg_match_all( '|<blockquote[^>]*class=\"twitter-tweet\"[^>]*>.*?</script>|si', $content, $matches );
188
  foreach ( $matches[0] as $match ) {
189
+ // Find src.
190
  preg_match( '|<a href=\"([^\"]*)\">([^<]*)</a></blockquote>|', $match, $match_src );
191
 
192
  if ( empty( $match_src ) ) {
195
 
196
  $src = $match_src[1];
197
 
198
+ // Replace - and add cookie consent notice.
199
  $adjusted = str_replace(
200
  '<script ',
201
  '<script type="text/plain" data-cookieconsent="' . cookiebot_addons_output_cookie_types( $this->get_cookie_types() ) . '" ',
231
  }
232
  unset( $matches );
233
 
234
+ // Match all speakerdeck, slideshare, screencast, reverbnation, mixcloud, kickstarter,
235
  // dailymoition, collegehumor, cloudup, animoto, videopress, youtube, vimeo and facebook iframes.
236
  preg_match_all(
237
  $this->get_regex(),
292
  foreach ( $matches[0] as $match ) {
293
  preg_match( '/src\s*=\s*"(.+?)"/', $match, $src );
294
 
295
+ // $matches[1] will have the text that matched the first captured parenthesized
296
  if ( isset( $src[1] ) ) {
297
  $src = $src[1];
298
  } else {
299
  $src = '';
300
  }
301
 
302
+ // Replace - and add cookie consent notice.
303
  $adjusted = str_replace(
304
  ' src=',
305
  ' data-cookieconsent="' . cookiebot_addons_output_cookie_types( $this->get_cookie_types() ) . '" data-src=',
337
 
338
  /**
339
  * Implementation of filter wp_video_shortcode - fixing code for cookiebot.
340
+ *
341
  * @throws Exception
342
  */
343
  public function cookiebot_addon_embed_autocorrect_handle_video(
src/addons/controller/addons/facebook_for_woocommerce/Facebook_For_Woocommerce.php CHANGED
@@ -112,7 +112,7 @@ class Facebook_For_Woocommerce extends Base_Cookiebot_Plugin_Addon {
112
  /**
113
  * inject base pixel
114
  */
115
- //We always need to remove this untill consent is given - because we can force no execution before consent it given
116
  cookiebot_addons_remove_class_action( 'wp_footer', 'WC_Facebookcommerce_EventsTracker', 'inject_base_pixel_noscript' );
117
  }
118
 
112
  /**
113
  * inject base pixel
114
  */
115
+ // We always need to remove this untill consent is given - because we can force no execution before consent it given
116
  cookiebot_addons_remove_class_action( 'wp_footer', 'WC_Facebookcommerce_EventsTracker', 'inject_base_pixel_noscript' );
117
  }
118
 
src/addons/controller/addons/ga_google_analytics/Ga_Google_Analytics.php CHANGED
@@ -15,7 +15,7 @@ class Ga_Google_Analytics extends Base_Cookiebot_Plugin_Addon {
15
 
16
  public function load_addon_configuration() {
17
 
18
- //Remove GA Google action and replace it with our own
19
  if ( has_action( 'wp_head', 'ga_google_analytics_tracking_code' ) ) {
20
  $this->buffer_output->add_tag(
21
  'wp_head',
15
 
16
  public function load_addon_configuration() {
17
 
18
+ // Remove GA Google action and replace it with our own
19
  if ( has_action( 'wp_head', 'ga_google_analytics_tracking_code' ) ) {
20
  $this->buffer_output->add_tag(
21
  'wp_head',
src/addons/controller/addons/jetpack/Jetpack.php CHANGED
@@ -177,6 +177,7 @@ class Jetpack extends Base_Cookiebot_Plugin_Addon {
177
 
178
  /**
179
  * Returns default cookie types
 
180
  * @return array
181
  *
182
  * @since 1.5.0
177
 
178
  /**
179
  * Returns default cookie types
180
+ *
181
  * @return array
182
  *
183
  * @since 1.5.0
src/addons/controller/addons/jetpack/widget/Base_Jetpack_Widget.php CHANGED
@@ -62,10 +62,10 @@ abstract class Base_Jetpack_Widget {
62
  protected $buffer_output;
63
 
64
  /**
65
- * @param Settings_Service_Interface $settings
66
  * @param Script_Loader_Tag_Interface $script_loader_tag
67
- * @param Cookie_Consent_Interface $cookie_consent
68
- * @param Buffer_Output_Interface $buffer_output
69
  *
70
  * @throws Exception
71
  */
62
  protected $buffer_output;
63
 
64
  /**
65
+ * @param Settings_Service_Interface $settings
66
  * @param Script_Loader_Tag_Interface $script_loader_tag
67
+ * @param Cookie_Consent_Interface $cookie_consent
68
+ * @param Buffer_Output_Interface $buffer_output
69
  *
70
  * @throws Exception
71
  */
src/addons/controller/addons/jetpack/widget/Visitor_Cookies_Jetpack_Widget.php CHANGED
@@ -14,6 +14,7 @@ class Visitor_Cookies_Jetpack_Widget extends Base_Jetpack_Widget {
14
  /**
15
  * When consent is not given
16
  * Then disable comment cookies
 
17
  * @TODO is_cookie_state_accepted only accepts a string but an array is given, what should be the correct behaviour?
18
  */
19
  if ( ! $this->cookie_consent->is_cookie_state_accepted( $this->get_widget_cookie_types() ) ) {
@@ -56,6 +57,7 @@ class Visitor_Cookies_Jetpack_Widget extends Base_Jetpack_Widget {
56
  * - comment_author_{HASH}
57
  * - comment_author_email_{HASH}
58
  * - comment_author_url_{HASH}
 
59
  * @since 1.2.0
60
  */
61
  private function disable_comment_cookies() {
14
  /**
15
  * When consent is not given
16
  * Then disable comment cookies
17
+ *
18
  * @TODO is_cookie_state_accepted only accepts a string but an array is given, what should be the correct behaviour?
19
  */
20
  if ( ! $this->cookie_consent->is_cookie_state_accepted( $this->get_widget_cookie_types() ) ) {
57
  * - comment_author_{HASH}
58
  * - comment_author_email_{HASH}
59
  * - comment_author_url_{HASH}
60
+ *
61
  * @since 1.2.0
62
  */
63
  private function disable_comment_cookies() {
src/addons/controller/addons/litespeed_cache/Litespeed_Cache.php CHANGED
@@ -30,7 +30,7 @@ class Litespeed_Cache extends Base_Cookiebot_Plugin_Addon {
30
  /**
31
  * Exclude scripts from Litespeed cache’s defer JS option.
32
  *
33
- * @param array $excluded_files Array of script URLs to be excluded
34
  *
35
  * @return array Extended array script URLs to be excluded
36
  *
30
  /**
31
  * Exclude scripts from Litespeed cache’s defer JS option.
32
  *
33
+ * @param array $excluded_files Array of script URLs to be excluded
34
  *
35
  * @return array Extended array script URLs to be excluded
36
  *
src/addons/controller/addons/wp_google_analytics_events/Wp_Google_Analytics_Events.php CHANGED
@@ -29,6 +29,7 @@ class Wp_Google_Analytics_Events extends Base_Cookiebot_Plugin_Addon {
29
 
30
  /**
31
  * Returns default cookie types
 
32
  * @return array
33
  *
34
  * @since 1.5.0
29
 
30
  /**
31
  * Returns default cookie types
32
+ *
33
  * @return array
34
  *
35
  * @since 1.5.0
src/addons/controller/addons/wp_mautic/Wp_Mautic.php CHANGED
@@ -38,7 +38,7 @@ class Wp_Mautic extends Base_Cookiebot_Plugin_Addon {
38
  false
39
  );
40
 
41
- //Remove noscript tracking
42
  if ( has_action( 'wp_footer', 'wpmautic_inject_noscript' ) ) {
43
  remove_action( 'wp_footer', 'wpmautic_inject_noscript' );
44
  }
38
  false
39
  );
40
 
41
+ // Remove noscript tracking
42
  if ( has_action( 'wp_footer', 'wpmautic_inject_noscript' ) ) {
43
  remove_action( 'wp_footer', 'wpmautic_inject_noscript' );
44
  }
src/addons/controller/addons/wp_rocket/Wp_Rocket.php CHANGED
@@ -27,7 +27,7 @@ class Wp_Rocket extends Base_Cookiebot_Plugin_Addon {
27
  /**
28
  * Exclude scripts from WP Rocket’s defer JS option.
29
  *
30
- * @param array $excluded_files Array of script URLs to be excluded
31
  *
32
  * @return array Extended array script URLs to be excluded
33
  *
27
  /**
28
  * Exclude scripts from WP Rocket’s defer JS option.
29
  *
30
+ * @param array $excluded_files Array of script URLs to be excluded
31
  *
32
  * @return array Extended array script URLs to be excluded
33
  *
src/addons/controller/addons/wpforms/Wpforms.php CHANGED
@@ -96,7 +96,7 @@ class Wpforms extends Base_Cookiebot_Plugin_Addon {
96
  *
97
  * @param $key
98
  * @param $new_value
99
- * @param string $option
100
  */
101
  public function wpforms_set_setting( $key, $new_value, $option = 'wpforms_settings' ) {
102
  if ( function_exists( 'wpforms_sanitize_key' ) ) {
96
  *
97
  * @param $key
98
  * @param $new_value
99
+ * @param string $option
100
  */
101
  public function wpforms_set_setting( $key, $new_value, $option = 'wpforms_settings' ) {
102
  if ( function_exists( 'wpforms_sanitize_key' ) ) {
src/lib/Cookiebot_WP.php CHANGED
@@ -11,7 +11,7 @@ use cybot\cookiebot\widgets\Dashboard_Widget_Cookiebot_Status;
11
  use RuntimeException;
12
 
13
  class Cookiebot_WP {
14
- const COOKIEBOT_PLUGIN_VERSION = '4.1.1';
15
  const COOKIEBOT_MIN_PHP_VERSION = '5.6.0';
16
 
17
  /**
@@ -88,6 +88,8 @@ class Cookiebot_WP {
88
  ( new Widgets() )->register_hooks();
89
  ( new Cookiebot_Gutenberg_Declaration_Block() )->register_hooks();
90
  ( new WP_Rocket_Helper() )->register_hooks();
 
 
91
  }
92
 
93
  /**
@@ -152,4 +154,15 @@ class Cookiebot_WP {
152
 
153
  return false;
154
  }
 
 
 
 
 
 
 
 
 
 
 
155
  }
11
  use RuntimeException;
12
 
13
  class Cookiebot_WP {
14
+ const COOKIEBOT_PLUGIN_VERSION = '4.2.1';
15
  const COOKIEBOT_MIN_PHP_VERSION = '5.6.0';
16
 
17
  /**
88
  ( new Widgets() )->register_hooks();
89
  ( new Cookiebot_Gutenberg_Declaration_Block() )->register_hooks();
90
  ( new WP_Rocket_Helper() )->register_hooks();
91
+
92
+ $this->set_consent_mode_default();
93
  }
94
 
95
  /**
154
 
155
  return false;
156
  }
157
+
158
+ private function set_consent_mode_default() {
159
+ if ( ! get_option( 'cookiebot-gcm' ) && ! get_option( 'cookiebot-gcm-first-run' ) ) {
160
+ update_option( 'cookiebot-gcm', '1' );
161
+ }
162
+
163
+ if ( get_option( 'cookiebot-gcm' ) && ! get_option( 'cookiebot-gcm-first-run' ) ) {
164
+ update_option( 'cookiebot-gcm', '1' );
165
+ update_option( 'cookiebot-gcm-first-run', '1' );
166
+ }
167
+ }
168
  }
src/lib/Supported_Regions.php ADDED
@@ -0,0 +1,264 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace cybot\cookiebot\lib;
3
+
4
+ class Supported_Regions {
5
+
6
+ public static function get() {
7
+ $regions = array(
8
+ 'AW' => __( 'Aruba', 'cookiebot' ),
9
+ 'AF' => __( 'Afghanistan', 'cookiebot' ),
10
+ 'AO' => __( 'Angola', 'cookiebot' ),
11
+ 'AI' => __( 'Anguilla', 'cookiebot' ),
12
+ 'AX' => __( 'Åland Islands', 'cookiebot' ),
13
+ 'AL' => __( 'Albania', 'cookiebot' ),
14
+ 'AD' => __( 'Andorra', 'cookiebot' ),
15
+ 'AE' => __( 'United Arab Emirates', 'cookiebot' ),
16
+ 'AR' => __( 'Argentina', 'cookiebot' ),
17
+ 'AM' => __( 'Armenia', 'cookiebot' ),
18
+ 'AS' => __( 'American Samoa', 'cookiebot' ),
19
+ 'AQ' => __( 'Antarctica', 'cookiebot' ),
20
+ 'TF' => __( 'French Southern Territories', 'cookiebot' ),
21
+ 'AG' => __( 'Antigua and Barbuda', 'cookiebot' ),
22
+ 'AU' => __( 'Australia', 'cookiebot' ),
23
+ 'AT' => __( 'Austria', 'cookiebot' ),
24
+ 'AZ' => __( 'Azerbaijan', 'cookiebot' ),
25
+ 'BI' => __( 'Burundi', 'cookiebot' ),
26
+ 'BE' => __( 'Belgium', 'cookiebot' ),
27
+ 'BJ' => __( 'Benin', 'cookiebot' ),
28
+ 'BQ' => __( 'Bonaire, Sint Eustatius and Saba', 'cookiebot' ),
29
+ 'BF' => __( 'Burkina Faso', 'cookiebot' ),
30
+ 'BD' => __( 'Bangladesh', 'cookiebot' ),
31
+ 'BG' => __( 'Bulgaria', 'cookiebot' ),
32
+ 'BH' => __( 'Bahrain', 'cookiebot' ),
33
+ 'BS' => __( 'Bahamas', 'cookiebot' ),
34
+ 'BA' => __( 'Bosnia and Herzegovina', 'cookiebot' ),
35
+ 'BL' => __( 'Saint Barthélemy', 'cookiebot' ),
36
+ 'BY' => __( 'Belarus', 'cookiebot' ),
37
+ 'BZ' => __( 'Belize', 'cookiebot' ),
38
+ 'BM' => __( 'Bermuda', 'cookiebot' ),
39
+ 'BO' => __( 'Bolivia, Plurinational State of', 'cookiebot' ),
40
+ 'BR' => __( 'Brazil', 'cookiebot' ),
41
+ 'BB' => __( 'Barbados', 'cookiebot' ),
42
+ 'BN' => __( 'Brunei Darussalam', 'cookiebot' ),
43
+ 'BT' => __( 'Bhutan', 'cookiebot' ),
44
+ 'BV' => __( 'Bouvet Island', 'cookiebot' ),
45
+ 'BW' => __( 'Botswana', 'cookiebot' ),
46
+ 'CF' => __( 'Central African Republic', 'cookiebot' ),
47
+ 'CA' => __( 'Canada', 'cookiebot' ),
48
+ 'CC' => __( 'Cocos (Keeling) Islands', 'cookiebot' ),
49
+ 'CH' => __( 'Switzerland', 'cookiebot' ),
50
+ 'CL' => __( 'Chile', 'cookiebot' ),
51
+ 'CN' => __( 'China', 'cookiebot' ),
52
+ 'CI' => __( 'Côte d\'Ivoire', 'cookiebot' ),
53
+ 'CM' => __( 'Cameroon', 'cookiebot' ),
54
+ 'CD' => __( 'Congo, the Democratic Republic of the', 'cookiebot' ),
55
+ 'CG' => __( 'Congo', 'cookiebot' ),
56
+ 'CK' => __( 'Cook Islands', 'cookiebot' ),
57
+ 'CO' => __( 'Colombia', 'cookiebot' ),
58
+ 'KM' => __( 'Comoros', 'cookiebot' ),
59
+ 'CV' => __( 'Cape Verde', 'cookiebot' ),
60
+ 'CR' => __( 'Costa Rica', 'cookiebot' ),
61
+ 'CU' => __( 'Cuba', 'cookiebot' ),
62
+ 'CW' => __( 'Curaçao', 'cookiebot' ),
63
+ 'CX' => __( 'Christmas Island', 'cookiebot' ),
64
+ 'KY' => __( 'Cayman Islands', 'cookiebot' ),
65
+ 'CY' => __( 'Cyprus', 'cookiebot' ),
66
+ 'CZ' => __( 'Czech Republic', 'cookiebot' ),
67
+ 'DE' => __( 'Germany', 'cookiebot' ),
68
+ 'DJ' => __( 'Djibouti', 'cookiebot' ),
69
+ 'DM' => __( 'Dominica', 'cookiebot' ),
70
+ 'DK' => __( 'Denmark', 'cookiebot' ),
71
+ 'DO' => __( 'Dominican Republic', 'cookiebot' ),
72
+ 'DZ' => __( 'Algeria', 'cookiebot' ),
73
+ 'EC' => __( 'Ecuador', 'cookiebot' ),
74
+ 'EG' => __( 'Egypt', 'cookiebot' ),
75
+ 'ER' => __( 'Eritrea', 'cookiebot' ),
76
+ 'EH' => __( 'Western Sahara', 'cookiebot' ),
77
+ 'ES' => __( 'Spain', 'cookiebot' ),
78
+ 'EE' => __( 'Estonia', 'cookiebot' ),
79
+ 'ET' => __( 'Ethiopia', 'cookiebot' ),
80
+ 'FI' => __( 'Finland', 'cookiebot' ),
81
+ 'FJ' => __( 'Fiji', 'cookiebot' ),
82
+ 'FK' => __( 'Falkland Islands (Malvinas)', 'cookiebot' ),
83
+ 'FR' => __( 'France', 'cookiebot' ),
84
+ 'FO' => __( 'Faroe Islands', 'cookiebot' ),
85
+ 'FM' => __( 'Micronesia, Federated States of', 'cookiebot' ),
86
+ 'GA' => __( 'Gabon', 'cookiebot' ),
87
+ 'GB' => __( 'United Kingdom', 'cookiebot' ),
88
+ 'GE' => __( 'Georgia', 'cookiebot' ),
89
+ 'GG' => __( 'Guernsey', 'cookiebot' ),
90
+ 'GH' => __( 'Ghana', 'cookiebot' ),
91
+ 'GI' => __( 'Gibraltar', 'cookiebot' ),
92
+ 'GN' => __( 'Guinea', 'cookiebot' ),
93
+ 'GP' => __( 'Guadeloupe', 'cookiebot' ),
94
+ 'GM' => __( 'Gambia', 'cookiebot' ),
95
+ 'GW' => __( 'Guinea-Bissau', 'cookiebot' ),
96
+ 'GQ' => __( 'Equatorial Guinea', 'cookiebot' ),
97
+ 'GR' => __( 'Greece', 'cookiebot' ),
98
+ 'GD' => __( 'Grenada', 'cookiebot' ),
99
+ 'GL' => __( 'Greenland', 'cookiebot' ),
100
+ 'GT' => __( 'Guatemala', 'cookiebot' ),
101
+ 'GF' => __( 'French Guiana', 'cookiebot' ),
102
+ 'GU' => __( 'Guam', 'cookiebot' ),
103
+ 'GY' => __( 'Guyana', 'cookiebot' ),
104
+ 'HK' => __( 'Hong Kong', 'cookiebot' ),
105
+ 'HM' => __( 'Heard Island and McDonald Islands', 'cookiebot' ),
106
+ 'HN' => __( 'Honduras', 'cookiebot' ),
107
+ 'HR' => __( 'Croatia', 'cookiebot' ),
108
+ 'HT' => __( 'Haiti', 'cookiebot' ),
109
+ 'HU' => __( 'Hungary', 'cookiebot' ),
110
+ 'ID' => __( 'Indonesia', 'cookiebot' ),
111
+ 'IM' => __( 'Isle of Man', 'cookiebot' ),
112
+ 'IN' => __( 'India', 'cookiebot' ),
113
+ 'IO' => __( 'British Indian Ocean Territory', 'cookiebot' ),
114
+ 'IE' => __( 'Ireland', 'cookiebot' ),
115
+ 'IR' => __( 'Iran, Islamic Republic of', 'cookiebot' ),
116
+ 'IQ' => __( 'Iraq', 'cookiebot' ),
117
+ 'IS' => __( 'Iceland', 'cookiebot' ),
118
+ 'IL' => __( 'Israel', 'cookiebot' ),
119
+ 'IT' => __( 'Italy', 'cookiebot' ),
120
+ 'JM' => __( 'Jamaica', 'cookiebot' ),
121
+ 'JE' => __( 'Jersey', 'cookiebot' ),
122
+ 'JO' => __( 'Jordan', 'cookiebot' ),
123
+ 'JP' => __( 'Japan', 'cookiebot' ),
124
+ 'KZ' => __( 'Kazakhstan', 'cookiebot' ),
125
+ 'KE' => __( 'Kenya', 'cookiebot' ),
126
+ 'KG' => __( 'Kyrgyzstan', 'cookiebot' ),
127
+ 'KH' => __( 'Cambodia', 'cookiebot' ),
128
+ 'KI' => __( 'Kiribati', 'cookiebot' ),
129
+ 'KN' => __( 'Saint Kitts and Nevis', 'cookiebot' ),
130
+ 'KR' => __( 'North Korea', 'cookiebot' ),
131
+ 'KW' => __( 'Kuwait', 'cookiebot' ),
132
+ 'LA' => __( 'Lao People\'s Democratic Republic', 'cookiebot' ),
133
+ 'LB' => __( 'Lebanon', 'cookiebot' ),
134
+ 'LR' => __( 'Liberia', 'cookiebot' ),
135
+ 'LY' => __( 'Libya', 'cookiebot' ),
136
+ 'LC' => __( 'Saint Lucia', 'cookiebot' ),
137
+ 'LI' => __( 'Liechtenstein', 'cookiebot' ),
138
+ 'LK' => __( 'Sri Lanka', 'cookiebot' ),
139
+ 'LS' => __( 'Lesotho', 'cookiebot' ),
140
+ 'LT' => __( 'Lithuania', 'cookiebot' ),
141
+ 'LU' => __( 'Luxembourg', 'cookiebot' ),
142
+ 'LV' => __( 'Latvia', 'cookiebot' ),
143
+ 'MO' => __( 'Macao', 'cookiebot' ),
144
+ 'MF' => __( 'Saint Martin (French part)', 'cookiebot' ),
145
+ 'MA' => __( 'Morocco', 'cookiebot' ),
146
+ 'MC' => __( 'Monaco', 'cookiebot' ),
147
+ 'MD' => __( 'Moldova, Republic of', 'cookiebot' ),
148
+ 'MG' => __( 'Madagascar', 'cookiebot' ),
149
+ 'MV' => __( 'Maldives', 'cookiebot' ),
150
+ 'MX' => __( 'Mexico', 'cookiebot' ),
151
+ 'MH' => __( 'Marshall Islands', 'cookiebot' ),
152
+ 'MK' => __( 'Macedonia, the former Yugoslav Republic of', 'cookiebot' ),
153
+ 'ML' => __( 'Mali', 'cookiebot' ),
154
+ 'MT' => __( 'Malta', 'cookiebot' ),
155
+ 'MM' => __( 'Myanmar', 'cookiebot' ),
156
+ 'ME' => __( 'Montenegro', 'cookiebot' ),
157
+ 'MN' => __( 'Mongolia', 'cookiebot' ),
158
+ 'MP' => __( 'Northern Mariana Islands', 'cookiebot' ),
159
+ 'MZ' => __( 'Mozambique', 'cookiebot' ),
160
+ 'MR' => __( 'Mauritania', 'cookiebot' ),
161
+ 'MS' => __( 'Montserrat', 'cookiebot' ),
162
+ 'MQ' => __( 'Martinique', 'cookiebot' ),
163
+ 'MU' => __( 'Mauritius', 'cookiebot' ),
164
+ 'MW' => __( 'Malawi', 'cookiebot' ),
165
+ 'MY' => __( 'Malaysia', 'cookiebot' ),
166
+ 'YT' => __( 'Mayotte', 'cookiebot' ),
167
+ 'NA' => __( 'Namibia', 'cookiebot' ),
168
+ 'NC' => __( 'New Caledonia', 'cookiebot' ),
169
+ 'NE' => __( 'Niger', 'cookiebot' ),
170
+ 'NF' => __( 'Norfolk Island', 'cookiebot' ),
171
+ 'NG' => __( 'Nigeria', 'cookiebot' ),
172
+ 'NI' => __( 'Nicaragua', 'cookiebot' ),
173
+ 'NU' => __( 'Niue', 'cookiebot' ),
174
+ 'NL' => __( 'Netherlands', 'cookiebot' ),
175
+ 'NO' => __( 'Norway', 'cookiebot' ),
176
+ 'NP' => __( 'Nepal', 'cookiebot' ),
177
+ 'NR' => __( 'Nauru', 'cookiebot' ),
178
+ 'NZ' => __( 'New Zealand', 'cookiebot' ),
179
+ 'OM' => __( 'Oman', 'cookiebot' ),
180
+ 'PK' => __( 'Pakistan', 'cookiebot' ),
181
+ 'PA' => __( 'Panama', 'cookiebot' ),
182
+ 'PN' => __( 'Pitcairn', 'cookiebot' ),
183
+ 'PE' => __( 'Peru', 'cookiebot' ),
184
+ 'PH' => __( 'Philippines', 'cookiebot' ),
185
+ 'PW' => __( 'Palau', 'cookiebot' ),
186
+ 'PG' => __( 'Papua New Guinea', 'cookiebot' ),
187
+ 'PL' => __( 'Poland', 'cookiebot' ),
188
+ 'PR' => __( 'Puerto Rico', 'cookiebot' ),
189
+ 'KP' => __( 'South Korea', 'cookiebot' ),
190
+ 'PT' => __( 'Portugal', 'cookiebot' ),
191
+ 'PY' => __( 'Paraguay', 'cookiebot' ),
192
+ 'PS' => __( 'Palestinian Territory', 'cookiebot' ),
193
+ 'PF' => __( 'French Polynesia', 'cookiebot' ),
194
+ 'QA' => __( 'Qatar', 'cookiebot' ),
195
+ 'RE' => __( 'Réunion', 'cookiebot' ),
196
+ 'RO' => __( 'Romania', 'cookiebot' ),
197
+ 'RU' => __( 'Russia', 'cookiebot' ),
198
+ 'RW' => __( 'Rwanda', 'cookiebot' ),
199
+ 'SA' => __( 'Saudi Arabia', 'cookiebot' ),
200
+ 'SD' => __( 'Sudan', 'cookiebot' ),
201
+ 'SN' => __( 'Senegal', 'cookiebot' ),
202
+ 'SG' => __( 'Singapore', 'cookiebot' ),
203
+ 'GS' => __( 'South Georgia and the South Sandwich Islands', 'cookiebot' ),
204
+ 'SH' => __( 'Saint Helena, Ascension and Tristan da Cunha', 'cookiebot' ),
205
+ 'SJ' => __( 'Svalbard and Jan Mayen', 'cookiebot' ),
206
+ 'SB' => __( 'Solomon Islands', 'cookiebot' ),
207
+ 'SL' => __( 'Sierra Leone', 'cookiebot' ),
208
+ 'SV' => __( 'El Salvador', 'cookiebot' ),
209
+ 'SM' => __( 'San Marino', 'cookiebot' ),
210
+ 'SO' => __( 'Somalia', 'cookiebot' ),
211
+ 'PM' => __( 'Saint Pierre and Miquelon', 'cookiebot' ),
212
+ 'RS' => __( 'Serbia', 'cookiebot' ),
213
+ 'SS' => __( 'South Sudan', 'cookiebot' ),
214
+ 'ST' => __( 'Sao Tome and Principe', 'cookiebot' ),
215
+ 'SR' => __( 'Suriname', 'cookiebot' ),
216
+ 'SK' => __( 'Slovakia', 'cookiebot' ),
217
+ 'SI' => __( 'Slovenia', 'cookiebot' ),
218
+ 'SE' => __( 'Sweden', 'cookiebot' ),
219
+ 'SZ' => __( 'Swaziland', 'cookiebot' ),
220
+ 'SX' => __( 'Sint Maarten (Dutch part)', 'cookiebot' ),
221
+ 'SC' => __( 'Seychelles', 'cookiebot' ),
222
+ 'SY' => __( 'Syrian Arab Republic', 'cookiebot' ),
223
+ 'TC' => __( 'Turks and Caicos Islands', 'cookiebot' ),
224
+ 'TD' => __( 'Chad', 'cookiebot' ),
225
+ 'TG' => __( 'Togo', 'cookiebot' ),
226
+ 'TH' => __( 'Thailand', 'cookiebot' ),
227
+ 'TJ' => __( 'Tajikistan', 'cookiebot' ),
228
+ 'TK' => __( 'Tokelau', 'cookiebot' ),
229
+ 'TM' => __( 'Turkmenistan', 'cookiebot' ),
230
+ 'TL' => __( 'Timor-Leste', 'cookiebot' ),
231
+ 'TO' => __( 'Tonga', 'cookiebot' ),
232
+ 'TT' => __( 'Trinidad and Tobago', 'cookiebot' ),
233
+ 'TN' => __( 'Tunisia', 'cookiebot' ),
234
+ 'TR' => __( 'Turkey', 'cookiebot' ),
235
+ 'TV' => __( 'Tuvalu', 'cookiebot' ),
236
+ 'TW' => __( 'Taiwan, Province of China', 'cookiebot' ),
237
+ 'TZ' => __( 'Tanzania, United Republic of', 'cookiebot' ),
238
+ 'UG' => __( 'Uganda', 'cookiebot' ),
239
+ 'UA' => __( 'Ukraine', 'cookiebot' ),
240
+ 'UM' => __( 'United States Minor Outlying Islands', 'cookiebot' ),
241
+ 'UY' => __( 'Uruguay', 'cookiebot' ),
242
+ 'US' => __( 'United States', 'cookiebot' ),
243
+ 'US-06' => __( 'United States - State of California', 'cookiebot' ),
244
+ 'UZ' => __( 'Uzbekistan', 'cookiebot' ),
245
+ 'VA' => __( 'Holy See (Vatican City State)', 'cookiebot' ),
246
+ 'VC' => __( 'Saint Vincent and the Grenadines', 'cookiebot' ),
247
+ 'VE' => __( 'Venezuela, Bolivarian Republic of', 'cookiebot' ),
248
+ 'VG' => __( 'Virgin Islands, British', 'cookiebot' ),
249
+ 'VI' => __( 'Virgin Islands, U.S.', 'cookiebot' ),
250
+ 'VN' => __( 'Viet Nam', 'cookiebot' ),
251
+ 'VU' => __( 'Vanuatu', 'cookiebot' ),
252
+ 'WF' => __( 'Wallis and Futuna', 'cookiebot' ),
253
+ 'WS' => __( 'Samoa', 'cookiebot' ),
254
+ 'YE' => __( 'Yemen', 'cookiebot' ),
255
+ 'ZA' => __( 'South Africa', 'cookiebot' ),
256
+ 'ZM' => __( 'Zambia', 'cookiebot' ),
257
+ 'ZW' => __( 'Zimbabwe', 'cookiebot' ),
258
+ );
259
+
260
+ asort( $regions );
261
+
262
+ return $regions;
263
+ }
264
+ }
src/settings/Menu_Settings.php CHANGED
@@ -2,6 +2,7 @@
2
 
3
  namespace cybot\cookiebot\settings;
4
 
 
5
  use cybot\cookiebot\settings\pages\Debug_Page;
6
  use cybot\cookiebot\settings\pages\Gtm_Page;
7
  use cybot\cookiebot\settings\pages\Iab_Page;
@@ -12,21 +13,19 @@ use cybot\cookiebot\settings\pages\Support_Page;
12
  class Menu_Settings {
13
 
14
  const MENU = array(
 
15
  Settings_Page::class,
16
  );
17
 
18
  const SUBMENU = array(
19
  Support_Page::class,
20
- Gtm_Page::class,
21
- Iab_Page::class,
22
- Legislations_Page::class,
23
  Debug_Page::class,
24
  );
25
 
26
  public function add_menu() {
27
  add_action( 'admin_menu', array( $this, 'load_menu' ), 1 );
28
 
29
- //Register settings
30
  add_action( 'admin_init', array( $this, 'register_cookiebot_settings' ) );
31
  }
32
 
@@ -58,12 +57,16 @@ class Menu_Settings {
58
  register_setting( 'cookiebot', 'cookiebot-script-tag-cd-attribute' );
59
  register_setting( 'cookiebot', 'cookiebot-cookie-blocking-mode' );
60
  register_setting( 'cookiebot', 'cookiebot-consent-mapping' );
61
- register_setting( 'cookiebot-iab', 'cookiebot-iab' );
62
- register_setting( 'cookiebot-legislations', 'cookiebot-ccpa' );
63
  register_setting( 'cookiebot-legislations', 'cookiebot-ccpa-domain-group-id' );
64
- register_setting( 'cookiebot-gtm', 'cookiebot-gtm' );
65
- register_setting( 'cookiebot-gtm', 'cookiebot-gtm-id' );
66
- register_setting( 'cookiebot-gtm', 'cookiebot-data-layer' );
67
- register_setting( 'cookiebot-gtm', 'cookiebot-gcm' );
 
 
 
 
68
  }
69
  }
2
 
3
  namespace cybot\cookiebot\settings;
4
 
5
+ use cybot\cookiebot\settings\pages\Dashboard_Page;
6
  use cybot\cookiebot\settings\pages\Debug_Page;
7
  use cybot\cookiebot\settings\pages\Gtm_Page;
8
  use cybot\cookiebot\settings\pages\Iab_Page;
13
  class Menu_Settings {
14
 
15
  const MENU = array(
16
+ Dashboard_Page::class,
17
  Settings_Page::class,
18
  );
19
 
20
  const SUBMENU = array(
21
  Support_Page::class,
 
 
 
22
  Debug_Page::class,
23
  );
24
 
25
  public function add_menu() {
26
  add_action( 'admin_menu', array( $this, 'load_menu' ), 1 );
27
 
28
+ // Register settings
29
  add_action( 'admin_init', array( $this, 'register_cookiebot_settings' ) );
30
  }
31
 
57
  register_setting( 'cookiebot', 'cookiebot-script-tag-cd-attribute' );
58
  register_setting( 'cookiebot', 'cookiebot-cookie-blocking-mode' );
59
  register_setting( 'cookiebot', 'cookiebot-consent-mapping' );
60
+ register_setting( 'cookiebot', 'cookiebot-iab' );
61
+ register_setting( 'cookiebot', 'cookiebot-ccpa' );
62
  register_setting( 'cookiebot-legislations', 'cookiebot-ccpa-domain-group-id' );
63
+ register_setting( 'cookiebot', 'cookiebot-gtm' );
64
+ register_setting( 'cookiebot', 'cookiebot-gtm-id' );
65
+ register_setting( 'cookiebot', 'cookiebot-data-layer' );
66
+ register_setting( 'cookiebot', 'cookiebot-gcm' );
67
+ register_setting( 'cookiebot', 'cookiebot-gcm-first-run' );
68
+ register_setting( 'cookiebot', 'cookiebot-multiple-config' );
69
+ register_setting( 'cookiebot', 'cookiebot-second-banner-regions' );
70
+ register_setting( 'cookiebot', 'cookiebot-second-banner-id' );
71
  }
72
  }
src/settings/Network_Menu_Settings.php CHANGED
@@ -65,13 +65,13 @@ class Network_Menu_Settings {
65
  public function network_settings_save() {
66
  check_admin_referer( 'cookiebot-network-settings' );
67
 
68
- update_site_option( 'cookiebot-cbid', $_POST['cookiebot-cbid'] );
69
- update_site_option( 'cookiebot-script-tag-uc-attribute', $_POST['cookiebot-script-tag-uc-attribute'] );
70
- update_site_option( 'cookiebot-script-tag-cd-attribute', $_POST['cookiebot-script-tag-cd-attribute'] );
71
- update_site_option( 'cookiebot-autoupdate', $_POST['cookiebot-autoupdate'] );
72
- update_site_option( 'cookiebot-nooutput', $_POST['cookiebot-nooutput'] );
73
- update_site_option( 'cookiebot-nooutput-admin', $_POST['cookiebot-nooutput-admin'] );
74
- update_site_option( 'cookiebot-cookie-blocking-mode', $_POST['cookiebot-cookie-blocking-mode'] );
75
 
76
  wp_safe_redirect(
77
  add_query_arg(
@@ -109,6 +109,13 @@ class Network_Menu_Settings {
109
  'before'
110
  );
111
 
 
 
 
 
 
 
 
112
  include_view(
113
  'admin/settings/network-settings-page.php',
114
  array(
65
  public function network_settings_save() {
66
  check_admin_referer( 'cookiebot-network-settings' );
67
 
68
+ update_site_option( 'cookiebot-cbid', ! empty( $_POST['cookiebot-cbid'] ) ? $_POST['cookiebot-cbid'] : '' );
69
+ update_site_option( 'cookiebot-script-tag-uc-attribute', ! empty( $_POST['cookiebot-script-tag-uc-attribute'] ) ? $_POST['cookiebot-script-tag-uc-attribute'] : '' );
70
+ update_site_option( 'cookiebot-script-tag-cd-attribute', ! empty( $_POST['cookiebot-script-tag-cd-attribute'] ) ? $_POST['cookiebot-script-tag-cd-attribute'] : '' );
71
+ update_site_option( 'cookiebot-autoupdate', ! empty( $_POST['cookiebot-autoupdate'] ) ? $_POST['cookiebot-autoupdate'] : '' );
72
+ update_site_option( 'cookiebot-nooutput', ! empty( $_POST['cookiebot-nooutput'] ) ? $_POST['cookiebot-nooutput'] : '' );
73
+ update_site_option( 'cookiebot-nooutput-admin', ! empty( $_POST['cookiebot-nooutput-admin'] ) ? $_POST['cookiebot-nooutput-admin'] : '' );
74
+ update_site_option( 'cookiebot-cookie-blocking-mode', ! empty( $_POST['cookiebot-cookie-blocking-mode'] ) ? $_POST['cookiebot-cookie-blocking-mode'] : '' );
75
 
76
  wp_safe_redirect(
77
  add_query_arg(
109
  'before'
110
  );
111
 
112
+ wp_enqueue_style(
113
+ 'cookiebot-settings-page-css',
114
+ asset_url( 'css/backend/settings-page.css' ),
115
+ null,
116
+ Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION
117
+ );
118
+
119
  include_view(
120
  'admin/settings/network-settings-page.php',
121
  array(
src/settings/pages/Dashboard_Page.php ADDED
@@ -0,0 +1,71 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace cybot\cookiebot\settings\pages;
4
+
5
+ use cybot\cookiebot\lib\Cookiebot_WP;
6
+ use InvalidArgumentException;
7
+ use function cybot\cookiebot\lib\asset_url;
8
+ use function cybot\cookiebot\lib\include_view;
9
+
10
+ class Dashboard_Page implements Settings_Page_Interface {
11
+
12
+
13
+ const ICON = 'data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgNzIgNTQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbD0iI0ZGRkZGRiIgZmlsbC1ydWxlPSJldmVub2RkIj48cGF0aCBkPSJNNDYuODcyNTkwMyA4Ljc3MzU4MzM0QzQxLjk0MzkwMzkgMy4zODI5NTAxMSAzNC44NDI0OTQ2IDAgMjYuOTQ4MjgxOSAwIDEyLjA2NTE1NjggMCAwIDEyLjAyNDQ3NzQgMCAyNi44NTc0MjE5YzAgMTQuODMyOTQ0NSAxMi4wNjUxNTY4IDI2Ljg1NzQyMTkgMjYuOTQ4MjgxOSAyNi44NTc0MjE5IDcuODk0MjEyNyAwIDE0Ljk5NTYyMi0zLjM4Mjk1MDIgMTkuOTI0MzA4NC04Ljc3MzU4MzQtMi44ODk2OTY3LTEuMzY4ODY2My01LjM5OTMxMS0zLjQwNTQzOS03LjMyODA4MzgtNS45MDk2MzU4LTMuMTIxNDMwNiAzLjIwOTQxMDQtNy40OTI5OTQ0IDUuMjA0MTI5MS0xMi4zMzIwMjU4IDUuMjA0MTI5MS05LjQ4NDM0NDQgMC0xNy4xNzI5MjQ3LTcuNjYyNjU3Mi0xNy4xNzI5MjQ3LTE3LjExNTAyMzhzNy42ODg1ODAzLTE3LjExNTAyMzcgMTcuMTcyOTI0Ny0xNy4xMTUwMjM3YzQuNzIzNDgyMiAwIDkuMDAxNTU1MiAxLjkwMDU5MzkgMTIuMTA2MjkyIDQuOTc2MzA5IDEuOTU2OTIzNy0yLjY0MTEzMSA0LjU1MDAyNjMtNC43ODU1MTgzIDcuNTUzODE3Ni02LjIwODQzMTg2eiIvPjxwYXRoIGQ9Ik01NS4zODAzMjgyIDQyLjY1MDE5OTFDNDYuMzMzNzIyNyA0Mi42NTAxOTkxIDM5IDM1LjM0MTIwMzEgMzkgMjYuMzI1MDk5NiAzOSAxNy4zMDg5OTYgNDYuMzMzNzIyNyAxMCA1NS4zODAzMjgyIDEwYzkuMDQ2NjA1NSAwIDE2LjM4MDMyODIgNy4zMDg5OTYgMTYuMzgwMzI4MiAxNi4zMjUwOTk2IDAgOS4wMTYxMDM1LTcuMzMzNzIyNyAxNi4zMjUwOTk1LTE2LjM4MDMyODIgMTYuMzI1MDk5NXptLjAyMTMwOTItNy43NTU2MzQyYzQuNzM3MDI3NiAwIDguNTc3MTQ3MS0zLjgyNzE3MiA4LjU3NzE0NzEtOC41NDgyMjc5IDAtNC43MjEwNTYtMy44NDAxMTk1LTguNTQ4MjI4LTguNTc3MTQ3MS04LjU0ODIyOC00LjczNzAyNzUgMC04LjU3NzE0NyAzLjgyNzE3Mi04LjU3NzE0NyA4LjU0ODIyOCAwIDQuNzIxMDU1OSAzLjg0MDExOTUgOC41NDgyMjc5IDguNTc3MTQ3IDguNTQ4MjI3OXoiLz48L2c+PC9zdmc+';
14
+
15
+ const ADMIN_SLUG = 'cookiebot';
16
+
17
+ public function menu() {
18
+ add_menu_page(
19
+ 'Cookiebot',
20
+ __( 'Cookiebot', 'cookiebot' ),
21
+ 'manage_options',
22
+ self::ADMIN_SLUG,
23
+ array(
24
+ $this,
25
+ 'display',
26
+ )
27
+ );
28
+
29
+ add_submenu_page(
30
+ 'cookiebot',
31
+ __( 'Cookiebot Dashboard', 'cookiebot' ),
32
+ __( 'Dashboard', 'cookiebot' ),
33
+ 'manage_options',
34
+ self::ADMIN_SLUG,
35
+ array(
36
+ $this,
37
+ 'display',
38
+ ),
39
+ 1
40
+ );
41
+ }
42
+
43
+ /**
44
+ * @throws InvalidArgumentException
45
+ */
46
+ public function display() {
47
+ $args = array(
48
+ 'cbid' => Cookiebot_WP::get_cbid(),
49
+ 'cb_wp' => asset_url( 'img/cb-wp.png' ),
50
+ 'europe_icon' => asset_url( 'img/europe.png' ),
51
+ 'usa_icon' => asset_url( 'img/usa.png' ),
52
+ 'check_icon' => asset_url( 'img/icons/check.svg' ),
53
+ 'link_icon' => asset_url( 'img/icons/link.svg' ),
54
+ );
55
+
56
+ $style_sheets = array(
57
+ array( 'cookiebot-dashboard-css', 'css/backend/dashboard_page.css' ),
58
+ );
59
+
60
+ foreach ( $style_sheets as $style ) {
61
+ wp_enqueue_style(
62
+ $style[0],
63
+ asset_url( $style[1] ),
64
+ null,
65
+ Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION
66
+ );
67
+ }
68
+
69
+ include_view( 'admin/settings/dashboard-page.php', $args );
70
+ }
71
+ }
src/settings/pages/Debug_Page.php CHANGED
@@ -17,14 +17,17 @@ use Exception;
17
 
18
  class Debug_Page implements Settings_Page_Interface {
19
 
 
 
20
  public function menu() {
21
  add_submenu_page(
22
  'cookiebot',
23
  __( 'Debug info', 'cookiebot' ),
24
  __( 'Debug info', 'cookiebot' ),
25
  'manage_options',
26
- 'cookiebot_debug',
27
- array( $this, 'display' )
 
28
  );
29
  }
30
 
@@ -39,6 +42,20 @@ class Debug_Page implements Settings_Page_Interface {
39
  Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION,
40
  true
41
  );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
42
  $debug_output = $this->prepare_debug_data();
43
 
44
  include_view( 'admin/settings/debug-page.php', array( 'debug_output' => $debug_output ) );
17
 
18
  class Debug_Page implements Settings_Page_Interface {
19
 
20
+ const ADMIN_SLUG = 'cookiebot_debug';
21
+
22
  public function menu() {
23
  add_submenu_page(
24
  'cookiebot',
25
  __( 'Debug info', 'cookiebot' ),
26
  __( 'Debug info', 'cookiebot' ),
27
  'manage_options',
28
+ self::ADMIN_SLUG,
29
+ array( $this, 'display' ),
30
+ 25
31
  );
32
  }
33
 
42
  Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION,
43
  true
44
  );
45
+
46
+ $style_sheets = array(
47
+ array( 'cookiebot-debug-css', 'css/backend/debug_info.css' ),
48
+ );
49
+
50
+ foreach ( $style_sheets as $style ) {
51
+ wp_enqueue_style(
52
+ $style[0],
53
+ asset_url( $style[1] ),
54
+ null,
55
+ Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION
56
+ );
57
+ }
58
+
59
  $debug_output = $this->prepare_debug_data();
60
 
61
  include_view( 'admin/settings/debug-page.php', array( 'debug_output' => $debug_output ) );
src/settings/pages/Gtm_Page.php CHANGED
@@ -9,28 +9,12 @@ use function cybot\cookiebot\lib\include_view;
9
 
10
  class Gtm_Page implements Settings_Page_Interface {
11
 
12
- public function menu() {
13
- add_submenu_page(
14
- 'cookiebot',
15
- __( 'Google Tag Manager', 'cookiebot' ),
16
- __( 'Google Tag Manager', 'cookiebot' ),
17
- 'manage_options',
18
- 'cookiebot_GTM',
19
- array( $this, 'display' )
20
- );
21
- }
22
 
23
  /**
24
  * @throws InvalidArgumentException
25
  */
26
  public function display() {
27
  include_view( 'admin/settings/gtm-page.php', array() );
28
-
29
- wp_enqueue_style(
30
- 'cookiebot-gtm-page-css',
31
- asset_url( 'css/backend/gtm_page.css' ),
32
- null,
33
- Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION
34
- );
35
  }
36
  }
9
 
10
  class Gtm_Page implements Settings_Page_Interface {
11
 
12
+
 
 
 
 
 
 
 
 
 
13
 
14
  /**
15
  * @throws InvalidArgumentException
16
  */
17
  public function display() {
18
  include_view( 'admin/settings/gtm-page.php', array() );
 
 
 
 
 
 
 
19
  }
20
  }
src/settings/pages/Multiple_Page.php ADDED
@@ -0,0 +1,81 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace cybot\cookiebot\settings\pages;
4
+
5
+ use cybot\cookiebot\lib\Cookiebot_WP;
6
+ use cybot\cookiebot\lib\Supported_Regions;
7
+ use InvalidArgumentException;
8
+ use function cybot\cookiebot\lib\asset_url;
9
+ use function cybot\cookiebot\lib\include_view;
10
+
11
+ class Multiple_Page implements Settings_Page_Interface {
12
+
13
+ private function selectedRegionList() {
14
+ $countries = Supported_Regions::get();
15
+ $list = explode( ', ', esc_attr( get_option( 'cookiebot-second-banner-regions' ) ) );
16
+ $ccpa = esc_attr( get_option( 'cookiebot-ccpa' ) );
17
+
18
+ if ( $ccpa === '1' && ! in_array( 'US-06', $list, true ) ) {
19
+ array_push( $list, 'US-06' );
20
+ }
21
+
22
+ $selected = array();
23
+
24
+ foreach ( $list as $item ) {
25
+ if ( isset( $countries[ $item ] ) ) {
26
+ $selected[ $item ] = $countries[ $item ];
27
+ }
28
+ }
29
+
30
+ return $selected;
31
+ }
32
+
33
+ private function retroSecondaryId() {
34
+ $ccpa_group_id = esc_attr( get_option( 'cookiebot-ccpa-domain-group-id' ) );
35
+ $secondary_group_id = esc_attr( get_option( 'cookiebot-second-banner-id' ) );
36
+
37
+ if ( $ccpa_group_id && ! $secondary_group_id ) {
38
+ $secondary_group_id = $ccpa_group_id;
39
+ update_option( 'cookiebot-second-banner-id', $ccpa_group_id );
40
+ delete_option( 'cookiebot-ccpa-domain-group-id' );
41
+ }
42
+
43
+ return $secondary_group_id;
44
+ }
45
+
46
+ public function getCountryName( $code ) {
47
+ $countries = Supported_Regions::get();
48
+
49
+ return $countries[ $code ];
50
+ }
51
+
52
+ /**
53
+ * @throws InvalidArgumentException
54
+ */
55
+ public function display() {
56
+ $args = array(
57
+ 'cbid' => Cookiebot_WP::get_cbid(),
58
+ 'secondary_group_id' => $this->retroSecondaryId(),
59
+ 'supported_regions' => Supported_Regions::get(),
60
+ 'ccpa_compatibility' => esc_attr( get_option( 'cookiebot-ccpa' ) ),
61
+ 'selected_regions' => $this->selectedRegionList(),
62
+ );
63
+
64
+ wp_enqueue_style(
65
+ 'cookiebot-multiple-page-css',
66
+ asset_url( 'css/backend/multiple_page.css' ),
67
+ null,
68
+ Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION
69
+ );
70
+
71
+ wp_enqueue_script(
72
+ 'cookiebot-multiple-page-js',
73
+ asset_url( 'js/backend/multiple-page.js' ),
74
+ null,
75
+ Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION,
76
+ true
77
+ );
78
+
79
+ include_view( 'admin/settings/multiple-configuration/page.php', $args );
80
+ }
81
+ }
src/settings/pages/Settings_Page.php CHANGED
@@ -14,29 +14,20 @@ class Settings_Page implements Settings_Page_Interface {
14
 
15
  const ICON = 'data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgNzIgNTQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbD0iI0ZGRkZGRiIgZmlsbC1ydWxlPSJldmVub2RkIj48cGF0aCBkPSJNNDYuODcyNTkwMyA4Ljc3MzU4MzM0QzQxLjk0MzkwMzkgMy4zODI5NTAxMSAzNC44NDI0OTQ2IDAgMjYuOTQ4MjgxOSAwIDEyLjA2NTE1NjggMCAwIDEyLjAyNDQ3NzQgMCAyNi44NTc0MjE5YzAgMTQuODMyOTQ0NSAxMi4wNjUxNTY4IDI2Ljg1NzQyMTkgMjYuOTQ4MjgxOSAyNi44NTc0MjE5IDcuODk0MjEyNyAwIDE0Ljk5NTYyMi0zLjM4Mjk1MDIgMTkuOTI0MzA4NC04Ljc3MzU4MzQtMi44ODk2OTY3LTEuMzY4ODY2My01LjM5OTMxMS0zLjQwNTQzOS03LjMyODA4MzgtNS45MDk2MzU4LTMuMTIxNDMwNiAzLjIwOTQxMDQtNy40OTI5OTQ0IDUuMjA0MTI5MS0xMi4zMzIwMjU4IDUuMjA0MTI5MS05LjQ4NDM0NDQgMC0xNy4xNzI5MjQ3LTcuNjYyNjU3Mi0xNy4xNzI5MjQ3LTE3LjExNTAyMzhzNy42ODg1ODAzLTE3LjExNTAyMzcgMTcuMTcyOTI0Ny0xNy4xMTUwMjM3YzQuNzIzNDgyMiAwIDkuMDAxNTU1MiAxLjkwMDU5MzkgMTIuMTA2MjkyIDQuOTc2MzA5IDEuOTU2OTIzNy0yLjY0MTEzMSA0LjU1MDAyNjMtNC43ODU1MTgzIDcuNTUzODE3Ni02LjIwODQzMTg2eiIvPjxwYXRoIGQ9Ik01NS4zODAzMjgyIDQyLjY1MDE5OTFDNDYuMzMzNzIyNyA0Mi42NTAxOTkxIDM5IDM1LjM0MTIwMzEgMzkgMjYuMzI1MDk5NiAzOSAxNy4zMDg5OTYgNDYuMzMzNzIyNyAxMCA1NS4zODAzMjgyIDEwYzkuMDQ2NjA1NSAwIDE2LjM4MDMyODIgNy4zMDg5OTYgMTYuMzgwMzI4MiAxNi4zMjUwOTk2IDAgOS4wMTYxMDM1LTcuMzMzNzIyNyAxNi4zMjUwOTk1LTE2LjM4MDMyODIgMTYuMzI1MDk5NXptLjAyMTMwOTItNy43NTU2MzQyYzQuNzM3MDI3NiAwIDguNTc3MTQ3MS0zLjgyNzE3MiA4LjU3NzE0NzEtOC41NDgyMjc5IDAtNC43MjEwNTYtMy44NDAxMTk1LTguNTQ4MjI4LTguNTc3MTQ3MS04LjU0ODIyOC00LjczNzAyNzUgMC04LjU3NzE0NyAzLjgyNzE3Mi04LjU3NzE0NyA4LjU0ODIyOCAwIDQuNzIxMDU1OSAzLjg0MDExOTUgOC41NDgyMjc5IDguNTc3MTQ3IDguNTQ4MjI3OXoiLz48L2c+PC9zdmc+';
16
 
17
- public function menu() {
18
- add_menu_page(
19
- 'Cookiebot',
20
- __( 'Cookiebot', 'cookiebot' ),
21
- 'manage_options',
22
- 'cookiebot',
23
- array(
24
- $this,
25
- 'display',
26
- )
27
- );
28
 
 
29
  add_submenu_page(
30
  'cookiebot',
31
  __( 'Cookiebot Settings', 'cookiebot' ),
32
  __( 'Settings', 'cookiebot' ),
33
  'manage_options',
34
- 'cookiebot',
35
  array(
36
  $this,
37
  'display',
38
  ),
39
- 10
40
  );
41
  }
42
 
@@ -62,7 +53,7 @@ class Settings_Page implements Settings_Page_Interface {
62
 
63
  /* Check if multisite */
64
  if ( is_multisite() ) {
65
- //Receive settings from multisite - this might change the way we render the form
66
  $args['network_cbid'] = get_site_option( 'cookiebot-cbid', '' );
67
  $args['network_scrip_tag_uc_attr'] = get_site_option( 'cookiebot-script-tag-uc-attribute', 'custom' );
68
  $args['network_scrip_tag_cd_attr'] = get_site_option( 'cookiebot-script-tag-cd-attribute', 'custom' );
14
 
15
  const ICON = 'data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgNzIgNTQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbD0iI0ZGRkZGRiIgZmlsbC1ydWxlPSJldmVub2RkIj48cGF0aCBkPSJNNDYuODcyNTkwMyA4Ljc3MzU4MzM0QzQxLjk0MzkwMzkgMy4zODI5NTAxMSAzNC44NDI0OTQ2IDAgMjYuOTQ4MjgxOSAwIDEyLjA2NTE1NjggMCAwIDEyLjAyNDQ3NzQgMCAyNi44NTc0MjE5YzAgMTQuODMyOTQ0NSAxMi4wNjUxNTY4IDI2Ljg1NzQyMTkgMjYuOTQ4MjgxOSAyNi44NTc0MjE5IDcuODk0MjEyNyAwIDE0Ljk5NTYyMi0zLjM4Mjk1MDIgMTkuOTI0MzA4NC04Ljc3MzU4MzQtMi44ODk2OTY3LTEuMzY4ODY2My01LjM5OTMxMS0zLjQwNTQzOS03LjMyODA4MzgtNS45MDk2MzU4LTMuMTIxNDMwNiAzLjIwOTQxMDQtNy40OTI5OTQ0IDUuMjA0MTI5MS0xMi4zMzIwMjU4IDUuMjA0MTI5MS05LjQ4NDM0NDQgMC0xNy4xNzI5MjQ3LTcuNjYyNjU3Mi0xNy4xNzI5MjQ3LTE3LjExNTAyMzhzNy42ODg1ODAzLTE3LjExNTAyMzcgMTcuMTcyOTI0Ny0xNy4xMTUwMjM3YzQuNzIzNDgyMiAwIDkuMDAxNTU1MiAxLjkwMDU5MzkgMTIuMTA2MjkyIDQuOTc2MzA5IDEuOTU2OTIzNy0yLjY0MTEzMSA0LjU1MDAyNjMtNC43ODU1MTgzIDcuNTUzODE3Ni02LjIwODQzMTg2eiIvPjxwYXRoIGQ9Ik01NS4zODAzMjgyIDQyLjY1MDE5OTFDNDYuMzMzNzIyNyA0Mi42NTAxOTkxIDM5IDM1LjM0MTIwMzEgMzkgMjYuMzI1MDk5NiAzOSAxNy4zMDg5OTYgNDYuMzMzNzIyNyAxMCA1NS4zODAzMjgyIDEwYzkuMDQ2NjA1NSAwIDE2LjM4MDMyODIgNy4zMDg5OTYgMTYuMzgwMzI4MiAxNi4zMjUwOTk2IDAgOS4wMTYxMDM1LTcuMzMzNzIyNyAxNi4zMjUwOTk1LTE2LjM4MDMyODIgMTYuMzI1MDk5NXptLjAyMTMwOTItNy43NTU2MzQyYzQuNzM3MDI3NiAwIDguNTc3MTQ3MS0zLjgyNzE3MiA4LjU3NzE0NzEtOC41NDgyMjc5IDAtNC43MjEwNTYtMy44NDAxMTk1LTguNTQ4MjI4LTguNTc3MTQ3MS04LjU0ODIyOC00LjczNzAyNzUgMC04LjU3NzE0NyAzLjgyNzE3Mi04LjU3NzE0NyA4LjU0ODIyOCAwIDQuNzIxMDU1OSAzLjg0MDExOTUgOC41NDgyMjc5IDguNTc3MTQ3IDguNTQ4MjI3OXoiLz48L2c+PC9zdmc+';
16
 
17
+ const ADMIN_SLUG = 'cookiebot_settings';
 
 
 
 
 
 
 
 
 
 
18
 
19
+ public function menu() {
20
  add_submenu_page(
21
  'cookiebot',
22
  __( 'Cookiebot Settings', 'cookiebot' ),
23
  __( 'Settings', 'cookiebot' ),
24
  'manage_options',
25
+ self::ADMIN_SLUG,
26
  array(
27
  $this,
28
  'display',
29
  ),
30
+ 2
31
  );
32
  }
33
 
53
 
54
  /* Check if multisite */
55
  if ( is_multisite() ) {
56
+ // Receive settings from multisite - this might change the way we render the form
57
  $args['network_cbid'] = get_site_option( 'cookiebot-cbid', '' );
58
  $args['network_scrip_tag_uc_attr'] = get_site_option( 'cookiebot-script-tag-uc-attribute', 'custom' );
59
  $args['network_scrip_tag_cd_attr'] = get_site_option( 'cookiebot-script-tag-cd-attribute', 'custom' );
src/settings/pages/Settings_Page_Interface.php CHANGED
@@ -4,7 +4,6 @@ namespace cybot\cookiebot\settings\pages;
4
 
5
  interface Settings_Page_Interface {
6
 
7
- public function menu();
8
 
9
  public function display();
10
  }
4
 
5
  interface Settings_Page_Interface {
6
 
 
7
 
8
  public function display();
9
  }
src/settings/pages/Support_Page.php CHANGED
@@ -2,18 +2,22 @@
2
 
3
  namespace cybot\cookiebot\settings\pages;
4
 
 
5
  use InvalidArgumentException;
 
6
  use function cybot\cookiebot\lib\include_view;
7
 
8
  class Support_Page implements Settings_Page_Interface {
9
 
 
 
10
  public function menu() {
11
  add_submenu_page(
12
  'cookiebot',
13
  __( 'Cookiebot Support', 'cookiebot' ),
14
  __( 'Support', 'cookiebot' ),
15
  'manage_options',
16
- 'cookiebot_support',
17
  array( $this, 'display' ),
18
  20
19
  );
@@ -23,6 +27,33 @@ class Support_Page implements Settings_Page_Interface {
23
  * @throws InvalidArgumentException
24
  */
25
  public function display() {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
26
  include_view( 'admin/settings/support-page.php', array() );
27
  }
28
  }
2
 
3
  namespace cybot\cookiebot\settings\pages;
4
 
5
+ use cybot\cookiebot\lib\Cookiebot_WP;
6
  use InvalidArgumentException;
7
+ use function cybot\cookiebot\lib\asset_url;
8
  use function cybot\cookiebot\lib\include_view;
9
 
10
  class Support_Page implements Settings_Page_Interface {
11
 
12
+ const ADMIN_SLUG = 'cookiebot_support';
13
+
14
  public function menu() {
15
  add_submenu_page(
16
  'cookiebot',
17
  __( 'Cookiebot Support', 'cookiebot' ),
18
  __( 'Support', 'cookiebot' ),
19
  'manage_options',
20
+ self::ADMIN_SLUG,
21
  array( $this, 'display' ),
22
  20
23
  );
27
  * @throws InvalidArgumentException
28
  */
29
  public function display() {
30
+ $scripts = array(
31
+ array( 'cookiebot-support-page-js', 'js/backend/support-page.js' ),
32
+ );
33
+
34
+ foreach ( $scripts as $script ) {
35
+ wp_enqueue_script(
36
+ $script[0],
37
+ asset_url( $script[1] ),
38
+ null,
39
+ Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION,
40
+ true
41
+ );
42
+ }
43
+
44
+ $style_sheets = array(
45
+ array( 'cookiebot-support-css', 'css/backend/support_page.css' ),
46
+ );
47
+
48
+ foreach ( $style_sheets as $style ) {
49
+ wp_enqueue_style(
50
+ $style[0],
51
+ asset_url( $style[1] ),
52
+ null,
53
+ Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION
54
+ );
55
+ }
56
+
57
  include_view( 'admin/settings/support-page.php', array() );
58
  }
59
  }
src/settings/templates/Header.php ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace cybot\cookiebot\settings\templates;
4
+
5
+ use cybot\cookiebot\lib\Cookiebot_WP;
6
+ use InvalidArgumentException;
7
+ use function cybot\cookiebot\lib\asset_url;
8
+ use function cybot\cookiebot\lib\include_view;
9
+
10
+ class Header {
11
+
12
+ /**
13
+ * @throws InvalidArgumentException
14
+ */
15
+ public function display() {
16
+ $args = array(
17
+ 'cookiebot_logo' => CYBOT_COOKIEBOT_PLUGIN_URL . 'logo.svg',
18
+ );
19
+
20
+ $style_sheets = array(
21
+ array( 'cookiebot-main-css', 'css/backend/cookiebot_admin_main.css' ),
22
+ );
23
+
24
+ foreach ( $style_sheets as $style ) {
25
+ wp_enqueue_style(
26
+ $style[0],
27
+ asset_url( $style[1] ),
28
+ null,
29
+ Cookiebot_WP::COOKIEBOT_PLUGIN_VERSION
30
+ );
31
+ }
32
+
33
+ include_view( 'admin/templates/header.php', $args );
34
+ }
35
+ }
src/settings/templates/Main_Tabs.php ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace cybot\cookiebot\settings\templates;
4
+
5
+ use InvalidArgumentException;
6
+ use function cybot\cookiebot\lib\asset_url;
7
+ use function cybot\cookiebot\lib\include_view;
8
+
9
+ class Main_Tabs {
10
+
11
+ /**
12
+ * @throws InvalidArgumentException
13
+ */
14
+ public function display( $active ) {
15
+ $args = array(
16
+ 'active_tab' => $active,
17
+ );
18
+
19
+ include_view( 'admin/templates/main-tabs.php', $args );
20
+ }
21
+ }
src/view/admin/settings/dashboard-page.php ADDED
@@ -0,0 +1,113 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ use cybot\cookiebot\settings\templates\Header;
4
+ use cybot\cookiebot\settings\templates\Main_Tabs;
5
+
6
+ use cybot\cookiebot\settings\pages\Settings_Page;
7
+
8
+ /**
9
+ * @var string $cbid
10
+ * @var string $cb_wp
11
+ * @var string $europe_icon
12
+ * @var string $usa_icon
13
+ * @var string $check_icon
14
+ * @var string $link_icon
15
+ */
16
+
17
+ $header = new Header();
18
+ $main_tabs = new Main_Tabs();
19
+
20
+ $header->display();
21
+ ?>
22
+ <div class="cb-body">
23
+ <div class="cb-wrapper">
24
+ <?php $main_tabs->display( 'dashboard' ); ?>
25
+ <div class="cb-main__content <?php echo $cbid ? 'sync-account' : ''; ?>">
26
+ <?php
27
+ if ( ! $cbid ) :
28
+ $today = new DateTime( 'now' );
29
+ $end_date = new DateTime( '2022-12-31' );
30
+
31
+ if ( $today < $end_date ) :
32
+ ?>
33
+ <div class="cb-main__dashboard__promo">
34
+ <div class="cb-main__dashboard__promo--inner">
35
+ <div class="cb-dashboard__promo--label"><div class="time-icon"></div><span>End of Year Promotion</span></div>
36
+ <h2 class="cb-dashboard__promo--title">Get <span class="highlight">30% off</span> your premium Cookiebot CMP subscription*</h2>
37
+ <a href="https://www.cookiebot.com/en/new-wp-cookie-plugin/?utm_source=wordpress&utm_medium=organic&utm_campaign=banner" target="_blank" class="cb-btn cb-promo-btn">SIGN UP NOW</a>
38
+ <p class="promo-condition">* This promotion is valid until December 31st, 2022 and will be calculated automatically. The discount only applies to new subscriptions and is valid for the first 12 months.</p>
39
+ </div>
40
+ </div>
41
+ <?php
42
+ endif;
43
+ endif;
44
+ ?>
45
+ <div class="cb-main__dashboard__card--container">
46
+ <div class="cb-main__dashboard__card">
47
+ <div class="cb-main__card__inner <?php echo $cbid ? 'start_card' : 'account_card'; ?>">
48
+ <?php if ( ! $cbid ) : ?>
49
+ <img src="<?php echo esc_html( $cb_wp ); ?>" alt="Cookiebot for WordPress" class="cb-wp">
50
+ <div class="cb-main__card__content">
51
+ <h2 class="cb-main__card__title"><?php echo esc_html__( 'I already have a Cookiebot CMP account', 'cookiebot' ); ?></h2>
52
+ <a href="/wp-admin/admin.php?page=<?php echo esc_html( Settings_Page::ADMIN_SLUG ); ?>" class="cb-btn cb-main-btn"><?php echo esc_html__( 'Connect my existing account', 'cookiebot' ); ?></a>
53
+ </div>
54
+ <?php else : ?>
55
+ <h2 class="cb-main__card__title"><?php echo esc_html__( 'Your Cookiebot CMP for WordPress solution', 'cookiebot' ); ?></h2>
56
+ <div class="cb-main__card__success">
57
+ <div class="cb-btn cb-success-btn"><img src="<?php echo esc_html( $check_icon ); ?>" alt="Check"> <?php echo esc_html__( 'Congratulations!', 'cookiebot' ); ?></div>
58
+ <p class="cb-main__success__text"> <?php echo esc_html__( 'You have added your Domain Group ID to WordPress. You are all set!', 'cookiebot' ); ?></p>
59
+ </div>
60
+ <?php endif; ?>
61
+ </div>
62
+ </div>
63
+
64
+ <div class="cb-main__dashboard__card">
65
+ <div class="cb-main__card__inner <?php echo $cbid ? 'start_card' : 'new_card'; ?>">
66
+ <?php if ( ! $cbid ) : ?>
67
+ <div class="cb-main__card__content">
68
+ <p class="cb-main__card__label"><?php echo esc_html__( 'Get started', 'cookiebot' ); ?></p>
69
+ <h2 class="cb-main__card__title"><?php echo esc_html__( 'Create a new Cookiebot CMP account', 'cookiebot' ); ?></h2>
70
+ <a href="https://manage.cookiebot.com/en/signup/?utm_source=wordpress&utm_medium=organic&utm_campaign=banner" target="_blank" class="cb-btn cb-white-btn"><?php echo esc_html__( 'Create a new account', 'cookiebot' ); ?></a>
71
+ </div>
72
+ <?php else : ?>
73
+ <h3 class="cb-main__card__subtitle"><?php echo esc_html__( 'Learn more about how to optimize your Cookiebot CMP setup?', 'cookiebot' ); ?></h3>
74
+ <a href="https://support.cookiebot.com/hc/en-us" target="_blank" class="cb-btn cb-link-btn"><?php echo esc_html__( 'Visit Help Center', 'cookiebot' ); ?></a>
75
+ <?php endif; ?>
76
+ </div>
77
+ </div>
78
+ </div>
79
+
80
+ <div class="cb-main__dashboard__card--container">
81
+ <div class="cb-main__dashboard__card">
82
+ <div class="cb-main__card__inner start_card">
83
+ <div class="cb-main__video">
84
+ <iframe src="https://www.youtube.com/embed/eSVFnjoMKFk" title="Cookiebot WordPress Installation" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
85
+ </div>
86
+ <div class="cb-main__card--content">
87
+ <p class="cb-main__card__label"><?php echo esc_html__( 'Video guide', 'cookiebot' ); ?></p>
88
+ <h2 class="cb-main__card__title"><?php echo esc_html__( 'How to get started with Cookiebot CMP', 'cookiebot' ); ?></h2>
89
+ <a href="https://support.cookiebot.com/hc/en-us/articles/4408356523282-Getting-started" target="_blank" class="cb-btn cb-link-btn"><?php echo esc_html__( 'Learn more about Cookiebot CMP', 'cookiebot' ); ?></a>
90
+ </div>
91
+ </div>
92
+ </div>
93
+ <div class="cb-main__dashboard__card">
94
+ <div class="cb-main__card__inner legislations_card">
95
+ <div class="cb-main__legislation__item">
96
+ <div class="cb-main__legislation____icon"><img src="<?php echo esc_html( $europe_icon ); ?>" alt="GDPR"></div>
97
+ <div class="cb-main__legislation__name"><?php echo esc_html__( 'GDPR', 'cookiebot' ); ?></div>
98
+ <div class="cb-main__legislation__region"><?php echo esc_html__( 'Europe', 'cookiebot' ); ?></div>
99
+ <a href="https://www.cookiebot.com/en/gdpr/" target="_blank" class="cb-btn cb-link-btn external-icon legislation-link"><?php echo esc_html__( 'Learn More', 'cookiebot' ); ?> <img src="<?php echo esc_html( $link_icon ); ?>" alt="<?php echo esc_html__( 'Learn More', 'cookiebot' ); ?>"></a>
100
+ </div>
101
+ <div class="cb-main__legislation__item">
102
+ <div class="cb-main__legislation____icon"><img src="<?php echo esc_html( $usa_icon ); ?>" alt="CCPA"></div>
103
+ <div class="cb-main__legislation__name"><?php echo esc_html__( 'CCPA', 'cookiebot' ); ?></div>
104
+ <div class="cb-main__legislation__region"><?php echo esc_html__( 'North America', 'cookiebot' ); ?></div>
105
+ <a href="https://www.cookiebot.com/en/what-is-ccpa/" target="_blank" class="cb-btn cb-link-btn external-icon legislation-link"><?php echo esc_html__( 'Learn More', 'cookiebot' ); ?> <img src="<?php echo esc_html( $link_icon ); ?>" alt="<?php echo esc_html__( 'Learn More', 'cookiebot' ); ?>"></a>
106
+ </div>
107
+ <a href="https://www.cookiebot.com/en/blog/" target="_blank" class="cb-btn cb-link-btn cb-right-btn"><?php echo esc_html__( 'See other legislations', 'cookiebot' ); ?></a>
108
+ </div>
109
+ </div>
110
+ </div>
111
+ </div>
112
+ </div>
113
+ </div>
src/view/admin/settings/debug-page.php CHANGED
@@ -2,32 +2,65 @@
2
  /**
3
  * @var string $debug_output
4
  */
 
 
 
 
 
 
 
 
5
  ?>
6
- <div class="wrap">
7
- <h1><?php esc_html_e( 'Debug information', 'cookiebot' ); ?></h1>
8
- <p>
9
- <?php
10
- esc_html_e(
11
- 'The information below is for debugging purpose. If you have any issues with your Cookiebot integration, the information below is usefull for a supporter to help you the best way.',
12
- 'cookiebot'
13
- );
14
- ?>
15
- </p>
16
- <p>
17
- <button class="button button-primary" onclick="copyDebugInfo();">
18
- <?php
19
- esc_html_e(
20
- 'Copy debug information to clipboard',
21
- 'cookiebot'
22
- );
23
- ?>
24
- </button>
25
- </p>
26
- <textarea
27
- cols="100"
28
- rows="40"
29
- style="width:800px;max-width:100%;"
30
- id="cookiebot-debug-info"
31
- readonly="readonly"
32
- ><?php echo esc_textarea( $debug_output ); ?></textarea>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
33
  </div>
2
  /**
3
  * @var string $debug_output
4
  */
5
+
6
+ use cybot\cookiebot\settings\templates\Header;
7
+ use cybot\cookiebot\settings\templates\Main_Tabs;
8
+
9
+ $header = new Header();
10
+ $main_tabs = new Main_Tabs();
11
+
12
+ $header->display();
13
  ?>
14
+ <div class="cb-body">
15
+ <div class="cb-wrapper">
16
+ <?php $main_tabs->display( 'debug' ); ?>
17
+ <div class="cb-main__content">
18
+ <h1 class="cb-main__page_title"><?php esc_html_e( 'Debug info', 'cookiebot' ); ?></h1>
19
+
20
+ <div class="cb-debug__content">
21
+ <div class="cb-debug__info__card">
22
+ <h2 class="cb-debug__info__title"><?php esc_html_e( 'Debug information', 'cookiebot' ); ?></h2>
23
+ <p class="cb-debug__info__text">
24
+ <?php
25
+ esc_html_e(
26
+ 'The information below is for debugging purposes. If you have any issues with your Cookiebot CMP integration, this information is the best place to start.',
27
+ 'cookiebot'
28
+ );
29
+ ?>
30
+ </p>
31
+ <button class="cb-btn cb-main-btn" onclick="copyDebugInfo();">
32
+ <?php
33
+ esc_html_e(
34
+ 'Copy debug information to clipboard',
35
+ 'cookiebot'
36
+ );
37
+ ?>
38
+ </button>
39
+ </div>
40
+ <div class="cb-debug__support__card">
41
+ <div class="cb-debug__support__inner">
42
+ <h2 class="cb-debug__support__title"><?php esc_html_e( 'If you have any issues with the implemenation of Cookiebot CMP, please visit our Support Center.', 'cookiebot' ); ?></h2>
43
+ <a href="https://support.cookiebot.com/hc/en-us" target="_blank" class="cb-btn cb-main-btn">
44
+ <?php
45
+ esc_html_e(
46
+ 'Visit Support Center',
47
+ 'cookiebot'
48
+ );
49
+ ?>
50
+ </a>
51
+ </div>
52
+
53
+ </div>
54
+ </div>
55
+
56
+ <div class="cb-debug__code__container">
57
+ <textarea
58
+ cols="50"
59
+ rows="40"
60
+ id="cookiebot-debug-info"
61
+ readonly="readonly"
62
+ ><?php echo esc_textarea( $debug_output ); ?></textarea>
63
+ </div>
64
+ </div>
65
+ </div>
66
  </div>
src/view/admin/settings/gtm-page.php CHANGED
@@ -1,71 +1,56 @@
1
- <div class="wrap">
2
- <h1><?php esc_html_e( 'Google Tag Manager', 'cookiebot' ); ?></h1>
3
-
4
- <form method="post" action="options.php" class="form_gtm">
5
- <?php settings_fields( 'cookiebot-gtm' ); ?>
6
- <?php do_settings_sections( 'cookiebot-gtm' ); ?>
7
-
8
- <p><?php esc_html_e( 'Enable GTM', 'cookiebot' ); ?></p>
9
- <div class="GTM_check">
10
- <input
11
- type="checkbox"
12
- name="cookiebot-gtm"
13
- id="cookiebot-gtm"
14
- value="1" <?php checked( 1, get_option( 'cookiebot-gtm' ) ); ?>>
15
- <p>
16
- <?php
17
- esc_html_e(
18
- 'For more details about Cookiebot and Google Tag Manager click',
19
- 'cookiebot'
20
- );
21
- ?>
22
- <a
23
- target="_blank"
24
- href="https://www.cookiebot.com/en/google-tag-manager-and-gdpr-compliance-with-cookiebot/">
25
- &nbsp;<?php esc_html_e( 'here', 'cookiebot' ); ?>
26
- </a>
27
- </p>
28
  </div>
 
 
29
 
30
- <p><?php esc_html_e( 'GTM ID', 'cookiebot' ); ?></p>
31
- <input
32
- type="text"
33
- name="cookiebot-gtm-id"
34
- id="cookiebot-gtm-id"
35
- value="<?php echo esc_html( get_option( 'cookiebot-gtm-id' ) ); ?>">
36
-
37
- <p><?php esc_html_e( 'DataLayer name', 'cookiebot' ); ?></p>
38
- <div>
39
- <input
40
- type="text"
41
- name="cookiebot-data-layer"
42
- id="data_layer"
43
- placeholder="dataLayer"
44
- value="<?php echo esc_html( get_option( 'cookiebot-data-layer' ) ); ?>">
45
- <p style="margin: 0;"><?php esc_html_e( 'Optional, only change if necessary', 'cookiebot' ); ?></p>
46
  </div>
 
 
47
 
48
- <p><?php esc_html_e( 'Google Consent Mode', 'cookiebot' ); ?></p>
49
- <div class="GTM_check">
50
- <input
51
- type="checkbox"
52
- name="cookiebot-gcm"
53
- id="gcm"
54
- value="1" <?php checked( 1, get_option( 'cookiebot-gcm' ) ); ?>>
55
- <p>
56
- <?php
57
- esc_html_e(
58
- 'For more details about Cookiebot and Google Consent Mode click',
59
- 'cookiebot'
60
- );
61
- ?>
62
- <a
63
- target="_blank"
64
- href="https://support.cookiebot.com/hc/en-us/articles/360016047000-Cookiebot-and-Google-Consent-Mode">
65
- &nbsp;<?php esc_html_e( 'here', 'cookiebot' ); ?>
66
- </a>
67
- </p>
68
  </div>
69
- <input type="submit" value="Save" name="gtm_save" id="gtm_save">
70
- </form>
71
  </div>
1
+ <div class="cb-settings__config__item">
2
+ <div class="cb-settings__config__content">
3
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Google Tag Manager:', 'cookiebot' ); ?></h3>
4
+ <p class="cb-general__info__text">
5
+ <?php esc_html_e( 'For more details about Cookiebot CMP and Google Tag Manager.', 'cookiebot' ); ?>
6
+ </p>
7
+ <a href="https://www.cookiebot.com/en/google-tag-manager-and-gdpr-compliance-with-cookiebot/" class="cb-btn cb-link-btn" target="_blank">
8
+ &nbsp;<?php esc_html_e( 'Read more', 'cookiebot' ); ?>
9
+ </a>
10
+ </div>
11
+ <div class="cb-settings__config__data">
12
+ <div class="cb-settings__config__data__inner">
13
+ <label class="switch-checkbox" for="cookiebot-gtm">
14
+ <input type="checkbox" name="cookiebot-gtm" id="cookiebot-gtm" value="1" <?php checked( 1, get_option( 'cookiebot-gtm' ) ); ?>>
15
+ <div class="switcher"></div>
16
+ <?php esc_html_e( 'Google Tag Manager', 'cookiebot' ); ?>
17
+ </label>
 
 
 
 
 
 
 
 
 
 
18
  </div>
19
+ </div>
20
+ </div>
21
 
22
+ <div class="cb-settings__config__item">
23
+ <div class="cb-settings__config__content">
24
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Google Tag Manager ID', 'cookiebot' ); ?></h3>
25
+ <p class="cb-general__info__text">
26
+ <?php esc_html_e( 'Paste your Tag Manager ID into the field on the right.', 'cookiebot' ); ?>
27
+ </p>
28
+ <a href="https://support.cookiebot.com/hc/en-us/articles/360003784174#3" class="cb-btn cb-link-btn" target="_blank">
29
+ &nbsp;<?php esc_html_e( 'How to find the GTM ID', 'cookiebot' ); ?>
30
+ </a>
31
+ </div>
32
+ <div class="cb-settings__config__data">
33
+ <div class="cb-settings__config__data__inner">
34
+ <h3 class="cb-settings__data__subtitle"><?php esc_html_e( 'Google Tag Manager ID', 'cookiebot' ); ?></h3>
35
+ <input type="text" name="cookiebot-gtm-id" id="cookiebot-gtm-id" placeholder="<?php esc_html_e( 'Enter GTM ID', 'cookiebot' ); ?>" value="<?php echo esc_html( get_option( 'cookiebot-gtm-id' ) ); ?>">
 
 
36
  </div>
37
+ </div>
38
+ </div>
39
 
40
+ <div class="cb-settings__config__item">
41
+ <div class="cb-settings__config__content">
42
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Data Layer Name (optional)', 'cookiebot' ); ?></h3>
43
+ <p class="cb-general__info__text">
44
+ <?php esc_html_e( 'You can also paste your Data Layer Name here. This is optional information.', 'cookiebot' ); ?>
45
+ </p>
46
+ <a href="https://support.cookiebot.com/hc/en-us/articles/360003784174#3" class="cb-btn cb-link-btn" target="_blank">
47
+ &nbsp;<?php esc_html_e( 'How to find the Data Layer Name', 'cookiebot' ); ?>
48
+ </a>
49
+ </div>
50
+ <div class="cb-settings__config__data">
51
+ <div class="cb-settings__config__data__inner">
52
+ <h3 class="cb-settings__data__subtitle"><?php esc_html_e( 'Name of your Data Layer', 'cookiebot' ); ?></h3>
53
+ <input type="text" name="cookiebot-data-layer" id="data_layer" placeholder="dataLayer" value="<?php echo esc_html( get_option( 'cookiebot-data-layer' ) ); ?>">
 
 
 
 
 
 
54
  </div>
55
+ </div>
 
56
  </div>
src/view/admin/settings/iab-page.php CHANGED
@@ -1,31 +1,18 @@
1
- <div class="wrap">
2
- <h1><?php esc_html_e( 'IAB', 'cookiebot' ); ?></h1>
3
-
4
- <p>
5
- <?php
6
- echo sprintf(
7
- /* translators: %1$s is replaced by a starting tag of href, %2$s is replaced by a closing tag of href */
8
- esc_html__(
9
- 'For more details about Cookiebot\'s IAB integration, see %1$sarticle about cookiebot and the IAB consent framework%2$s',
10
- 'cookiebot'
11
- ),
12
- '<a href="https://support.cookiebot.com/hc/en-us/articles/360007652694-Cookiebot-and-the-IAB-Consent-Framework" target="_blank">',
13
- '</a>'
14
- );
15
- ?>
16
- </p>
17
-
18
- <form method="post" action="options.php">
19
- <?php settings_fields( 'cookiebot-iab' ); ?>
20
- <?php do_settings_sections( 'cookiebot-iab' ); ?>
21
-
22
- <label for="cookiebot-iab"><?php esc_html_e( 'Enable IAB integration', 'cookiebot' ); ?></label>
23
- <input
24
- type="checkbox"
25
- name="cookiebot-iab"
26
- id="cookiebot-iab"
27
- value="1" <?php checked( 1, get_option( 'cookiebot-iab' ) ); ?>>
28
-
29
- <?php submit_button(); ?>
30
- </form>
31
  </div>
1
+ <div class="cb-settings__config__item">
2
+ <div class="cb-settings__config__content">
3
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'IAB Integration:', 'cookiebot' ); ?></h3>
4
+ <p class="cb-general__info__text">
5
+ <?php esc_html_e( 'If you want to use the IAB Framework TCF v2.0 within your Consent Management Platform (CMP) you can enable it on the right. Be aware that activating this could override some of the configurations you made with the default setup defined by the IAB.', 'cookiebot' ); ?>
6
+ </p>
7
+ <a href="https://support.cookiebot.com/hc/en-us/articles/360007652694-Cookiebot-and-the-IAB-Consent-Framework" target="_blank" class="cb-btn cb-link-btn"><?php esc_html_e( 'Read more on IAB with Cookiebot CMP here', 'cookiebot' ); ?></a>
8
+ </div>
9
+ <div class="cb-settings__config__data">
10
+ <div class="cb-settings__config__data__inner">
11
+ <label class="switch-checkbox" for="cookiebot-iab">
12
+ <input type="checkbox" name="cookiebot-iab" id="cookiebot-iab" value="1" <?php checked( 1, get_option( 'cookiebot-iab' ) ); ?>>
13
+ <div class="switcher"></div>
14
+ <?php esc_html_e( 'IAB TCF v2.0 integration', 'cookiebot' ); ?>
15
+ </label>
16
+ </div>
17
+ </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
18
  </div>
src/view/admin/settings/multiple-configuration/page.php ADDED
@@ -0,0 +1,87 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * @var string $cbid
4
+ * @var string $secondary_group_id
5
+ * @var array $supported_regions
6
+ * @var string $ccpa_compatibility
7
+ * @var array $selected_regions
8
+ */
9
+ ?>
10
+ <div class="cb-settings__config__item">
11
+ <div class="cb-settings__config__content">
12
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Additional configurations:', 'cookiebot' ); ?></h3>
13
+ <p class="cb-general__info__text">
14
+ <?php esc_html_e( 'You can add a second alternative banner or configuration to your website by creating a second Domain Group and specify it on a region.', 'cookiebot' ); ?>
15
+ </p>
16
+ <a href="https://support.cookiebot.com/hc/en-us/articles/360010932419-Multiple-banners-on-the-same-website-example-CCPA-GDPR-" target="_blank" class="cb-btn cb-link-btn"><?php esc_html_e( 'Read more about multiple configurations here', 'cookiebot' ); ?></a>
17
+ </div>
18
+ <div class="cb-settings__config__data">
19
+ <div class="cb-settings__config__data__inner">
20
+ <label class="switch-checkbox" for="multiple-config">
21
+ <input
22
+ type="checkbox"
23
+ name="cookiebot-multiple-config"
24
+ id="multiple-config"
25
+ value="1" <?php checked( 1, get_option( 'cookiebot-multiple-config' ) ); ?>>
26
+ <div class="switcher"></div>
27
+ <?php esc_html_e( 'Multiple configurations', 'cookiebot' ); ?>
28
+ </label>
29
+ </div>
30
+ </div>
31
+ </div>
32
+
33
+ <div class="cb-multiple__container <?php echo ! get_option( 'cookiebot-multiple-config' ) ? 'hidden' : ''; ?>">
34
+ <div class="cb-settings__config__item">
35
+ <div class="cb-settings__config__content">
36
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Set up your additional banner configuration:', 'cookiebot' ); ?></h3>
37
+ <p class="cb-general__info__text">
38
+ <?php esc_html_e( 'To enable a different configuration, create a separate DomainGroup without adding the domain to it and paste the ID below. Then select the countries in which you want to show this configuration. For example, if your main Domain Group is defined as a banner matching GDPR requirements, you might want to add another Domain Group for visitors from California. The number of additional configurations is restricted to one at the moment.', 'cookiebot' ); ?>
39
+ </p>
40
+ </div>
41
+ <div class="cb-settings__config__data"></div>
42
+ </div>
43
+
44
+ <div class="cb-region__table">
45
+ <div class="cb-region__table__header">
46
+ <div class="cb-region__table__column">
47
+ <div class="cb-region__table__header--title"><?php esc_html_e( 'Domain Group ID', 'cookiebot' ); ?></div>
48
+ </div>
49
+ <div class="cb-region__table__column">
50
+ <div class="cb-region__table__header--title"><?php esc_html_e( 'Region', 'cookiebot' ); ?></div>
51
+ </div>
52
+ </div>
53
+ <div class="cb-region__table__item">
54
+ <div class="cb-region__item__group">
55
+ <input type="text" disabled placeholder="<?php echo $cbid ? esc_html( $cbid ) : '1111-1111-1111-1111'; ?>">
56
+ </div>
57
+ <div class="cb-region__item__region">
58
+ <p class="cb-region__item__region--primary"><?php esc_html_e( 'Primary domain group', 'cookiebot' ); ?></p>
59
+ </div>
60
+ </div>
61
+ <div class="cb-region__table__item">
62
+ <div class="cb-region__item__group">
63
+ <input type="text" name="cookiebot-second-banner-id" placeholder="1111-1111-1111-1111" value="<?php echo esc_html( $secondary_group_id ); ?>">
64
+ </div>
65
+ <div class="cb-region__item__region">
66
+ <input type="hidden" name="cookiebot-second-banner-regions" id="second-banner-regions" value="<?php echo esc_html( implode( ', ', array_keys( $selected_regions ) ) ); ?>">
67
+ <input type="hidden" name="cookiebot-ccpa" id="ccpa-compatibility" value="<?php echo esc_html( $ccpa_compatibility ); ?>">
68
+ <div class="cb-region__region__selector">
69
+ <div class="default-none <?php echo $selected_regions ? 'hidden' : ''; ?>"><?php esc_html_e( 'Select region', 'cookiebot' ); ?></div>
70
+ <div class="selected-regions">
71
+ <?php foreach ( $selected_regions as $code => $region ) : ?>
72
+ <div id="<?php echo esc_html( $code ); ?>" class="selected-regions-item"><?php echo esc_html( $region ); ?></div>
73
+ <?php endforeach; ?>
74
+ </div>
75
+ </div>
76
+ <div class="cb-region__region__list hidden">
77
+ <div class="cb-region__veil"></div>
78
+ <div class="cb-region__list__container">
79
+ <?php foreach ( $supported_regions as $code => $region ) : ?>
80
+ <div class='cb-region__region__item <?php echo array_key_exists( $code, $selected_regions ) ? 'selected-region' : ''; ?>' data-region="<?php echo esc_html( $code ); ?>"><?php echo esc_html( $region ); ?></div>
81
+ <?php endforeach; ?>
82
+ </div>
83
+ </div>
84
+ </div>
85
+ </div>
86
+ </div>
87
+ </div>
src/view/admin/settings/network-settings-page.php CHANGED
@@ -1,291 +1,276 @@
1
  <?php
 
 
2
  /**
3
  * @var string $logo
4
  * @var string $cookiebot_gdpr_url
5
  * @var string $cbm
6
  */
 
 
 
 
 
7
  ?>
8
- <div class="wrap">
9
- <h1><?php esc_html_e( 'Cookiebot Network Settings', 'cookiebot' ); ?></h1>
10
- <a href="https://www.cookiebot.com">
11
- <img
12
- src="<?php echo esc_attr( $logo ); ?>"
13
- alt="Cookiebot"
14
- style="float:right;margin-left:1em;">
15
- </a>
16
- <p>
17
- <?php
18
- printf(
19
- /* translators: first link is for GDPR, second is more information about third-party services */
20
- esc_html__(
21
- 'Cookiebot enables your website to comply with current legislation in the EU on the use of cookies for user tracking and profiling. The EU ePrivacy Directive requires prior, informed consent of your site users, while the %1$s %2$s.',
22
- 'cookiebot'
23
- ),
24
- sprintf(
25
- '<a href="%s" target="_blank">%s</a>',
26
- esc_url( $cookiebot_gdpr_url ),
27
- esc_html__( 'General Data Protection Regulation (GDPR)', 'cookiebot' )
28
- ),
29
- esc_html__(
30
- ' requires you to document each consent. At the same time you must be able to account for what user data you share with embedded third-party services on your website and where in the world the user data is sent.',
31
- 'cookiebot'
32
- )
33
- );
34
- ?>
35
- </p>
36
- <p>
37
- <b style="color:red;font-size: larger">
38
- <?php
39
- esc_html_e(
40
- 'The settings below is network wide settings. See notes below each field.',
41
- 'cookiebot'
42
- );
43
- ?>
44
- </b>
45
- </p>
46
- <form method="post" action="edit.php?action=cookiebot_network_settings">
47
- <?php wp_nonce_field( 'cookiebot-network-settings' ); ?>
48
- <table class="form-table">
49
- <tr>
50
- <th scope="row"><?php esc_html_e( 'Network Cookiebot ID', 'cookiebot' ); ?></th>
51
- <td>
52
- <input
53
- type="text"
54
- name="cookiebot-cbid"
55
- value="<?php echo esc_attr( get_site_option( 'cookiebot-cbid', '' ) ); ?>"
56
- style="width:300px"/>
57
- <p class="description">
58
- <b>
59
- <?php
60
- esc_html_e(
61
- 'If added this will be the default Cookiebot ID for all subsites. Subsites are able to override the Cookiebot ID.',
62
- 'cookiebot'
63
- );
64
- ?>
65
- </b>
66
- <br/>
67
- <?php esc_html_e( 'Need an ID?', 'cookiebot' ); ?>
68
- <a href="https://www.cookiebot.com/goto/signup" target="_blank">
69
- <?php
70
- esc_html_e(
71
- 'Sign up for free on cookiebot.com',
72
- 'cookiebot'
73
- );
74
- ?>
75
- </a>
76
- </p>
77
- </td>
78
- </tr>
79
- <tr>
80
- <th scope="row">
81
- <?php esc_html_e( 'Cookie-blocking mode', 'cookiebot' ); ?>
82
- </th>
83
- <td>
84
- <label>
85
- <input
86
- type="radio"
87
- name="cookiebot-cookie-blocking-mode"
88
- value="auto" <?php checked( 'auto', $cbm ); ?> />
89
- <?php esc_html_e( 'Automatic', 'cookiebot' ); ?>
90
- </label>
91
- &nbsp; &nbsp;
92
- <label>
93
- <input
94
- type="radio"
95
- name="cookiebot-cookie-blocking-mode"
96
- value="manual" <?php checked( 'manual', $cbm ); ?> />
97
- <?php esc_html_e( 'Manual', 'cookiebot' ); ?>
98
- </label>
99
- <p class="description">
100
- <?php esc_html_e( 'Should Cookiebot automatic block cookies by tagging known tags.', 'cookiebot' ); ?>
101
- </p>
102
- </td>
103
- </tr>
104
- <tr id="cookiebot-setting-async">
105
- <th scope="row">
106
- <?php esc_html_e( 'Add async or defer attribute', 'cookiebot' ); ?>
107
- <br/><?php esc_html_e( 'Consent banner script tag', 'cookiebot' ); ?>
108
- </th>
109
- <td>
110
- <?php
111
- $cv = get_site_option( 'cookiebot-script-tag-uc-attribute', 'custom' );
112
- ?>
113
- <label>
114
- <input
115
- type="radio"
116
- name="cookiebot-script-tag-uc-attribute"
117
- value="" <?php checked( '', $cv ); ?> />
118
- <i><?php esc_html_e( 'None', 'cookiebot' ); ?></i>
119
- </label>
120
- &nbsp; &nbsp;
121
- <label>
122
- <input
123
- type="radio"
124
- name="cookiebot-script-tag-uc-attribute"
125
- value="async" <?php checked( 'async', $cv ); ?> />
126
- async
127
- </label>
128
- &nbsp; &nbsp;
129
- <label>
130
- <input
131
- type="radio"
132
- name="cookiebot-script-tag-uc-attribute"
133
- value="defer" <?php checked( 'defer', $cv ); ?> />
134
- defer
135
- </label>
136
- &nbsp; &nbsp;
137
- <label>
138
- <input
139
- type="radio"
140
- name="cookiebot-script-tag-uc-attribute"
141
- value="custom" <?php checked( 'custom', $cv ); ?> />
142
- <i><?php esc_html_e( 'Choose per subsite', 'cookiebot' ); ?></i>
143
- </label>
144
- <p class="description">
145
- <b>
146
- <?php
147
- esc_html_e(
148
- 'Setting will apply for all subsites. Subsites will not be able to override.',
149
- 'cookiebot'
150
- );
151
- ?>
152
- </b><br/>
153
- <?php esc_html_e( 'Add async or defer attribute to Cookiebot script tag. Default: Choose per subsite', 'cookiebot' ); ?>
154
- </p>
155
- </td>
156
- </tr>
157
- <tr>
158
- <th scope="row">
159
- <?php esc_html_e( 'Add async or defer attribute', 'cookiebot' ); ?>
160
- <br/><?php esc_html_e( 'Cookie declaration script tag', 'cookiebot' ); ?>
161
- </th>
162
- <td>
163
- <?php
164
- $cv = get_site_option( 'cookiebot-script-tag-cd-attribute', 'custom' );
165
- ?>
166
- <label>
167
- <input
168
- type="radio"
169
- name="cookiebot-script-tag-cd-attribute"
170
- value="" <?php checked( '', $cv ); ?> />
171
- <i><?php esc_html_e( 'None', 'cookiebot' ); ?></i>
172
- </label>
173
- &nbsp; &nbsp;
174
- <label>
175
- <input
176
- type="radio"
177
- name="cookiebot-script-tag-cd-attribute"
178
- value="async" <?php checked( 'async', $cv ); ?> />
179
- async
180
- </label>
181
- &nbsp; &nbsp;
182
- <label>
183
- <input
184
- type="radio"
185
- name="cookiebot-script-tag-cd-attribute"
186
- value="defer" <?php checked( 'defer', $cv ); ?> />
187
- defer
188
- </label>
189
- &nbsp; &nbsp;
190
- <label>
191
- <input
192
- type="radio"
193
- name="cookiebot-script-tag-cd-attribute"
194
- value="custom" <?php checked( 'custom', $cv ); ?> />
195
- <i><?php esc_html_e( 'Choose per subsite', 'cookiebot' ); ?></i>
196
- </label>
197
- <p class="description">
198
- <b>
199
- <?php
200
- esc_html_e(
201
- 'Setting will apply for all subsites. Subsites will not be able to override.',
202
- 'cookiebot'
203
- );
204
- ?>
205
- </b><br/>
206
- <?php esc_html_e( 'Add async or defer attribute to Cookiebot script tag. Default: Choose per subsite', 'cookiebot' ); ?>
207
- </p>
208
- </td>
209
- </tr>
210
- <tr>
211
- <th scope="row"><?php esc_html_e( 'Auto-update Cookiebot', 'cookiebot' ); ?></th>
212
- <td>
213
- <input
214
- type="checkbox"
215
- name="cookiebot-autoupdate"
216
- value="1"
217
- <?php
218
- checked(
219
- 1,
220
- get_site_option( 'cookiebot-autoupdate' )
221
- );
222
- ?>
223
- />
224
- <p class="description">
225
- <?php esc_html_e( 'Automatic update your Cookiebot plugin when new releases becomes available.', 'cookiebot' ); ?>
226
- </p>
227
- </td>
228
- </tr>
229
- <tr id="cookiebot-setting-hide-popup">
230
- <th scope="row"><?php esc_html_e( 'Hide Cookie Popup', 'cookiebot' ); ?></th>
231
- <td>
232
- <input type="checkbox" name="cookiebot-nooutput" value="1"
233
- <?php
234
- checked(
235
- 1,
236
- get_site_option( 'cookiebot-nooutput' )
237
- );
238
- ?>
239
- />
240
- <p class="description">
241
- <b>
242
- <?php
243
- esc_html_e(
244
- 'Remove the cookie consent banner from all subsites. This cannot be changed by subsites. The <i>[cookie_declaration]</i> shortcode will still be available.',
245
- 'cookiebot'
246
- );
247
- ?>
248
- </b><br/>
249
- <?php
250
- esc_html_e(
251
- 'If you are using Google Tag Manager (or equal), you need to add the Cookiebot script in your Tag Manager.',
252
- 'cookiebot'
253
- );
254
- ?>
255
- <br/>
256
- <?php
257
- esc_html_e(
258
- '<a href="https://support.cookiebot.com/hc/en-us/articles/360003793854-Google-Tag-Manager-deployment" target="_blank">See a detailed guide here</a>',
259
- 'cookiebot'
260
- );
261
- ?>
262
- </p>
263
- </td>
264
- </tr>
265
- <tr>
266
- <th scope="row"><?php esc_html_e( 'Hide Cookie Popup in WP Admin', 'cookiebot' ); ?></th>
267
- <td>
268
- <input type="checkbox" name="cookiebot-nooutput-admin" value="1"
269
- <?php
270
- checked(
271
- 1,
272
- get_site_option( 'cookiebot-nooutput-admin' )
273
- );
274
- ?>
275
- />
276
- <p class="description">
277
- <b>
278
- <?php
279
- esc_html_e(
280
- 'Remove the cookie consent banner the WordPress Admin area for all subsites. This cannot be changed by subsites.',
281
- 'cookiebot'
282
- );
283
- ?>
284
- </b>
285
- </p>
286
- </td>
287
- </tr>
288
- </table>
289
- <?php submit_button(); ?>
290
- </form>
291
  </div>
1
  <?php
2
+ use cybot\cookiebot\settings\templates\Header;
3
+ use cybot\cookiebot\settings\templates\Main_Tabs;
4
  /**
5
  * @var string $logo
6
  * @var string $cookiebot_gdpr_url
7
  * @var string $cbm
8
  */
9
+
10
+ $header = new Header();
11
+ $main_tabs = new Main_Tabs();
12
+
13
+ $header->display();
14
  ?>
15
+ <div class="cb-body">
16
+ <div class="cb-wrapper">
17
+ <?php $main_tabs->display( 'settings' ); ?>
18
+ <div class="cb-main__content">
19
+ <form method="post" action="edit.php?action=cookiebot_network_settings">
20
+ <?php wp_nonce_field( 'cookiebot-network-settings' ); ?>
21
+ <div class="cb-settings__header">
22
+ <h1 class="cb-main__page_title"><?php esc_html_e( 'Network Settings', 'cookiebot' ); ?></h1>
23
+ <?php submit_button(); ?>
24
+ </div>
25
+
26
+ <div class="cb-settings__tabs">
27
+ </div>
28
+
29
+ <div class="cb-settings__tabs__content">
30
+ <div class="cb-settings__tabs__content--item active-item">
31
+ <?php if ( ! esc_attr( get_site_option( 'cookiebot-cbid', '' ) ) ) : ?>
32
+ <div class="cb-general__new__account">
33
+ <h2 class="cb-general__info__title"><?php esc_html_e( 'You do not have an account yet?', 'cookiebot' ); ?></h2>
34
+ <p class="cb-general__info__text">
35
+ <?php esc_html_e( 'To use Cookiebot for WordPress you need to visit our website and sign-up. After you have signed up, you can configure your banner and then place the Cookiebot Domain Group ID below. Navigate to Settings and to "Your Scripts" to find your ID.', 'cookiebot' ); ?>
36
+ </p>
37
+ <div class="new-account-actions">
38
+ <a href="#" class="cb-btn cb-main-btn"><?php esc_html_e( 'Create a new Account', 'cookiebot' ); ?></a>
39
+ <a href="#" class="cb-btn cb-link-btn"><?php esc_html_e( 'Get help with connecting your account', 'cookiebot' ); ?></a>
40
+ </div>
41
+ </div>
42
+ <?php endif; ?>
43
+
44
+ <div class="cb-settings__config__item">
45
+ <div class="cb-settings__config__content">
46
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Network Domain Group:', 'cookiebot' ); ?></h3>
47
+ <p class="cb-general__info__text">
48
+ <?php esc_html_e( 'If added this will be the default Cookiebot ID for all subsites. Subsites are able to override the Cookiebot ID.', 'cookiebot' ); ?>
49
+ </p>
50
+ <a href="#" class="cb-btn cb-link-btn"><?php esc_html_e( 'Read more on the Domain Group ID', 'cookiebot' ); ?></a>
51
+ </div>
52
+ <div class="cb-settings__config__data">
53
+ <div class="cb-settings__config__data__inner">
54
+ <h3 class="cb-settings__data__subtitle"><?php esc_html_e( 'Add your Domain Group ID', 'cookiebot' ); ?></h3>
55
+ <input
56
+ type="text"
57
+ name="cookiebot-cbid"
58
+ value="<?php echo esc_attr( get_site_option( 'cookiebot-cbid', '' ) ); ?>"
59
+ />
60
+ </div>
61
+ </div>
62
+ </div>
63
+
64
+ <div class="cb-settings__config__item">
65
+ <div class="cb-settings__config__content">
66
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Cookie-blocking mode', 'cookiebot' ); ?></h3>
67
+ <p class="cb-general__info__text">
68
+ <?php esc_html_e( 'You can select your Cookie-blocking mode here. With Automatic Cookie Blocking Cookiebot will block all cookies except those strictly necessary from being set until a user has given their consent.', 'cookiebot' ); ?>
69
+ </p>
70
+ </div>
71
+ <div class="cb-settings__config__data">
72
+ <div class="cb-settings__config__data__inner">
73
+ <h3 class="cb-settings__data__subtitle"><?php esc_html_e( 'Select the Cookie-blocking mode', 'cookiebot' ); ?></h3>
74
+ <label class="recommended-item">
75
+ <input <?php checked( 'auto', $cbm ); ?>
76
+ type="radio"
77
+ name="cookiebot-cookie-blocking-mode"
78
+ value="auto"
79
+ />
80
+ <?php esc_html_e( 'Automatic cookie-blocking mode', 'cookiebot' ); ?>
81
+ </label>
82
+ <label>
83
+ <input <?php checked( 'manual', $cbm ); ?>
84
+ type="radio"
85
+ name="cookiebot-cookie-blocking-mode"
86
+ value="manual"
87
+ />
88
+ <?php esc_html_e( 'Manual cookie-blocking mode', 'cookiebot' ); ?>
89
+ </label>
90
+ </div>
91
+ </div>
92
+ </div>
93
+
94
+ <div class="cb-settings__config__item secondary__item" id="declaration-tag">
95
+ <div class="cb-settings__config__content">
96
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Cookiebot banner script tag', 'cookiebot' ); ?></h3>
97
+ <p class="cb-general__info__note">
98
+ <?php esc_html_e( 'Depending on Cookie-blocking mode', 'cookiebot' ); ?>
99
+ </p>
100
+ <p class="cb-general__info__note">
101
+ <?php esc_html_e( 'Setting will apply for all subsites. Subsites will not be able to override.', 'cookiebot' ); ?>
102
+ </p>
103
+ <p class="cb-general__info__text">
104
+ <?php esc_html_e( 'Add async or defer attribute to Cookie banner script tag. Default: Choose per subsite', 'cookiebot' ); ?>
105
+ </p>
106
+ </div>
107
+ <div class="cb-settings__config__data">
108
+ <div class="cb-settings__config__data__inner">
109
+ <?php
110
+ $cv = get_site_option( 'cookiebot-script-tag-uc-attribute', 'custom' );
111
+ ?>
112
+ <label>
113
+ <input
114
+ type="radio"
115
+ name="cookiebot-script-tag-uc-attribute"
116
+ value="" <?php checked( '', $cv ); ?> />
117
+ <?php esc_html_e( 'None', 'cookiebot' ); ?>
118
+ </label>
119
+ <label>
120
+ <input
121
+ type="radio"
122
+ name="cookiebot-script-tag-uc-attribute"
123
+ value="async" <?php checked( 'async', $cv ); ?> />
124
+ async
125
+ </label>
126
+ <label>
127
+ <input
128
+ type="radio"
129
+ name="cookiebot-script-tag-uc-attribute"
130
+ value="defer" <?php checked( 'defer', $cv ); ?> />
131
+ defer
132
+ </label>
133
+ <label>
134
+ <input
135
+ type="radio"
136
+ name="cookiebot-script-tag-uc-attribute"
137
+ value="custom" <?php checked( 'custom', $cv ); ?> />
138
+ <?php esc_html_e( 'Choose per subsite', 'cookiebot' ); ?>
139
+ </label>
140
+ </div>
141
+ </div>
142
+ </div>
143
+
144
+ <div class="cb-settings__config__item">
145
+ <div class="cb-settings__config__content">
146
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Cookiebot declaration script tag', 'cookiebot' ); ?></h3>
147
+ <p class="cb-general__info__note">
148
+ <?php esc_html_e( 'Setting will apply for all subsites. Subsites will not be able to override.', 'cookiebot' ); ?>
149
+ </p>
150
+ <p class="cb-general__info__text">
151
+ <?php esc_html_e( 'Add async or defer attribute to Cookie declaration script tag. Default: Choose per subsite', 'cookiebot' ); ?>
152
+ </p>
153
+ </div>
154
+ <div class="cb-settings__config__data">
155
+ <div class="cb-settings__config__data__inner">
156
+ <?php
157
+ $cv = get_site_option( 'cookiebot-script-tag-cd-attribute', 'custom' );
158
+ ?>
159
+ <label>
160
+ <input
161
+ type="radio"
162
+ name="cookiebot-script-tag-cd-attribute"
163
+ value="" <?php checked( '', $cv ); ?> />
164
+ <?php esc_html_e( 'None', 'cookiebot' ); ?>
165
+ </label>
166
+ <label>
167
+ <input
168
+ type="radio"
169
+ name="cookiebot-script-tag-cd-attribute"
170
+ value="async" <?php checked( 'async', $cv ); ?> />
171
+ async
172
+ </label>
173
+ <label>
174
+ <input
175
+ type="radio"
176
+ name="cookiebot-script-tag-cd-attribute"
177
+ value="defer" <?php checked( 'defer', $cv ); ?> />
178
+ defer
179
+ </label>
180
+ <label>
181
+ <input
182
+ type="radio"
183
+ name="cookiebot-script-tag-cd-attribute"
184
+ value="custom" <?php checked( 'custom', $cv ); ?> />
185
+ <?php esc_html_e( 'Choose per subsite', 'cookiebot' ); ?>
186
+ </label>
187
+ </div>
188
+ </div>
189
+ </div>
190
+
191
+ <div class="cb-settings__config__item">
192
+ <div class="cb-settings__config__content">
193
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Auto update Cookiebot Plugin:', 'cookiebot' ); ?></h3>
194
+ <p class="cb-general__info__text">
195
+ <?php esc_html_e( 'Automatic update your Cookiebot plugin when new releases becomes available.', 'cookiebot' ); ?>
196
+ </p>
197
+ </div>
198
+ <div class="cb-settings__config__data">
199
+ <div class="cb-settings__config__data__inner">
200
+ <label class="switch-checkbox" for="cookiebot-autoupdate">
201
+ <input id="cookiebot-autoupdate" type="checkbox" name="cookiebot-autoupdate" value="1"
202
+ <?php
203
+ checked(
204
+ 1,
205
+ get_site_option( 'cookiebot-autoupdate' )
206
+ );
207
+ ?>
208
+ />
209
+ <div class="switcher"></div>
210
+ <?php esc_html_e( 'Automatically update Cookiebot Plugin', 'cookiebot' ); ?>
211
+ </label>
212
+ </div>
213
+ </div>
214
+ </div>
215
+
216
+ <div class="cb-settings__config__item" id="cookie-popup">
217
+ <div class="cb-settings__config__content">
218
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Hide cookie popup', 'cookiebot' ); ?></h3>
219
+ <p class="cb-general__info__note">
220
+ <?php esc_html_e( 'Setting will apply for all subsites. Subsites will not be able to override.', 'cookiebot' ); ?>
221
+ </p>
222
+ <p class="cb-general__info__text">
223
+ <?php esc_html_e( 'This checkbox will remove the cookie consent banner from your website. The declaration shortcode will still be available. If you are using Google Tag Manager (or equal), you need to add the Cookiebot script in your Tag Manager.', 'cookiebot' ); ?>
224
+ </p>
225
+ </div>
226
+ <div class="cb-settings__config__data">
227
+ <div class="cb-settings__config__data__inner">
228
+ <label class="switch-checkbox" for="cookiebot-nooutput">
229
+ <input id="cookiebot-nooutput" type="checkbox" name="cookiebot-nooutput" value="1"
230
+ <?php
231
+ checked(
232
+ 1,
233
+ get_site_option( 'cookiebot-nooutput', false )
234
+ );
235
+ ?>
236
+ />
237
+ <div class="switcher"></div>
238
+ <?php esc_html_e( 'Hide the cookie popup banner', 'cookiebot' ); ?>
239
+ </label>
240
+ </div>
241
+ </div>
242
+ </div>
243
+
244
+ <div class="cb-settings__config__item">
245
+ <div class="cb-settings__config__content">
246
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Cookiebot in WP Admin:', 'cookiebot' ); ?></h3>
247
+ <p class="cb-general__info__note">
248
+ <?php esc_html_e( 'Setting will apply for all subsites. Subsites will not be able to override.', 'cookiebot' ); ?>
249
+ </p>
250
+ <p class="cb-general__info__text">
251
+ <?php esc_html_e( 'This checkbox will disable Cookiebot to act within the WordPress Admin area', 'cookiebot' ); ?>
252
+ </p>
253
+ </div>
254
+ <div class="cb-settings__config__data">
255
+ <div class="cb-settings__config__data__inner">
256
+ <label class="switch-checkbox" for="cookiebot-nooutput-admin">
257
+ <input id="cookiebot-nooutput-admin" type="checkbox" name="cookiebot-nooutput-admin" value="1"
258
+ <?php
259
+ checked(
260
+ 1,
261
+ get_site_option( 'cookiebot-nooutput-admin' )
262
+ );
263
+ ?>
264
+ />
265
+ <div class="switcher"></div>
266
+ <?php esc_html_e( 'Disable Cookiebot in the WordPress Admin area', 'cookiebot' ); ?>
267
+ </label>
268
+ </div>
269
+ </div>
270
+ </div>
271
+ </div>
272
+ </div>
273
+ </form>
274
+ </div>
275
+ </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
276
  </div>
src/view/admin/settings/prior-consent/available-addons/tab-header.php ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
1
+ <div class="cb-addons__tab__header">
2
+ <div class="cb-addons__header__column--inner">
3
+ <div class="cb-addons__header__column submit-column">
4
+ <h2 class="cb-addons__tab__subtitle"><?php esc_html_e( 'Remember to save your changes before switching tabs', 'cookiebot' ); ?></h2>
5
+ </div>
6
+ </div>
7
+ </div>
src/view/admin/settings/prior-consent/available-addons/tab.php CHANGED
@@ -13,18 +13,19 @@ require_once ABSPATH . '/wp-includes/l10n.php';
13
  require_once ABSPATH . '/wp-admin/includes/translation-install.php';
14
  ?>
15
  <div class="postbox cookiebot-addon">
16
- <p>
17
- <label for="<?php echo 'enabled_' . esc_attr( $addon_option_name ); ?>">
18
- <?php esc_html_e( 'Enable', 'cookiebot' ); ?>
 
 
 
 
 
 
 
19
  </label>
20
- <input <?php checked( 1, $addon_is_enabled ); ?>
21
- id="<?php echo 'enabled_' . esc_attr( $addon_option_name ); ?>"
22
- name="cookiebot_available_addons[<?php echo esc_attr( $addon_option_name ); ?>][enabled]"
23
- type="checkbox"
24
- value="1"
25
- />
26
- </p>
27
- <p><?php esc_html_e( 'Check one or multiple cookie types:', 'cookiebot' ); ?></p>
28
  <ul class="cookietypes">
29
  <li>
30
  <input <?php cookiebot_addons_checked_selected_helper( $addon_cookie_types, 'preferences' ); ?>
@@ -33,7 +34,7 @@ require_once ABSPATH . '/wp-admin/includes/translation-install.php';
33
  value="preferences"
34
  name="cookiebot_available_addons[<?php echo esc_attr( $addon_option_name ); ?>][cookie_type][]"
35
  >
36
- <label>Preferences</label>
37
  </li>
38
  <li>
39
  <input <?php cookiebot_addons_checked_selected_helper( $addon_cookie_types, 'statistics' ); ?>
@@ -42,7 +43,7 @@ require_once ABSPATH . '/wp-admin/includes/translation-install.php';
42
  value="statistics"
43
  name="cookiebot_available_addons[<?php echo esc_attr( $addon_option_name ); ?>][cookie_type][]"
44
  >
45
- <label>Statistics</label>
46
  </li>
47
  <li>
48
  <input <?php cookiebot_addons_checked_selected_helper( $addon_cookie_types, 'marketing' ); ?>
@@ -51,12 +52,11 @@ require_once ABSPATH . '/wp-admin/includes/translation-install.php';
51
  value="marketing"
52
  name="cookiebot_available_addons[<?php echo esc_attr( $addon_option_name ); ?>][cookie_type][]"
53
  >
54
- <label>Marketing</label>
55
  </li>
56
  </ul>
57
-
58
- <p>
59
- <label><?php esc_html_e( 'Display a placeholder', 'cookiebot' ); ?></label>
60
  <input <?php checked( 1, $addon_placeholder_is_enabled ); ?>
61
  type="checkbox"
62
  class="placeholder_enable"
@@ -64,6 +64,7 @@ require_once ABSPATH . '/wp-admin/includes/translation-install.php';
64
  name="cookiebot_available_addons[<?php echo esc_attr( $addon_option_name ); ?>][placeholder][enabled]"
65
  value="1"
66
  >
 
67
  </p>
68
 
69
  <div <?php echo ( ! $addon_placeholder_is_enabled ) ? 'style="display:none"' : ''; ?>
@@ -72,7 +73,7 @@ require_once ABSPATH . '/wp-admin/includes/translation-install.php';
72
  >
73
  <?php echo $placeholders_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
74
  <p class="add_placeholder_language">
75
- <button class="btn_add_language button button-secondary"
76
  data-addon="<?php echo esc_attr( $addon_option_name ); ?>">
77
  <?php esc_html_e( '+ Add language', 'cookiebot' ); ?>
78
  </button>
13
  require_once ABSPATH . '/wp-admin/includes/translation-install.php';
14
  ?>
15
  <div class="postbox cookiebot-addon">
16
+ <div class="cookiebot-addon-enable">
17
+ <label class="switch-checkbox" for="<?php echo 'enabled_' . esc_attr( $addon_option_name ); ?>">
18
+ <input <?php checked( 1, $addon_is_enabled ); ?>
19
+ id="<?php echo 'enabled_' . esc_attr( $addon_option_name ); ?>"
20
+ name="cookiebot_available_addons[<?php echo esc_attr( $addon_option_name ); ?>][enabled]"
21
+ type="checkbox"
22
+ value="1"
23
+ />
24
+ <div class="switcher"></div>
25
+ <?php esc_html_e( 'Plugin enabled', 'cookiebot' ); ?>
26
  </label>
27
+ </div>
28
+ <p class="cookiebot-addon-text"><?php esc_html_e( 'Check one or multiple cookie types:', 'cookiebot' ); ?></p>
 
 
 
 
 
 
29
  <ul class="cookietypes">
30
  <li>
31
  <input <?php cookiebot_addons_checked_selected_helper( $addon_cookie_types, 'preferences' ); ?>
34
  value="preferences"
35
  name="cookiebot_available_addons[<?php echo esc_attr( $addon_option_name ); ?>][cookie_type][]"
36
  >
37
+ <label class="cookiebot-addon-text">Preferences</label>
38
  </li>
39
  <li>
40
  <input <?php cookiebot_addons_checked_selected_helper( $addon_cookie_types, 'statistics' ); ?>
43
  value="statistics"
44
  name="cookiebot_available_addons[<?php echo esc_attr( $addon_option_name ); ?>][cookie_type][]"
45
  >
46
+ <label class="cookiebot-addon-text">Statistics</label>
47
  </li>
48
  <li>
49
  <input <?php cookiebot_addons_checked_selected_helper( $addon_cookie_types, 'marketing' ); ?>
52
  value="marketing"
53
  name="cookiebot_available_addons[<?php echo esc_attr( $addon_option_name ); ?>][cookie_type][]"
54
  >
55
+ <label class="cookiebot-addon-text">Marketing</label>
56
  </li>
57
  </ul>
58
+ <p class="cookiebot-addon-text"><?php esc_html_e( 'Placeholder text:', 'cookiebot' ); ?></p>
59
+ <p class="cookiebot-addon-placeholder">
 
60
  <input <?php checked( 1, $addon_placeholder_is_enabled ); ?>
61
  type="checkbox"
62
  class="placeholder_enable"
64
  name="cookiebot_available_addons[<?php echo esc_attr( $addon_option_name ); ?>][placeholder][enabled]"
65
  value="1"
66
  >
67
+ <label class="cookiebot-addon-text"><?php esc_html_e( 'Display a placeholder', 'cookiebot' ); ?></label>
68
  </p>
69
 
70
  <div <?php echo ( ! $addon_placeholder_is_enabled ) ? 'style="display:none"' : ''; ?>
73
  >
74
  <?php echo $placeholders_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
75
  <p class="add_placeholder_language">
76
+ <button class="btn_add_language cb-btn cb-main-btn"
77
  data-addon="<?php echo esc_attr( $addon_option_name ); ?>">
78
  <?php esc_html_e( '+ Add language', 'cookiebot' ); ?>
79
  </button>
src/view/admin/settings/prior-consent/jetpack-widgets/tab-header.php CHANGED
@@ -1 +1,18 @@
1
- <p><?php echo esc_html__( 'Jetpack settings.', 'cookiebot' ); ?></p>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ $jetpack_enabled = isset( get_option( 'cookiebot_available_addons' )['jetpack']['enabled'] ) && get_option( 'cookiebot_available_addons' )['jetpack']['enabled'];
3
+ ?>
4
+ <div class="cb-addons__tab__header">
5
+ <div class="cb-addons__header__column--inner">
6
+ <div class="cb-addons__header__column">
7
+ <h2 class="cb-addons__tab__title"><?php esc_html_e( 'Jetpack settings', 'cookiebot' ); ?></h2>
8
+ <p class="cb-addons__tab__text"><?php esc_html_e( 'Enable Jetpack on "Available Addons" to see this page options.', 'cookiebot' ); ?></p>
9
+ </div>
10
+ </div>
11
+ <?php if ( $jetpack_enabled ) : ?>
12
+ <div class="cb-addons__header__column--inner">
13
+ <div class="cb-addons__header__column submit-column">
14
+ <h2 class="cb-addons__tab__subtitle"><?php esc_html_e( 'Remember to save your changes before switching tabs', 'cookiebot' ); ?></h2>
15
+ </div>
16
+ </div>
17
+ <?php endif; ?>
18
+ </div>
src/view/admin/settings/prior-consent/jetpack-widgets/tab.php CHANGED
@@ -66,7 +66,7 @@ use function cybot\cookiebot\lib\cookiebot_addons_checked_selected_helper;
66
  >
67
  <?php echo $placeholders_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
68
  <p class="add_placeholder_language">
69
- <button class="btn_add_language button button-secondary"
70
  data-addon="<?php echo esc_attr( $widget_option_name ); ?>">
71
  <?php esc_html_e( '+ Add language', 'cookiebot' ); ?>
72
  </button>
66
  >
67
  <?php echo $placeholders_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
68
  <p class="add_placeholder_language">
69
+ <button class="btn_add_language cb-btn cb-main-btn"
70
  data-addon="<?php echo esc_attr( $widget_option_name ); ?>">
71
  <?php esc_html_e( '+ Add language', 'cookiebot' ); ?>
72
  </button>
src/view/admin/settings/prior-consent/other-addons/embed-autocorrect-extra-addon-options.php CHANGED
@@ -5,7 +5,7 @@
5
  /** @var $default_regex string */
6
  ?>
7
  <div class="show_advanced_options">
8
- <button class="button button-secondary">
9
  <?php
10
  esc_html_e(
11
  'Show advanced options',
@@ -30,7 +30,7 @@
30
  ><?php echo esc_textarea( $regex ); ?></textarea>
31
 
32
  <?php if ( $regex_is_default ) : ?>
33
- <button id="edit_embed_regex" class="button">
34
  <?php
35
  esc_html_e(
36
  'Edit regex',
@@ -42,7 +42,7 @@
42
 
43
  <button
44
  id="btn_default_embed_regex"
45
- class="button<?php echo ( $regex_is_default ) ? ' hidden' : ''; ?>"
46
  type="button"
47
  value="Reset to default regex">
48
  <?php
5
  /** @var $default_regex string */
6
  ?>
7
  <div class="show_advanced_options">
8
+ <button class="cb-btn cb-main-btn">
9
  <?php
10
  esc_html_e(
11
  'Show advanced options',
30
  ><?php echo esc_textarea( $regex ); ?></textarea>
31
 
32
  <?php if ( $regex_is_default ) : ?>
33
+ <button id="edit_embed_regex" class="cb-btn cb-main-btn">
34
  <?php
35
  esc_html_e(
36
  'Edit regex',
42
 
43
  <button
44
  id="btn_default_embed_regex"
45
+ class="cb-btn cb-main-btn<?php echo ( $regex_is_default ) ? ' hidden' : ''; ?>"
46
  type="button"
47
  value="Reset to default regex">
48
  <?php
src/view/admin/settings/prior-consent/page.php CHANGED
@@ -1,52 +1,68 @@
1
  <?php
2
- /** @var Settings_Page_Tab[] $settings_page_tabs */
3
- /** @var Settings_Page_Tab $active_tab */
4
 
5
  use cybot\cookiebot\lib\Settings_Page_Tab;
6
 
 
 
 
 
 
 
 
 
 
 
7
  ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8
 
9
- <!-- Create a header in the default WordPress 'wrap' container -->
10
- <div class="wrap">
11
- <div id="icon-themes" class="icon32"></div>
12
- <h2><?php esc_html_e( 'Prior consent', 'cookiebot' ); ?></h2>
13
- <div class="notice inline notice-warning notice-alt cookiebot-notice">
14
- <p>
15
- <?php esc_html_e( 'These add-ons are produced by an open-source community of developers. This is done to help make it easier for WordPress users to implement ‘prior consent’ for cookies and trackers set by plugins that do not offer this as a built-in functionality.', 'cookiebot' ); ?>
16
- </p>
17
- <p>
18
- <?php esc_html_e( 'The add-ons are currently the best alternative to a WordPress Core framework that can signal the user’s consent state to other plugins (if and when this will be implemented is unknown) and to those plugins who do not yet offer native support for Cookiebot built into the plugin itself.', 'cookiebot' ); ?>
19
- </p>
20
- <p>
21
- <?php esc_html_e( 'We do not assume any responsibility for the use of these add-ons. If one of the plugins that the add-ons hook into makes a ‘breaking change’, there may be a period of time where the add-on will not work properly until it has been updated to accommodate the changes in the plugin.', 'cookiebot' ); ?>
22
- </p>
23
- <p>
24
- <strong>
25
- <?php
26
- echo sprintf(
27
- // translators: The first placeholder is the HTML anchor open tag, and the second placeholder is the closing tag.
28
- esc_html__( 'If your favourite plugin isn\'t supported you\'re welcome to contribute or request on our %1$sGithub development page.%2$s', 'cookiebot' ),
29
- '<a href="https://github.com/CybotAS/CookiebotAddons" target="_blank">',
30
- '</a>'
31
- );
32
- ?>
33
- </strong>
34
- </p>
35
  </div>
36
- <h2 class="nav-tab-wrapper">
37
- <?php foreach ( $settings_page_tabs as $settings_page_tab ) : ?>
38
- <a href="<?php echo esc_url( $settings_page_tab->get_tab_href() ); ?>" class="<?php echo esc_attr( $settings_page_tab->get_classes() ); ?>">
39
- <?php echo esc_html( $settings_page_tab->get_label() ); ?>
40
- </a>
41
- <?php endforeach; ?>
42
- </h2>
43
- <form method="post" action="options.php" class="<?php echo esc_attr( $active_tab->get_name() ); ?>">
44
- <?php
45
- settings_fields( $active_tab->get_settings_fields_option_group() );
46
- do_settings_sections( $active_tab->get_page_name() );
47
- if ( $active_tab->has_submit_button() ) {
48
- submit_button();
49
- }
50
- ?>
51
- </form>
52
  </div>
1
  <?php
2
+ use cybot\cookiebot\settings\templates\Header;
3
+ use cybot\cookiebot\settings\templates\Main_Tabs;
4
 
5
  use cybot\cookiebot\lib\Settings_Page_Tab;
6
 
7
+ /**
8
+ * @var Settings_Page_Tab[] $settings_page_tabs
9
+ * @var Settings_Page_Tab $active_tab
10
+ */
11
+
12
+ $header = new Header();
13
+ $main_tabs = new Main_Tabs();
14
+ $jetpack_enabled = isset( get_option( 'cookiebot_available_addons' )['jetpack']['enabled'] ) && get_option( 'cookiebot_available_addons' )['jetpack']['enabled'];
15
+
16
+ $header->display();
17
  ?>
18
+ <div class="cb-body">
19
+ <div class="cb-wrapper">
20
+ <?php $main_tabs->display( 'addons' ); ?>
21
+ <div class="cb-main__content">
22
+ <form method="post" action="options.php" class="<?php echo esc_attr( $active_tab->get_name() ); ?>">
23
+ <div class="cb-settings__header">
24
+ <h1 class="cb-main__page_title"><?php esc_html_e( 'Plugins', 'cookiebot' ); ?></h1>
25
+ <?php
26
+ if ( $active_tab->has_submit_button() ) {
27
+ if ( $active_tab->get_name() === 'jetpack' ) {
28
+ if ( $jetpack_enabled ) {
29
+ submit_button();
30
+ }
31
+ } else {
32
+ submit_button();
33
+ }
34
+ }
35
+ ?>
36
+ </div>
37
+
38
+ <div class="cb-settings__tabs">
39
+ <?php foreach ( $settings_page_tabs as $settings_page_tab ) : ?>
40
+ <a href="<?php echo esc_url( $settings_page_tab->get_tab_href() ); ?>" class="cb-settings__tabs__item <?php echo esc_attr( $settings_page_tab->get_classes() ); ?>">
41
+ <?php echo esc_html( $settings_page_tab->get_label() ); ?>
42
+ </a>
43
+ <?php endforeach; ?>
44
+ </div>
45
+
46
+ <div class="cb-settings__tabs__content">
47
+ <div class="cb-settings__tabs__content--item">
48
+
49
+ <?php
50
+ settings_fields( $active_tab->get_settings_fields_option_group() );
51
+ do_settings_sections( $active_tab->get_page_name() );
52
+ if ( $active_tab->has_submit_button() ) {
53
+ if ( $active_tab->get_name() === 'jetpack' ) {
54
+ if ( $jetpack_enabled ) {
55
+ submit_button();
56
+ }
57
+ } else {
58
+ submit_button();
59
+ }
60
+ }
61
+ ?>
62
 
63
+ </div>
64
+ </div>
65
+ </form>
66
+ </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
67
  </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
68
  </div>
src/view/admin/settings/prior-consent/partials/extra-information.php CHANGED
@@ -4,7 +4,7 @@
4
  * @var string[] $extra_information_lines
5
  */
6
  ?>
7
- <?php echo esc_html( $label ); ?>
8
  <div class="extra_information">
9
  <?php foreach ( $extra_information_lines as $extra_information_line ) : ?>
10
  <p><?php echo esc_html( $extra_information_line ); ?></p>
4
  * @var string[] $extra_information_lines
5
  */
6
  ?>
7
+ <div class="plugin-title"><?php echo esc_html( $label ); ?></div>
8
  <div class="extra_information">
9
  <?php foreach ( $extra_information_lines as $extra_information_line ) : ?>
10
  <p><?php echo esc_html( $extra_information_line ); ?></p>
src/view/admin/settings/prior-consent/partials/info-tab-header.php ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
1
+ <div class="cb-addons__tab__header">
2
+ <div class="cb-addons__header__column--inner">
3
+ <div class="cb-addons__header__column">
4
+ <h2 class="cb-addons__tab__title"><?php esc_html_e( 'Info', 'cookiebot' ); ?></h2>
5
+ <p class="cb-addons__tab__text"><?php esc_html_e( 'These add-ons are produced by an open-source community of developers. This is done to help make it easier for WordPress users to implement ‘prior consent’ for cookies and trackers set by plugins that do not offer this as a built-in function. The add-ons are currently the best alternative to a WordPress Core framework that can signal the user’s consent state to other plugins (if and when this will be implemented is unknown) and to those plugins that do not yet offer native support for Cookiebot CMP. ', 'cookiebot' ); ?></p>
6
+ </div>
7
+ </div>
8
+ </div>
src/view/admin/settings/prior-consent/partials/placeholder-submitbox-default.php CHANGED
@@ -6,10 +6,10 @@
6
  ?>
7
  <div class="placeholder_content">
8
  <p>
9
- <label><?php esc_html_e( 'Language', 'cookiebot' ); ?></label>
10
  <?php
11
  echo $site_default_languages_dropdown_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
12
  ?>
 
13
  </p>
14
  <p>
15
  <textarea cols="80" rows="5" name="<?php echo esc_attr( $name ); ?>"><?php echo esc_textarea( $default_placeholder ); ?></textarea>
6
  ?>
7
  <div class="placeholder_content">
8
  <p>
 
9
  <?php
10
  echo $site_default_languages_dropdown_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
11
  ?>
12
+ <label><?php esc_html_e( 'Language', 'cookiebot' ); ?></label>
13
  </p>
14
  <p>
15
  <textarea cols="80" rows="5" name="<?php echo esc_attr( $name ); ?>"><?php echo esc_textarea( $default_placeholder ); ?></textarea>
src/view/admin/settings/prior-consent/partials/placeholder-submitboxes.php CHANGED
@@ -15,22 +15,22 @@ foreach ( $placeholders as $placeholder ) :
15
  ?>
16
  <div class="placeholder_content submitbox">
17
  <p>
18
- <label><?php esc_html_e( 'Language', 'cookiebot' ); ?></label>
19
  <?php
20
  echo $languages_dropdown_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
21
  ?>
22
  <?php if ( $removable ) : ?>
23
- <a href="" class="submitdelete deletion">
24
  <?php esc_html_e( 'Remove language', 'cookiebot' ); ?>
25
  </a>
26
  <?php endif; ?>
27
  </p>
28
  <p>
29
- <textarea
30
- cols="80"
31
- rows="5"
32
- name="<?php echo esc_attr( $name ); ?>"
33
- ><?php echo esc_textarea( $placeholder_content ); ?></textarea>
34
  <span class="help-tip" title="<?php echo esc_attr( $placeholder_helper ); ?>"></span>
35
  </p>
36
  </div>
15
  ?>
16
  <div class="placeholder_content submitbox">
17
  <p>
18
+ <label class="placeholder_title"><?php esc_html_e( 'Language', 'cookiebot' ); ?>:</label>
19
  <?php
20
  echo $languages_dropdown_html; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
21
  ?>
22
  <?php if ( $removable ) : ?>
23
+ <a href="" class="submitdelete deletion cb-btn cb-main-btn">
24
  <?php esc_html_e( 'Remove language', 'cookiebot' ); ?>
25
  </a>
26
  <?php endif; ?>
27
  </p>
28
  <p>
29
+ <textarea class="placeholder_textarea"
30
+ cols="5"
31
+ rows="5"
32
+ name="<?php echo esc_attr( $name ); ?>"
33
+ ><?php echo esc_textarea( $placeholder_content ); ?></textarea>
34
  <span class="help-tip" title="<?php echo esc_attr( $placeholder_helper ); ?>"></span>
35
  </p>
36
  </div>
src/view/admin/settings/prior-consent/unavailable-addons/field.php CHANGED
@@ -3,5 +3,5 @@
3
 
4
  ?>
5
  <div class="postbox cookiebot-addon">
6
- <i><?php echo esc_html( $message ); ?></i>
7
  </div>
3
 
4
  ?>
5
  <div class="postbox cookiebot-addon">
6
+ <p><?php echo esc_html( $message ); ?></p>
7
  </div>
src/view/admin/settings/prior-consent/unavailable-addons/tab-header.php CHANGED
@@ -1 +1,8 @@
1
- <p><?php echo esc_html__( 'The following addons are unavailable. This is because the corresponding plugin is not installed or activated.', 'cookiebot' ); ?></p>
 
 
 
 
 
 
 
1
+ <div class="cb-addons__tab__header">
2
+ <div class="cb-addons__header__column--inner">
3
+ <div class="cb-addons__header__column">
4
+ <h2 class="cb-addons__tab__title"><?php esc_html_e( 'Unavailable plugins', 'cookiebot' ); ?></h2>
5
+ <p class="cb-addons__tab__text"><?php esc_html_e( 'The following addons are unavailable. This is because the corresponding plugin is not installed or activated.', 'cookiebot' ); ?></p>
6
+ </div>
7
+ </div>
8
+ </div>
src/view/admin/settings/settings-page.php CHANGED
@@ -1,5 +1,10 @@
1
  <?php
 
 
2
 
 
 
 
3
 
4
  /**
5
  * @var string $cbid
@@ -17,184 +22,146 @@
17
  * @var string $cookie_blocking_mode
18
  * @var string $add_language_gif_url
19
  */
 
 
 
 
 
 
 
 
20
  ?>
21
- <div class="wrap">
22
- <h1><?php esc_html_e( 'Cookiebot Settings', 'cookiebot' ); ?></h1>
23
- <a href="https://www.cookiebot.com">
24
- <img
25
- src="<?php echo esc_url( $cookiebot_logo ); ?>"
26
- alt="Cookiebot logo"
27
- style="float:right;margin-left:1em;">
28
- </a>
29
- <p>
30
- <?php
31
- printf(
32
- /* translators: %1$s: GDPR URL; %2$s: extra information about the requirements */
33
- esc_html__(
34
- 'Cookiebot enables your website to comply with current legislation in the EU on the use of cookies for user tracking and profiling. The EU ePrivacy Directive requires prior, informed consent of your site users, while the %1$s %2$s.',
35
- 'cookiebot'
36
- ),
37
- sprintf(
38
- '<a href="%s" target="_blank">%s</a>',
39
- esc_url( $cookiebot_gdpr_url ),
40
- esc_html__( 'General Data Protection Regulation (GDPR)', 'cookiebot' )
41
- ),
42
- esc_html__(
43
- ' requires you to document each consent. At the same time you must be able to account for what user data you share with embedded third-party services on your website and where in the world the user data is sent.',
44
- 'cookiebot'
45
- )
46
- );
47
- ?>
48
- </p>
49
- <form method="post" action="options.php">
50
- <?php settings_fields( 'cookiebot' ); ?>
51
- <?php do_settings_sections( 'cookiebot' ); ?>
52
- <table class="form-table">
53
- <tr>
54
- <th scope="row"><?php esc_html_e( 'Cookiebot ID', 'cookiebot' ); ?></th>
55
- <td>
56
- <input <?php echo ( $is_ms ) ? ' placeholder="' . esc_attr( $network_cbid ) . '"' : ''; ?>
57
- type="text" name="cookiebot-cbid"
58
- value="<?php echo esc_attr( $cbid ); ?>"
59
- style="width:300px"
60
- />
61
- <p class="description">
62
- <?php esc_html_e( 'Need an ID?', 'cookiebot' ); ?>
63
- <a href="https://www.cookiebot.com/goto/signup" target="_blank">
64
- <?php
65
- esc_html_e(
66
- 'Sign up for free on cookiebot.com',
67
- 'cookiebot'
68
- );
69
- ?>
70
- </a>
71
- </p>
72
- </td>
73
- </tr>
74
- <tr>
75
- <th scope="row">
76
- <?php esc_html_e( 'Cookie-blocking mode', 'cookiebot' ); ?>
77
- </th>
78
- <td>
79
- <label>
80
- <input <?php checked( 'auto', $cookie_blocking_mode ); ?>
81
- type="radio"
82
- name="cookiebot-cookie-blocking-mode"
83
- value="auto"
84
- />
85
- <?php esc_html_e( 'Automatic', 'cookiebot' ); ?>
86
- </label>
87
- &nbsp; &nbsp;
88
- <label>
89
- <input <?php checked( 'manual', $cookie_blocking_mode ); ?>
90
- type="radio"
91
- name="cookiebot-cookie-blocking-mode"
92
- value="manual"
93
- />
94
- <?php esc_html_e( 'Manual', 'cookiebot' ); ?>
95
- </label>
96
- <p class="description">
97
- <?php esc_html_e( 'Automatic block cookies (except necessary) until the user has given their consent.', 'cookiebot' ); ?>
98
- <a
99
- href="https://support.cookiebot.com/hc/en-us/articles/360009063100-Automatic-Cookie-Blocking-How-does-it-work-"
100
- target="_blank">
101
- <?php esc_html_e( 'Learn more', 'cookiebot' ); ?>
102
- </a>
103
- </p>
104
- </td>
105
- </tr>
106
- <tr>
107
- <th scope="row"><?php esc_html_e( 'Cookiebot Language', 'cookiebot' ); ?></th>
108
- <td>
109
- <div>
110
- <select name="cookiebot-language" id="cookiebot-language">
111
- <option value=""><?php esc_html_e( 'Default (Autodetect)', 'cookiebot' ); ?></option>
112
- <option value="_wp"<?php echo ( $current_lang === '_wp' ) ? ' selected' : ''; ?>>
113
- <?php
114
- esc_html_e(
115
- 'Use WordPress Language',
116
- 'cookiebot'
117
- );
118
- ?>
119
- </option>
120
- <?php
121
- foreach ( $supported_languages as $lang_code => $lang_name ) {
122
- echo '<option value="' . esc_attr( $lang_code ) . '"' . ( ( $current_lang === esc_attr( $lang_code ) ) ? ' selected' : '' ) . '>' . esc_html( $lang_name ) . '</option>';
123
- }
124
- ?>
125
- </select>
126
  </div>
127
- <div
128
- class="notice inline notice-warning notice-alt cookiebot-notice"
129
- style="padding:12px;font-size:13px;display:inline-block;">
130
- <div
131
- style="<?php echo ( $current_lang === '' ) ? 'display:none;' : ''; ?>"
132
- id="info_lang_specified">
133
- <?php esc_html_e( 'You need to add the language in the Cookiebot administration tool.', 'cookiebot' ); ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
134
  </div>
135
- <div
136
- style="<?php echo ( $current_lang === '' ) ? '' : 'display:none;'; ?>"
137
- id="info_lang_autodetect">
138
- <?php
139
- esc_html_e(
140
- 'You need to add all languages that you want auto-detected in the Cookiebot administration tool.',
141
- 'cookiebot'
142
- );
143
- ?>
144
- <br/>
145
- <?php
146
- esc_html_e(
147
- 'The auto-detect checkbox needs to be enabled in the Cookiebot administration tool.',
148
- 'cookiebot'
149
- );
150
- ?>
151
- <br/>
152
- <?php
153
- esc_html_e(
154
- 'If the auto-detected language is not supported, Cookiebot will use the default language.',
155
- 'cookiebot'
156
- );
157
- ?>
158
  </div>
159
- <br>
160
 
161
- <a
162
- href="#"
163
- id="show_add_language_guide">
164
- <?php esc_html_e( 'Show guide to add languages', 'cookiebot' ); ?>
165
- </a>
166
- &nbsp;
167
- <a
168
- href="https://support.cookiebot.com/hc/en-us/articles/360003793394-How-do-I-set-the-language-of-the-consent-banner-dialog-"
169
- target="_blank">
170
- <?php esc_html_e( 'Read more here', 'cookiebot' ); ?>
171
- </a>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
172
 
173
- <div id="add_language_guide" style="display:none;">
174
- <img
175
- src="<?php echo esc_attr( $add_language_gif_url ); ?>"
176
- alt="Add language in Cookiebot administration tool"/>
177
- <br/>
178
- <a
179
- href="#"
180
- id="hide_add_language_guide">
181
- <?php esc_html_e( 'Hide guide', 'cookiebot' ); ?>
182
- </a>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
183
  </div>
184
- </div>
185
- </td>
186
- </tr>
187
- </table>
188
- <h3 id="advanced_settings_link"
189
- class="cookiebot_fieldset_header"><?php esc_html_e( 'Advanced settings', 'cookiebot' ); ?></h3>
190
- <div id="advanced_settings" style="display:none;">
191
- <table class="form-table">
192
- <tr id="cookiebot-setting-async">
193
- <th scope="row">
194
- <?php esc_html_e( 'Add async or defer attribute', 'cookiebot' ); ?>
195
- <br/><?php esc_html_e( 'Consent banner script tag', 'cookiebot' ); ?>
196
- </th>
197
- <td>
198
  <?php
199
  $cv = get_option( 'cookiebot-script-tag-uc-attribute', 'async' );
200
  $disabled = false;
@@ -203,401 +170,302 @@
203
  $cv = $network_scrip_tag_uc_attr;
204
  }
205
  ?>
206
- <label>
207
- <input
208
- type="radio"
209
- name="cookiebot-script-tag-uc-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
210
- value="" <?php checked( '', $cv ); ?> />
211
- <i><?php esc_html_e( 'None', 'cookiebot' ); ?></i>
212
- </label>
213
- &nbsp; &nbsp;
214
- <label>
215
- <input
216
- type="radio"
217
- name="cookiebot-script-tag-uc-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
218
- value="async" <?php checked( 'async', $cv ); ?> />
219
- async
220
- </label>
221
- &nbsp; &nbsp;
222
- <label>
223
- <input
224
- type="radio"
225
- name="cookiebot-script-tag-uc-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
226
- value="defer" <?php checked( 'defer', $cv ); ?> />
227
- defer
228
- </label>
229
- <p class="description">
230
- <?php
231
- if ( $disabled ) {
232
- echo '<b>' . esc_html__(
233
- 'Network setting applied. Please contact website administrator to change this setting.',
234
- 'cookiebot'
235
- ) . '</b><br />';
236
- }
237
- ?>
238
- <?php esc_html_e( 'Add async or defer attribute to Cookiebot script tag. Default: async', 'cookiebot' ); ?>
239
- </p>
240
- </td>
241
- </tr>
242
- <tr>
243
- <th scope="row">
244
- <?php esc_html_e( 'Add async or defer attribute', 'cookiebot' ); ?>
245
- <br/><?php esc_html_e( 'Cookie declaration script tag', 'cookiebot' ); ?>
246
- </th>
247
- <td>
248
- <?php
249
- $cv = get_option( 'cookiebot-script-tag-cd-attribute', 'async' );
250
- $disabled = false;
251
- if ( $is_ms && $network_scrip_tag_cd_attr !== 'custom' ) {
252
- $disabled = true;
253
- $cv = $network_scrip_tag_cd_attr;
254
- }
255
- ?>
256
- <label>
257
- <input
258
- type="radio"
259
- name="cookiebot-script-tag-cd-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
260
- value="" <?php checked( '', $cv ); ?>/>
261
- <i><?php esc_html_e( 'None', 'cookiebot' ); ?></i>
262
- </label>
263
- &nbsp; &nbsp;
264
- <label>
265
- <input
266
- type="radio"
267
- name="cookiebot-script-tag-cd-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
268
- value="async" <?php checked( 'async', $cv ); ?>/>
269
- async
270
- </label>
271
- &nbsp; &nbsp;
272
- <label>
273
- <input
274
- type="radio"
275
- name="cookiebot-script-tag-cd-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
276
- value="defer" <?php checked( 'defer', $cv ); ?>/>
277
- defer
278
- </label>
279
- <p class="description">
280
- <?php
281
- if ( $disabled ) {
282
- echo '<b>' . esc_html__(
283
- 'Network setting applied. Please contact website administrator to change this setting.',
284
- 'cookiebot'
285
- ) . '</b><br />';
286
- }
287
- ?>
288
- <?php esc_html_e( 'Add async or defer attribute to Cookiebot script tag. Default: async', 'cookiebot' ); ?>
289
- </p>
290
- </td>
291
- </tr>
292
- <?php
293
- if ( ! is_multisite() ) {
294
- ?>
295
- <tr>
296
- <th scope="row"><?php esc_html_e( 'Auto-update Cookiebot', 'cookiebot' ); ?></th>
297
- <td>
298
- <input type="checkbox" name="cookiebot-autoupdate" value="1"
299
- <?php
300
- checked(
301
- 1,
302
- get_option( 'cookiebot-autoupdate', false )
303
- );
304
- ?>
305
- />
306
- <p class="description">
307
- <?php esc_html_e( 'Automatic update your Cookiebot plugin when new releases becomes available.', 'cookiebot' ); ?>
308
- </p>
309
- </td>
310
- </tr>
311
- <?php
312
- }
313
- ?>
314
- <tr id="cookiebot-setting-hide-popup">
315
- <th scope="row"><?php esc_html_e( 'Hide Cookie Popup', 'cookiebot' ); ?></th>
316
- <td>
317
- <?php
318
- $disabled = false;
319
- if ( $is_ms && get_site_option( 'cookiebot-nooutput' ) ) {
320
- $disabled = true;
321
- echo '<input type="checkbox" checked disabled />';
322
- } else {
323
- ?>
324
- <input type="checkbox" name="cookiebot-nooutput" value="1"
325
- <?php
326
- checked(
327
- 1,
328
- get_option( 'cookiebot-nooutput', false )
329
- );
330
- ?>
331
- />
332
- <?php
333
- }
334
- ?>
335
- <p class="description">
336
- <?php
337
- if ( $disabled ) {
338
- echo '<b>' . esc_html__(
339
- 'Network setting applied. Please contact website administrator to change this setting.',
340
- 'cookiebot'
341
- ) . '</b><br />';
342
- }
343
- ?>
344
- <b>
345
- <?php
346
- esc_html_e(
347
- 'This checkbox will remove the cookie consent banner from your website. The <i>[cookie_declaration]</i> shortcode will still be available.',
348
- 'cookiebot'
349
- );
350
- ?>
351
- </b><br/>
352
- <?php
353
- esc_html_e(
354
- 'If you are using Google Tag Manager (or equal), you need to add the Cookiebot script in your Tag Manager.',
355
- 'cookiebot'
356
- );
357
- ?>
358
- <br/>
359
- <a
360
- href="https://support.cookiebot.com/hc/en-us/articles/360003793854-Google-Tag-Manager-deployment"
361
- target="_blank">
362
- <?php esc_html_e( 'See a detailed guide here', 'cookiebot' ); ?>
363
- </a>
364
- </p>
365
- </td>
366
- </tr>
367
- <tr>
368
- <th scope="row"><?php esc_html_e( 'Disable Cookiebot in WP Admin', 'cookiebot' ); ?></th>
369
- <td>
370
- <?php
371
- $disabled = false;
372
- if ( $is_ms && get_site_option( 'cookiebot-nooutput-admin' ) ) {
373
- echo '<input type="checkbox" checked disabled />';
374
- $disabled = true;
375
- } else {
376
- ?>
377
- <input type="checkbox" name="cookiebot-nooutput-admin" value="1"
378
- <?php
379
- checked(
380
- 1,
381
- get_option( 'cookiebot-nooutput-admin', false )
382
- );
383
- ?>
384
- />
385
- <?php
386
- }
387
- ?>
388
- <p class="description">
389
- <?php
390
- if ( $disabled ) {
391
- echo '<b>' . esc_html__( 'Network setting applied. Please contact website administrator to change this setting.', 'cookiebot' ) . '</b><br />';
392
- }
393
- ?>
394
- <b><?php esc_html_e( 'This checkbox will disable Cookiebot in the WordPress Admin area.', 'cookiebot' ); ?></b>
395
- </p>
396
- </td>
397
- </tr>
398
- <tr>
399
- <th scope="row"><?php esc_html_e( 'Enable Cookiebot on front end while logged in', 'cookiebot' ); ?></th>
400
- <td>
401
- <?php
402
- $disabled = false;
403
- if ( $is_ms && get_site_option( 'cookiebot-output-logged-in' ) ) {
404
- echo '<input type="checkbox" checked disabled />';
405
- $disabled = true;
406
- } else {
407
- ?>
408
- <input type="checkbox" name="cookiebot-output-logged-in" value="1"
409
- <?php
410
- checked(
411
- 1,
412
- get_option( 'cookiebot-output-logged-in', false )
413
- );
414
- ?>
415
- />
416
- <?php
417
- }
418
- ?>
419
- <p class="description">
420
- <?php
421
- if ( $disabled ) {
422
- echo '<b>' . esc_html__( 'Network setting applied. Please contact website administrator to change this setting.', 'cookiebot' ) . '</b><br />';
423
- }
424
- ?>
425
- <b><?php esc_html_e( 'This checkbox will enable Cookiebot on front end while you\'re logged in', 'cookiebot' ); ?></b>
426
- </p>
427
- </td>
428
- </tr>
429
- <tr>
430
- <th scope="row"><?php esc_html_e( 'Ignore enqueued scripts from cookiebot scan', 'cookiebot' ); ?></th>
431
- <td>
432
- <textarea
433
- name="cookiebot-ignore-scripts"
434
- rows="4"
435
- cols="50"
436
- placeholder="<?php esc_attr_e( 'add script source URL, one per line', 'cookiebot' ); ?>"
437
- ><?php echo esc_html( get_option( 'cookiebot-ignore-scripts', false ) ); ?></textarea>
438
- <br/>
439
- <span>
440
- <?php esc_html_e( 'List enqueued scripts source URL (one per line) to ignore cookiebot scan. Partial source URL will also work. Ex. wp-content/plugins/woocommerce will block every WooCommerce scripts.', 'cookiebot' ); ?>
441
- <br>
442
- <?php esc_html_e( 'This feature works only for scripts loaded via wp_enqueue_script! Manually added scripts must be manually edited!', 'cookiebot' ); ?>
443
- </span>
444
- </td>
445
- </tr>
446
- </table>
447
- </div>
448
- <?php if ( $is_wp_consent_api_active ) { ?>
449
- <h3 id="consent_level_api_settings" class="cookiebot_fieldset_header">
450
- <?php
451
- esc_html_e(
452
- 'Consent Level API Settings',
453
- 'cookiebot'
454
- );
455
- ?>
456
- </h3>
457
- <div id="consent_level_api_settings" style="display:none;">
458
- <p>
459
- <?php
460
- esc_html_e(
461
- 'WP Consent Level API and Cookiebot categorise cookies a bit different. The default settings should fit mosts needs - but if you need to change the mapping you are able to do it below.',
462
- 'cookiebot'
463
- );
464
- ?>
465
- </p>
466
 
467
- <?php
468
- $consent_types = array( 'preferences', 'statistics', 'marketing' );
469
- $states = array_reduce(
470
- $consent_types,
471
- function ( $t, $v ) {
472
- $newt = array();
473
- if ( empty( $t ) ) {
474
- $newt = array(
475
- array( $v => true ),
476
- array( $v => false ),
477
- );
478
- } else {
479
- foreach ( $t as $item ) {
480
- $newt[] = array_merge( $item, array( $v => true ) );
481
- $newt[] = array_merge( $item, array( $v => false ) );
482
- }
483
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
484
 
485
- return $newt;
486
- },
487
- array()
488
- );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
489
 
490
- ?>
491
 
 
492
 
493
- <table class="widefat striped consent_mapping_table">
494
- <thead>
495
- <tr>
496
- <th><?php esc_html_e( 'Cookiebot categories', 'cookiebot' ); ?></th>
497
- <th class="consent_mapping"><?php esc_html_e( 'WP Consent Level categories', 'cookiebot' ); ?></th>
498
- </tr>
499
- </thead>
500
- <?php
501
- foreach ( $states as $state ) {
502
- $key = array();
503
- $key[] = 'n=1';
504
- $key[] = 'p=' . ( $state['preferences'] ? '1' : '0' );
505
- $key[] = 's=' . ( $state['statistics'] ? '1' : '0' );
506
- $key[] = 'm=' . ( $state['marketing'] ? '1' : '0' );
507
- $key = implode( ';', $key );
508
- ?>
509
- <tr>
510
- <td>
511
- <div class="cb_consent">
512
- <span class="forceconsent">
513
- <?php esc_html_e( 'Necessary', 'cookiebot' ); ?>
514
- </span>
515
- <span class="<?php echo( $state['preferences'] ? 'consent' : 'noconsent' ); ?>">
516
- <?php esc_html_e( 'Preferences', 'cookiebot' ); ?>
517
- </span>
518
- <span class="<?php echo( $state['statistics'] ? 'consent' : 'noconsent' ); ?>">
519
- <?php esc_html_e( 'Statistics', 'cookiebot' ); ?>
520
- </span>
521
- <span class="<?php echo( $state['marketing'] ? 'consent' : 'noconsent' ); ?>">
522
- <?php esc_html_e( 'Marketing', 'cookiebot' ); ?>
523
- </span>
524
- </div>
525
- </td>
526
- <td>
527
- <div class="consent_mapping">
528
- <label><input
529
- type="checkbox"
530
- name="cookiebot-consent-mapping[<?php echo esc_attr( $key ); ?>][functional]"
531
- data-default-value="1" value="1" checked disabled
532
- > <?php esc_html_e( 'Functional', 'cookiebot' ); ?> </label>
533
- <label><input
534
- type="checkbox"
535
- name="cookiebot-consent-mapping[<?php echo esc_attr( $key ); ?>][preferences]"
536
- data-default-value="<?php echo esc_attr( $m_default[ $key ]['preferences'] ); ?>"
537
- value="1"
538
  <?php
539
- if ( $m[ $key ]['preferences'] ) {
540
- echo 'checked';
541
- }
 
542
  ?>
543
- > <?php esc_html_e( 'Preferences', 'cookiebot' ); ?> </label>
544
- <label><input
545
- type="checkbox"
546
- name="cookiebot-consent-mapping[<?php echo esc_attr( $key ); ?>][statistics]"
547
- data-default-value="<?php echo esc_attr( $m_default[ $key ]['statistics'] ); ?>"
548
- value="1"
549
- <?php
550
- if ( $m[ $key ]['statistics'] ) {
551
- echo 'checked';
552
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
553
  ?>
554
- > <?php esc_html_e( 'Statistics', 'cookiebot' ); ?> </label>
555
- <label><input
556
- type="checkbox"
557
- name="cookiebot-consent-mapping[<?php echo esc_attr( $key ); ?>][statistics-anonymous]"
558
- data-default-value="<?php echo esc_attr( $m_default[ $key ]['statistics-anonymous'] ); ?>"
559
- value="1"
 
 
560
  <?php
561
- if ( $m[ $key ]['statistics-anonymous'] ) {
562
- echo 'checked';
563
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
564
  ?>
565
- > <?php esc_html_e( 'Statistics Anonymous', 'cookiebot' ); ?>
 
 
 
 
 
 
 
 
 
 
 
 
566
  </label>
567
- <label><input
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
568
  type="checkbox"
569
- name="cookiebot-consent-mapping[<?php echo esc_attr( $key ); ?>][marketing]"
570
- data-default-value="<?php echo esc_attr( $m_default[ $key ]['marketing'] ); ?>"
571
- value="1"
572
- <?php
573
- if ( $m[ $key ]['marketing'] ) {
574
- echo 'checked';
575
- }
576
- ?>
577
- > <?php esc_html_e( 'Marketing', 'cookiebot' ); ?></label>
578
  </div>
579
- </td>
580
- </tr>
581
- <?php
582
- }
583
- ?>
584
- <tfoot>
585
- <tr>
586
- <td colspan="2" style="text-align:right;">
587
- <button class="button" onclick="return resetConsentMapping();">
588
- <?php
589
- esc_html_e(
590
- 'Reset to default mapping',
591
- 'cookiebot'
592
- );
593
- ?>
594
- </button>
595
- </td>
596
- </tr>
597
- </tfoot>
598
- </table>
599
- </div>
600
- <?php } ?>
601
- <?php submit_button(); ?>
602
- </form>
603
  </div>
1
  <?php
2
+ use cybot\cookiebot\settings\templates\Header;
3
+ use cybot\cookiebot\settings\templates\Main_Tabs;
4
 
5
+ use cybot\cookiebot\settings\pages\Gtm_Page;
6
+ use cybot\cookiebot\settings\pages\Iab_Page;
7
+ use cybot\cookiebot\settings\pages\Multiple_Page;
8
 
9
  /**
10
  * @var string $cbid
22
  * @var string $cookie_blocking_mode
23
  * @var string $add_language_gif_url
24
  */
25
+
26
+ $header = new Header();
27
+ $main_tabs = new Main_Tabs();
28
+
29
+ // phpcs:ignore WordPress.Security.NonceVerification.Recommended
30
+ $active_tab = $_GET['tab'] ? $_GET['tab'] : false;
31
+
32
+ $header->display();
33
  ?>
34
+
35
+ <div class="cb-body">
36
+ <div class="cb-wrapper">
37
+ <?php $main_tabs->display( 'settings' ); ?>
38
+ <div class="cb-main__content">
39
+ <form method="post" action="options.php">
40
+ <?php settings_fields( 'cookiebot' ); ?>
41
+ <?php do_settings_sections( 'cookiebot' ); ?>
42
+ <div class="cb-settings__header">
43
+ <h1 class="cb-main__page_title"><?php esc_html_e( 'Settings', 'cookiebot' ); ?></h1>
44
+ <?php submit_button(); ?>
45
+ </div>
46
+
47
+ <div class="cb-settings__tabs">
48
+ <div class="cb-settings__tabs__item <?php echo ! $active_tab || $active_tab === 'general-settings' ? 'active-item' : ''; ?>" data-tab="general-settings">
49
+ <?php esc_html_e( 'General Settings', 'cookiebot' ); ?>
50
+ </div>
51
+ <div class="cb-settings__tabs__item <?php echo $active_tab === 'additional-settings' ? 'active-item' : ''; ?>" data-tab="additional-settings">
52
+ <?php esc_html_e( 'Additional Settings', 'cookiebot' ); ?>
53
+ </div>
54
+ <div class="cb-settings__tabs__item <?php echo $active_tab === 'tag-manager' ? 'active-item' : ''; ?>" data-tab="tag-manager">
55
+ <?php esc_html_e( 'Google Tag Manager', 'cookiebot' ); ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
56
  </div>
57
+ <div class="cb-settings__tabs__item <?php echo $active_tab === 'consent-mode' ? 'active-item' : ''; ?>" data-tab="consent-mode">
58
+ <?php esc_html_e( 'Google Consent Mode', 'cookiebot' ); ?>
59
+ </div>
60
+ <div class="cb-settings__tabs__item <?php echo $active_tab === 'iab' ? 'active-item' : ''; ?>" data-tab="iab">
61
+ <?php esc_html_e( 'IAB', 'cookiebot' ); ?>
62
+ </div>
63
+ <div class="cb-settings__tabs__item <?php echo $active_tab === 'multiple-configurations' ? 'active-item' : ''; ?>" data-tab="multiple-configurations">
64
+ <?php esc_html_e( 'Multiple Configurations', 'cookiebot' ); ?>
65
+ </div>
66
+ </div>
67
+
68
+ <div class="cb-settings__tabs__content">
69
+ <div class="cb-settings__tabs__content--item <?php echo ! $active_tab || $active_tab === 'general-settings' ? 'active-item' : ''; ?>" id="general-settings">
70
+ <?php if ( ! $cbid ) : ?>
71
+ <div class="cb-general__new__account">
72
+ <h2 class="cb-general__info__title"><?php esc_html_e( 'Do you not have an account yet?', 'cookiebot' ); ?></h2>
73
+ <p class="cb-general__info__text">
74
+ <?php esc_html_e( 'Before you can get started with Cookiebot CMP for WordPress, you need to create an account on our website by clicking on "Create a new account" below. After you have signed up, you can configure your banner in the Cookiebot Manager and then place the Cookiebot Domain Group ID in the designated field below. You can find your ID in the Cookiebot Manager by navigating to "Settings" and "Your Scripts".', 'cookiebot' ); ?>
75
+ </p>
76
+ <div class="new-account-actions">
77
+ <a href="https://manage.cookiebot.com/en/signup/?utm_source=wordpress&utm_medium=organic&utm_campaign=banner" target="_blank" class="cb-btn cb-main-btn"><?php esc_html_e( 'Create a new Account', 'cookiebot' ); ?></a>
78
+ <a href="https://support.cookiebot.com/hc/en-us/articles/360003784174-Installing-Cookiebot-CMP-on-WordPress" class="cb-btn cb-link-btn"><?php esc_html_e( 'Get help with connecting your account', 'cookiebot' ); ?></a>
79
+ </div>
80
  </div>
81
+ <?php endif; ?>
82
+
83
+ <div class="cb-settings__config__item">
84
+ <div class="cb-settings__config__content">
85
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Connect your Domain Group:', 'cookiebot' ); ?></h3>
86
+ <p class="cb-general__info__text">
87
+ <?php esc_html_e( 'To connect your Domain Group, paste your Domain Group ID here. If you want to connect a second ID for other regions, you can do this under the "Multiple Configurations" tab.', 'cookiebot' ); ?>
88
+ </p>
89
+ <a href="https://support.cookiebot.com/hc/en-us/articles/4405643234194-Your-CBID-or-Domain-group-ID-and-where-to-find-it" target="_blank" class="cb-btn cb-link-btn"><?php esc_html_e( 'Read more on the Domain Group ID', 'cookiebot' ); ?></a>
90
+ </div>
91
+ <div class="cb-settings__config__data">
92
+ <div class="cb-settings__config__data__inner">
93
+ <h3 class="cb-settings__data__subtitle"><?php esc_html_e( 'Add your Domain Group ID', 'cookiebot' ); ?></h3>
94
+ <input <?php echo ( $is_ms ) ? ' placeholder="' . esc_attr( $network_cbid ) . '"' : ''; ?>
95
+ type="text" name="cookiebot-cbid"
96
+ value="<?php echo esc_attr( $cbid ); ?>"
97
+ />
98
+ </div>
99
+ </div>
 
 
 
 
100
  </div>
 
101
 
102
+ <div class="cb-settings__config__item">
103
+ <div class="cb-settings__config__content">
104
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Language:', 'cookiebot' ); ?></h3>
105
+ <p class="cb-general__info__text">
106
+ <?php esc_html_e( 'Select your main language here. Please make sure that the language selected has also been added in the Cookiebot Manager.', 'cookiebot' ); ?>
107
+ </p>
108
+ <a href="https://support.cookiebot.com/hc/en-us/articles/360003793394-How-to-set-the-language-of-the-consent-banner-" target="_blank" class="cb-btn cb-link-btn"><?php esc_html_e( 'Read more on how to add languages', 'cookiebot' ); ?></a>
109
+ </div>
110
+ <div class="cb-settings__config__data">
111
+ <div class="cb-settings__config__data__inner">
112
+ <h3 class="cb-settings__data__subtitle"><?php esc_html_e( 'Select the language', 'cookiebot' ); ?></h3>
113
+ <select name="cookiebot-language" id="cookiebot-language">
114
+ <option value=""><?php esc_html_e( 'Default (Autodetect)', 'cookiebot' ); ?></option>
115
+ <option value="_wp"<?php echo ( $current_lang === '_wp' ) ? ' selected' : ''; ?>>
116
+ <?php
117
+ esc_html_e(
118
+ 'Use WordPress Language',
119
+ 'cookiebot'
120
+ );
121
+ ?>
122
+ </option>
123
+ <?php
124
+ foreach ( $supported_languages as $lang_code => $lang_name ) {
125
+ echo '<option value="' . esc_attr( $lang_code ) . '"' . ( ( $current_lang === esc_attr( $lang_code ) ) ? ' selected' : '' ) . '>' . esc_html( $lang_name ) . '</option>';
126
+ }
127
+ ?>
128
+ </select>
129
+ </div>
130
+ </div>
131
+ </div>
132
 
133
+ <div class="cb-settings__config__item">
134
+ <div class="cb-settings__config__content">
135
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Cookie-blocking mode', 'cookiebot' ); ?></h3>
136
+ <p class="cb-general__info__text">
137
+ <?php esc_html_e( 'Select your cookie-blocking mode here. Auto cookie-blocking mode will automatically block all cookies (except for ‘strictly necessary’ cookies) until a user has given consent. Manual cookie-blocking mode requests manual adjustments to the cookie-setting scripts. Please find our implementation guides below:', 'cookiebot' ); ?>
138
+ </p>
139
+ <a href="https://support.cookiebot.com/hc/en-us/articles/360009063100-How-does-Automatic-Cookie-Blocking-work-" target="_blank" class="cb-btn cb-link-btn"><?php esc_html_e( 'Guide to auto cookie-blocking', 'cookiebot' ); ?></a>
140
+ <a href="https://support.cookiebot.com/hc/en-us/articles/4405978132242-Manual-cookie-blocking" target="_blank" class="cb-btn cb-link-btn"><?php esc_html_e( 'Guide to manual cookie-blocking', 'cookiebot' ); ?></a>
141
+ </div>
142
+ <div class="cb-settings__config__data">
143
+ <div class="cb-settings__config__data__inner">
144
+ <h3 class="cb-settings__data__subtitle"><?php esc_html_e( 'Select the cookie-blocking mode', 'cookiebot' ); ?></h3>
145
+ <label class="recommended-item">
146
+ <input <?php checked( 'auto', $cookie_blocking_mode ); ?>
147
+ type="radio"
148
+ name="cookiebot-cookie-blocking-mode"
149
+ value="auto"
150
+ />
151
+ <?php esc_html_e( 'Automatic cookie-blocking mode', 'cookiebot' ); ?>
152
+ </label>
153
+ <label>
154
+ <input <?php checked( 'manual', $cookie_blocking_mode ); ?>
155
+ type="radio"
156
+ name="cookiebot-cookie-blocking-mode"
157
+ value="manual"
158
+ />
159
+ <?php esc_html_e( 'Manual cookie-blocking mode', 'cookiebot' ); ?>
160
+ </label>
161
+ </div>
162
+ </div>
163
  </div>
164
+
 
 
 
 
 
 
 
 
 
 
 
 
 
165
  <?php
166
  $cv = get_option( 'cookiebot-script-tag-uc-attribute', 'async' );
167
  $disabled = false;
170
  $cv = $network_scrip_tag_uc_attr;
171
  }
172
  ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
173
 
174
+ <div class="cb-settings__config__item secondary__item" id="declaration-tag">
175
+ <div class="cb-settings__config__content">
176
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Cookiebot script tag', 'cookiebot' ); ?></h3>
177
+ <p class="cb-general__info__note">
178
+ <?php esc_html_e( 'Depending on cookie-blocking mode', 'cookiebot' ); ?>
179
+ </p>
180
+ <p class="cb-general__info__text">
181
+ <?php esc_html_e( 'Add async or defer attribute to cookie declaration script tag', 'cookiebot' ); ?>
182
+ </p>
183
+ </div>
184
+ <div class="cb-settings__config__data">
185
+ <div class="cb-settings__config__data__inner">
186
+ <label>
187
+ <input
188
+ type="radio"
189
+ name="cookiebot-script-tag-uc-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
190
+ value="" <?php checked( '', $cv ); ?> />
191
+ <?php esc_html_e( 'None', 'cookiebot' ); ?>
192
+ </label>
193
+ <label>
194
+ <input
195
+ type="radio"
196
+ name="cookiebot-script-tag-uc-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
197
+ value="async" <?php checked( 'async', $cv ); ?> />
198
+ async
199
+ </label>
200
+ <label>
201
+ <input
202
+ type="radio"
203
+ name="cookiebot-script-tag-uc-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
204
+ value="defer" <?php checked( 'defer', $cv ); ?> />
205
+ defer
206
+ </label>
207
+ </div>
208
+ </div>
209
+ </div>
210
 
211
+ <div class="cb-settings__config__item secondary__item" id="cookie-popup">
212
+ <div class="cb-settings__config__content">
213
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Hide cookie popup', 'cookiebot' ); ?></h3>
214
+ <p class="cb-general__info__note">
215
+ <?php esc_html_e( 'Depending on cookie-blocking mode', 'cookiebot' ); ?>
216
+ </p>
217
+ <p class="cb-general__info__text">
218
+ <?php esc_html_e( 'This checkbox will remove the cookie consent banner from your website. The declaration shortcode will still be available. If you are using Google Tag Manager (or equal), you need to add the Cookiebot script in your Tag Manager.', 'cookiebot' ); ?>
219
+ </p>
220
+ </div>
221
+ <div class="cb-settings__config__data">
222
+ <div class="cb-settings__config__data__inner">
223
+ <label>
224
+ <?php
225
+ $disabled = false;
226
+ if ( $is_ms && get_site_option( 'cookiebot-nooutput' ) ) {
227
+ $disabled = true;
228
+ echo '<input type="checkbox" checked disabled />';
229
+ } else {
230
+ ?>
231
+ <input type="checkbox" name="cookiebot-nooutput" value="1"
232
+ <?php
233
+ checked(
234
+ 1,
235
+ get_option( 'cookiebot-nooutput', false )
236
+ );
237
+ ?>
238
+ />
239
+ <?php } ?>
240
+ <?php esc_html_e( 'Hide the cookie popup banner', 'cookiebot' ); ?>
241
+ </label>
242
+ </div>
243
+ </div>
244
+ </div>
245
 
246
+ </div>
247
 
248
+ <div class="cb-settings__tabs__content--item <?php echo $active_tab === 'additional-settings' ? 'active-item' : ''; ?>" id="additional-settings">
249
 
250
+ <div class="cb-settings__config__item">
251
+ <div class="cb-settings__config__content">
252
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Auto-update Cookiebot Plugin:', 'cookiebot' ); ?></h3>
253
+ <p class="cb-general__info__text">
254
+ <?php esc_html_e( 'Automatically update your Cookiebot plugin when new releases becomes available.', 'cookiebot' ); ?>
255
+ </p>
256
+ </div>
257
+ <div class="cb-settings__config__data">
258
+ <div class="cb-settings__config__data__inner">
259
+ <label class="switch-checkbox" for="cookiebot-autoupdate">
260
+ <input id="cookiebot-autoupdate" type="checkbox" name="cookiebot-autoupdate" value="1"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
261
  <?php
262
+ checked(
263
+ 1,
264
+ get_option( 'cookiebot-autoupdate', false )
265
+ );
266
  ?>
267
+ />
268
+ <div class="switcher"></div>
269
+ <?php esc_html_e( 'Automatically update Cookiebot Plugin', 'cookiebot' ); ?>
270
+ </label>
271
+ </div>
272
+ </div>
273
+ </div>
274
+
275
+ <div class="cb-settings__config__item">
276
+ <div class="cb-settings__config__content">
277
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Cookiebot CMP in WP Admin:', 'cookiebot' ); ?></h3>
278
+ <p class="cb-general__info__text">
279
+ <?php esc_html_e( 'This checkbox will disable Cookiebot CMP to act within the WordPress Admin area', 'cookiebot' ); ?>
280
+ </p>
281
+ </div>
282
+ <div class="cb-settings__config__data">
283
+ <div class="cb-settings__config__data__inner">
284
+ <label class="switch-checkbox" for="cookiebot-nooutput-admin">
285
+ <?php
286
+ $disabled = false;
287
+ if ( $is_ms && get_site_option( 'cookiebot-nooutput-admin' ) ) {
288
+ echo '<input type="checkbox" checked disabled />';
289
+ $disabled = true;
290
+ } else {
291
  ?>
292
+ <input id="cookiebot-nooutput-admin" type="checkbox" name="cookiebot-nooutput-admin" value="1"
293
+ <?php
294
+ checked(
295
+ 1,
296
+ get_option( 'cookiebot-nooutput-admin', false )
297
+ );
298
+ ?>
299
+ />
300
  <?php
301
+ }
302
+ ?>
303
+ <div class="switcher"></div>
304
+ <?php esc_html_e( 'Disable Cookiebot CMP in the WordPress Admin area', 'cookiebot' ); ?>
305
+ </label>
306
+ </div>
307
+ </div>
308
+ </div>
309
+
310
+ <div class="cb-settings__config__item">
311
+ <div class="cb-settings__config__content">
312
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Cookiebot CMP on front-end while logged in:', 'cookiebot' ); ?></h3>
313
+ <p class="cb-general__info__text">
314
+ <?php esc_html_e( 'This setting will enable Cookiebot CMP on the front-end while you\'re logged in.', 'cookiebot' ); ?>
315
+ </p>
316
+ </div>
317
+ <div class="cb-settings__config__data">
318
+ <div class="cb-settings__config__data__inner">
319
+ <label class="switch-checkbox" for="cookiebot-output-logged-in">
320
+ <?php
321
+ $disabled = false;
322
+ if ( $is_ms && get_site_option( 'cookiebot-output-logged-in' ) ) {
323
+ echo '<input type="checkbox" checked disabled />';
324
+ $disabled = true;
325
+ } else {
326
  ?>
327
+ <input id="cookiebot-output-logged-in" type="checkbox" name="cookiebot-output-logged-in" value="1"
328
+ <?php
329
+ checked(
330
+ 1,
331
+ get_option( 'cookiebot-output-logged-in', false )
332
+ );
333
+ ?>
334
+ />
335
+ <?php
336
+ }
337
+ ?>
338
+ <div class="switcher"></div>
339
+ <?php esc_html_e( 'Render Cookiebot CMP on front-end while logged in', 'cookiebot' ); ?>
340
  </label>
341
+ </div>
342
+ </div>
343
+ </div>
344
+
345
+ <div class="cb-settings__config__item">
346
+ <div class="cb-settings__config__content">
347
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Cookie declaration script tag:', 'cookiebot' ); ?></h3>
348
+ <p class="cb-general__info__text">
349
+ <?php esc_html_e( 'If you implemented the declaration on your page through our widget in WordPress, you can choose here how the script should be loaded.', 'cookiebot' ); ?>
350
+ </p>
351
+ </div>
352
+ <div class="cb-settings__config__data">
353
+ <div class="cb-settings__config__data__inner">
354
+ <h3 class="cb-settings__data__subtitle"><?php esc_html_e( 'Select the cookie declaration script loading setting', 'cookiebot' ); ?></h3>
355
+ <?php
356
+ $cv = get_option( 'cookiebot-script-tag-cd-attribute', 'async' );
357
+ $disabled = false;
358
+ if ( $is_ms && $network_scrip_tag_cd_attr !== 'custom' ) {
359
+ $disabled = true;
360
+ $cv = $network_scrip_tag_cd_attr;
361
+ }
362
+ ?>
363
+ <label>
364
+ <input
365
+ type="radio"
366
+ name="cookiebot-script-tag-cd-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
367
+ value="" <?php checked( '', $cv ); ?>/>
368
+ <?php esc_html_e( 'None', 'cookiebot' ); ?>
369
+ </label>
370
+ <label>
371
+ <input
372
+ type="radio"
373
+ name="cookiebot-script-tag-cd-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
374
+ value="async" <?php checked( 'async', $cv ); ?>/>
375
+ async
376
+ </label>
377
+ <label>
378
+ <input
379
+ type="radio"
380
+ name="cookiebot-script-tag-cd-attribute"<?php echo ( $disabled ) ? ' disabled' : ''; ?>
381
+ value="defer" <?php checked( 'defer', $cv ); ?>/>
382
+ defer
383
+ </label>
384
+ </div>
385
+ </div>
386
+ </div>
387
+
388
+ <div class="cb-settings__config__item">
389
+ <div class="cb-settings__config__content">
390
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Ignore scripts in queue from Cookiebot CMP scan:', 'cookiebot' ); ?></h3>
391
+ <p class="cb-general__info__text">
392
+ <?php esc_html_e( 'List scripts source URL (one per line) from the queue to ignore Cookiebot CMP scan. Partial source URL will also work, e.g. wp-content/plugins/woocommerce will block every WooCommerce script.', 'cookiebot' ); ?>
393
+ </p>
394
+ <p class="cb-general__info__text">
395
+ <?php esc_html_e( 'This feature only works for scripts loaded via wp_enqueue_script. Manually added scripts must be manually edited.', 'cookiebot' ); ?>
396
+ </p>
397
+ </div>
398
+ <div class="cb-settings__config__data">
399
+ <div class="cb-settings__config__data__inner">
400
+ <h3 class="cb-settings__data__subtitle"><?php esc_html_e( 'Script source URL:', 'cookiebot' ); ?></h3>
401
+ <textarea
402
+ name="cookiebot-ignore-scripts"
403
+ rows="4"
404
+ cols="50"
405
+ placeholder="<?php esc_attr_e( 'Add script source URL, one per line', 'cookiebot' ); ?>"
406
+ ><?php echo esc_html( get_option( 'cookiebot-ignore-scripts', false ) ); ?></textarea>
407
+ </div>
408
+ </div>
409
+ </div>
410
+
411
+ </div>
412
+
413
+ <div class="cb-settings__tabs__content--item <?php echo $active_tab === 'tag-manager' ? 'active-item' : ''; ?>" id="tag-manager">
414
+ <?php $gtm_settings = new Gtm_Page(); ?>
415
+ <?php $gtm_settings->display(); ?>
416
+ </div>
417
+
418
+ <div class="cb-settings__tabs__content--item <?php echo $active_tab === 'consent-mode' ? 'active-item' : ''; ?>" id="consent-mode">
419
+ <div class="cb-general__consent__mode">
420
+ <h2 class="cb-general__info__title"><?php esc_html_e( 'What is Google Consent Mode and why should you enable it?', 'cookiebot' ); ?></h2>
421
+ <p class="cb-general__info__text">
422
+ <?php esc_html_e( 'Google Consent Mode is a way for your website to measure conversions and get analytics insights while being fully GDPR-compliant when using services like Google Analytics, Google Tag Manager (GTM) and Google Ads.', 'cookiebot' ); ?>
423
+ </p>
424
+ <p class="cb-general__info__text">
425
+ <?php esc_html_e( 'Cookiebot consent managment platform (CMP) and Google Consent Mode integrate seamlessly to offer you plug-and-play compliance and streamlined use of all Google\'s services in one easy solution.', 'cookiebot' ); ?>
426
+ </p>
427
+ <a class="cb-btn cb-link-btn" target="_blank" href="https://support.cookiebot.com/hc/en-us/articles/360016047000-Cookiebot-and-Google-Consent-Mode"><?php esc_html_e( 'Read more about Cookiebot CMP and Google Consent Mode', 'cookiebot' ); ?></a>
428
+ </div>
429
+
430
+ <div class="cb-settings__config__item">
431
+ <div class="cb-settings__config__content">
432
+ <h3 class="cb-settings__config__subtitle"><?php esc_html_e( 'Google Consent Mode:', 'cookiebot' ); ?></h3>
433
+ <p class="cb-general__info__text">
434
+ <?php esc_html_e( 'Enable Google Consent Mode with default settings on your WordPress page.', 'cookiebot' ); ?>
435
+ </p>
436
+ <a class="cb-btn cb-link-btn" target="_blank" href="https://support.cookiebot.com/hc/en-us/articles/360016047000-Cookiebot-and-Google-Consent-Mode"><?php esc_html_e( 'Read more', 'cookiebot' ); ?></a>
437
+ </div>
438
+ <div class="cb-settings__config__data">
439
+ <div class="cb-settings__config__data__inner">
440
+ <label class="switch-checkbox" for="gcm">
441
+ <input
442
  type="checkbox"
443
+ name="cookiebot-gcm"
444
+ id="gcm"
445
+ value="1" <?php checked( 1, get_option( 'cookiebot-gcm' ) ); ?>>
446
+ <div class="switcher"></div>
447
+ <?php esc_html_e( 'Google Consent Mode', 'cookiebot' ); ?>
448
+ </label>
449
+ <input type="hidden" name="cookiebot-gcm-first-run" value="1">
 
 
450
  </div>
451
+ </div>
452
+ </div>
453
+
454
+
455
+ </div>
456
+
457
+ <div class="cb-settings__tabs__content--item <?php echo $active_tab === 'iab' ? 'active-item' : ''; ?>" id="iab">
458
+ <?php $iab_settings = new Iab_Page(); ?>
459
+ <?php $iab_settings->display(); ?>
460
+ </div>
461
+
462
+ <div class="cb-settings__tabs__content--item <?php echo $active_tab === 'multiple-configurations' ? 'active-item' : ''; ?>" id="multiple-configurations">
463
+ <?php $multiple_settings = new Multiple_Page(); ?>
464
+ <?php $multiple_settings->display(); ?>
465
+ </div>
466
+
467
+ </div>
468
+ </form>
469
+ </div>
470
+ </div>
 
 
 
 
471
  </div>
src/view/admin/settings/support-page.php CHANGED
@@ -1,135 +1,215 @@
1
- <div class="wrap">
2
- <h1><?php esc_html_e( 'Support', 'cookiebot' ); ?></h1>
3
- <h2><?php esc_html_e( 'How to find my Cookiebot ID', 'cookiebot' ); ?></h2>
4
- <div>
5
- <ol>
6
- <li>
7
- <?php
8
- echo sprintf(
9
- // translators: the first placeholder string will be replaced with a html anchor open tag and the second placeholder string will be replaced by the html anchor closing tag
10
- esc_html__( 'Log in to your %1$sCookiebot account%2$s.', 'cookiebot' ),
11
- '<a href="https://www.cookiebot.com/goto/account" target="_blank">',
12
- '</a>'
13
- );
14
- ?>
15
- </li>
16
- <li>
17
- <?php
18
- echo sprintf(
19
- // translators: the placeholder strings denote the positions of <b>, </b>, <b> and </b> HTML tags
20
- esc_html__( 'Go to %1$sManage%2$s > %3$sSettings%4$s and add setup your Cookiebot', 'cookiebot' ),
21
- '<b>',
22
- '</b>',
23
- '<b>',
24
- '</b>'
25
- );
26
- ?>
27
- </li>
28
- <li>
29
- <?php
30
- echo sprintf(
31
- // translators: the placeholder strings denote the positions of <b> and </b> HTML tags
32
- esc_html__( 'Go to the %1$s"Your scripts"%2$s tab', 'cookiebot' ),
33
- '<b>',
34
- '</b>'
35
- );
36
- ?>
37
- </li>
38
- <li><?php esc_html_e( 'Copy the value inside the data-cid parameter - eg.: abcdef12-3456-7890-abcd-ef1234567890', 'cookiebot' ); ?></li>
39
- <li>
40
- <?php
41
- echo sprintf(
42
- // translators: the placeholder strings denote the positions of <b> and </b> HTML tags
43
- esc_html__( 'Add %1$s[cookie_declaration]%2$s shortcode to a page to show the declation', 'cookiebot' ),
44
- '<b>',
45
- '</b>'
46
- );
47
- ?>
48
- </li>
49
- <li><?php esc_html_e( 'Remember to change your scripts as descripted below', 'cookiebot' ); ?></li>
50
- </ol>
51
- </div>
52
- <h2><?php esc_html_e( 'Add the Cookie Declaration to your website', 'cookiebot' ); ?></h2>
53
- <p>
54
- <?php
55
- echo sprintf(
56
- // translators: the placeholder strings denote the positions of <b> and </b> HTML tags
57
- esc_html__( 'Use the shortcode %1$s[cookie_declaration]%2$s to add the cookie declaration a page or post. The cookie declaration will always show the latest version from Cookiebot.', 'cookiebot' ),
58
- '<b>',
59
- '</b>'
60
- );
61
- ?>
62
- <br/>
63
- <?php
64
- echo sprintf(
65
- // translators: the placeholder strings denote the positions of <i>, </i>, <b> and </b> HTML tags
66
- esc_html__( 'If you need to force language of the cookie declaration, you can add the %1$slang%2$s attribute. Eg. %3$s[cookie_declaration lang="de"]%4$s.', 'cookiebot' ),
67
- '<i>',
68
- '</i>',
69
- '<b>',
70
- '</b>'
71
- );
72
- ?>
73
- </p>
74
- <p>
75
- <a href="https://www.youtube.com/watch?v=OCXz2bt4H_w" target="_blank" class="button">
76
- <?php
77
- esc_html_e(
78
- 'Watch video demonstration',
79
- 'cookiebot'
80
- );
81
- ?>
82
- </a>
83
- </p>
84
- <h2><?php esc_html_e( 'Update your script tags', 'cookiebot' ); ?></h2>
85
- <p>
86
- <?php
87
- esc_html_e(
88
- 'To enable prior consent, apply the attribute "data-cookieconsent" to cookie-setting script tags on your website. Set the comma-separated value to one or more of the cookie categories "preferences", "statistics" and "marketing" in accordance with the types of cookies being set by each script. Finally change the attribute "type" from "text/javascript" to "text/plain". Example on modifying an existing Google Analytics Universal script tag.',
89
- 'cookiebot'
90
- );
91
- ?>
92
- </p>
93
- <code>
94
- <?php
95
- $output = <<<HTML
96
- <script type="text/plain" data-cookieconsent="statistics">
97
- (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
98
- ga('create', 'UA-00000000-0', 'auto');
99
- ga('send', 'pageview');
100
- </script>
101
- HTML;
102
- echo nl2br( esc_html( $output ) );
103
- ?>
104
- </code>
105
- <p>
106
- <a href="https://www.youtube.com/watch?v=MeHycvV2QCQ" target="_blank" class="button">
107
- <?php
108
- esc_html_e(
109
- 'Watch video demonstration',
110
- 'cookiebot'
111
- );
112
- ?>
113
- </a>
114
- </p>
115
 
116
- <h2><?php esc_html_e( 'Helper function to update your scripts', 'cookiebot' ); ?></h2>
117
- <p>
118
- <?php
119
- esc_html_e(
120
- 'You are able to update your scripts yourself. However, Cookiebot also offers a small helper function that makes the work easier.',
121
- 'cookiebot'
122
- );
123
- ?>
124
- <br/>
125
- <?php esc_html_e( 'Update your script tags this way:', 'cookiebot' ); ?>
126
- </p>
127
- <?php
128
- printf(
129
- // translators: %1$s refers to the original script tag HTML, and %2$s refers to its replacement
130
- esc_html__( '%1$s to %2$s', 'cookiebot' ),
131
- '<code>' . esc_html( '<script type="text/javascript">' ) . '</code>',
132
- '<code>' . esc_html( '<script<?php echo cookiebot_assist(\'marketing\') ?>>' ) . '</code>'
133
- );
134
- ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
135
  </div>
1
+ <?php
2
+ /**
3
+ * @var string $debug_output
4
+ */
5
+
6
+ use cybot\cookiebot\settings\templates\Header;
7
+ use cybot\cookiebot\settings\templates\Main_Tabs;
8
+
9
+ $header = new Header();
10
+ $main_tabs = new Main_Tabs();
11
+
12
+ $header->display();
13
+ ?>
14
+ <div class="cb-body">
15
+ <div class="cb-wrapper">
16
+ <?php $main_tabs->display( 'support' ); ?>
17
+ <div class="cb-main__content">
18
+ <h1 class="cb-main__page_title"><?php esc_html_e( 'Support', 'cookiebot' ); ?></h1>
19
+
20
+ <div class="cb-support__content">
21
+ <div class="cb-support__info__card">
22
+ <h2 class="cb-support__info__title"><?php esc_html_e( 'Need help with your configuration?', 'cookiebot' ); ?></h2>
23
+ <p class="cb-support__info__text">
24
+ <?php
25
+ esc_html_e(
26
+ 'In our Help Center you find all the answers to your questions. If you have additional questions, create a support request and our Support Team will help out as soon as possible.',
27
+ 'cookiebot'
28
+ );
29
+ ?>
30
+ </p>
31
+ <a href="https://support.cookiebot.com/hc/en-us" target="_blank" class="cb-btn cb-main-btn">
32
+ <?php
33
+ esc_html_e(
34
+ 'Visit Cookiebot CMP Help Center',
35
+ 'cookiebot'
36
+ );
37
+ ?>
38
+ </a>
39
+ </div>
40
+ <div class="cb-support__video__card">
41
+ <div class="cb-support__video__inner">
42
+ <h2 class="cb-support__video__title"><?php esc_html_e( 'Video guide', 'cookiebot' ); ?></h2>
43
+ <div class="cb-main__video">
44
+ <iframe src="https://www.youtube.com/embed/eSVFnjoMKFk" title="Cookiebot WordPress Installation" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
45
+ </div>
46
+ </div>
47
+
48
+ </div>
49
+ </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
50
 
51
+ <div class="cb-faqs">
52
+ <h2 class="cb-support__info__title">FAQ:</h2>
53
+ <div class="cb-faq__container cb-faq--opened">
54
+ <h3 class="cb-faq__question"><?php esc_html_e( 'How to find my Cookiebot ID', 'cookiebot' ); ?><span class="cb-faq__toggle"></span></h3>
55
+ <div class="cb-faq__answer">
56
+ <p class="cb-faq__answer__content">
57
+ <ol>
58
+ <li>
59
+ <?php
60
+ echo sprintf(
61
+ // translators: the first placeholder string will be replaced with a html anchor open tag and the second placeholder string will be replaced by the html anchor closing tag
62
+ esc_html__( 'Log in to your %1$sCookiebot CMP account%2$s.', 'cookiebot' ),
63
+ '<a href="https://www.cookiebot.com/goto/account" target="_blank">',
64
+ '</a>'
65
+ );
66
+ ?>
67
+ </li>
68
+ <li>
69
+ <?php
70
+ echo sprintf(
71
+ // translators: the placeholder strings denote the positions of <b>, </b>, <b> and </b> HTML tags
72
+ esc_html__( 'Go to %1$s"Settings"%2$s and setup your Cookiebot CMP', 'cookiebot' ),
73
+ '<b>',
74
+ '</b>'
75
+ );
76
+ ?>
77
+ </li>
78
+ <li>
79
+ <?php
80
+ echo sprintf(
81
+ // translators: the placeholder strings denote the positions of <b> and </b> HTML tags
82
+ esc_html__( 'Go to the %1$s"Your scripts"%2$s tab', 'cookiebot' ),
83
+ '<b>',
84
+ '</b>'
85
+ );
86
+ ?>
87
+ </li>
88
+ <li><?php esc_html_e( 'Copy the value inside the data-cid parameter - eg.: abcdef12-3456-7890-abcd-ef1234567890', 'cookiebot' ); ?></li>
89
+ <li>
90
+ <?php
91
+ echo sprintf(
92
+ // translators: the placeholder strings denote the positions of <b> and </b> HTML tags
93
+ esc_html__( 'Add %1$s[cookie_declaration]%2$s shortcode to a page to show the declaration', 'cookiebot' ),
94
+ '<b>',
95
+ '</b>'
96
+ );
97
+ ?>
98
+ </li>
99
+ <li><?php esc_html_e( 'Remember to change your scripts as described below', 'cookiebot' ); ?></li>
100
+ </ol>
101
+ </p>
102
+ </div>
103
+ </div>
104
+
105
+ <div class="cb-faq__container">
106
+ <h3 class="cb-faq__question"><?php esc_html_e( 'Add the Cookie Declaration to your website', 'cookiebot' ); ?><span class="cb-faq__toggle"></span></h3>
107
+ <div class="cb-faq__answer">
108
+ <p class="cb-faq__answer__content">
109
+ <?php
110
+ echo sprintf(
111
+ // translators: the placeholder strings denote the positions of <b> and </b> HTML tags
112
+ esc_html__( 'Use the shortcode %1$s[cookie_declaration]%2$s to add the cookie declaration to a page or post. The cookie declaration will always show the latest version from Cookiebot CMP.', 'cookiebot' ),
113
+ '<b>',
114
+ '</b>'
115
+ );
116
+ ?>
117
+ </p>
118
+ <p class="cb-faq__answer__content">
119
+ <?php
120
+ echo sprintf(
121
+ // translators: the placeholder strings denote the positions of <i>, </i>, <b> and </b> HTML tags
122
+ esc_html__( 'If you want to show the cookie declaration in a specific language, you can add the %1$s"lang"%2$s attribute, e.g. %3$s[cookie_declaration lang="de"]%4$s.', 'cookiebot' ),
123
+ '<i>',
124
+ '</i>',
125
+ '<b>',
126
+ '</b>'
127
+ );
128
+ ?>
129
+ </p>
130
+ <p class="cb-faq__answer__content">
131
+ <a href="https://www.youtube.com/watch?v=OCXz2bt4H_w" target="_blank" class="cb-btn cb-main-btn">
132
+ <?php
133
+ esc_html_e(
134
+ 'Watch video demonstration',
135
+ 'cookiebot'
136
+ );
137
+ ?>
138
+ </a>
139
+ </p>
140
+ </div>
141
+ </div>
142
+
143
+ <div class="cb-faq__container">
144
+ <h3 class="cb-faq__question"><?php esc_html_e( 'Update your script tags', 'cookiebot' ); ?><span class="cb-faq__toggle"></span></h3>
145
+ <div class="cb-faq__answer">
146
+ <p class="cb-faq__answer__content">
147
+ <?php
148
+ esc_html_e(
149
+ 'To enable prior consent, apply the attribute "data-cookieconsent" to cookie-setting script tags on your website. Set the comma-separated value to one or more of the cookie categories "preferences", "statistics" and/or "marketing" in accordance with the types of cookies being set by each script. Finally, change the attribute "type" from "text/javascript" to "text/plain".',
150
+ 'cookiebot'
151
+ );
152
+ ?>
153
+ </p>
154
+ <p class="cb-faq__answer__content">
155
+ <?php
156
+ echo sprintf(
157
+ // translators: the placeholder strings denote the positions of <i>, </i>, <b> and </b> HTML tags
158
+ esc_html__( 'Example on modifying an existing Google Analytics Universal script tag can be found %1$shere in step 4%2$s.', 'cookiebot' ),
159
+ '<a href="https://www.cookiebot.com/en/manual-implementation/" target="_blank">',
160
+ '</a>'
161
+ );
162
+ ?>
163
+ </p>
164
+ <code class="cb-faq__code">
165
+ <?php
166
+ $output = "<script type=\"text/plain\" data-cookieconsent=\"statistics\">
167
+ (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
168
+ ga('create', 'UA-00000000-0', 'auto');
169
+ ga('send', 'pageview');
170
+ </script>";
171
+ echo nl2br( esc_html( $output ) );
172
+ ?>
173
+ </code>
174
+ <p class="cb-faq__answer__content">
175
+ <a href="https://www.youtube.com/watch?v=MeHycvV2QCQ" target="_blank" class="cb-btn cb-main-btn">
176
+ <?php
177
+ esc_html_e(
178
+ 'Watch video demonstration',
179
+ 'cookiebot'
180
+ );
181
+ ?>
182
+ </a>
183
+ </p>
184
+ </div>
185
+ </div>
186
+
187
+ <div class="cb-faq__container">
188
+ <h3 class="cb-faq__question"><?php esc_html_e( 'Helper function to update your scripts', 'cookiebot' ); ?><span class="cb-faq__toggle"></span></h3>
189
+ <div class="cb-faq__answer">
190
+ <p class="cb-faq__answer__content">
191
+ <?php
192
+ esc_html_e(
193
+ 'You can update your scripts yourself. However, Cookiebot CMP also offers a small helper function that can make the work easier.',
194
+ 'cookiebot'
195
+ );
196
+ ?>
197
+ </p>
198
+ <p class="cb-faq__answer__content">
199
+ <?php esc_html_e( 'Update your script tags this way:', 'cookiebot' ); ?>
200
+ </p>
201
+ <?php
202
+ printf(
203
+ // translators: %1$s refers to the original script tag HTML, and %2$s refers to its replacement
204
+ esc_html__( '%1$s to %2$s', 'cookiebot' ),
205
+ '<code class="cb-faq__code">' . esc_html( '<script type="text/javascript">' ) . '</code>',
206
+ '<code class="cb-faq__code">' . esc_html( '<script<?php echo cookiebot_assist(\'marketing\') ?>>' ) . '</code>'
207
+ );
208
+ ?>
209
+ </div>
210
+ </div>
211
+ </div>
212
+
213
+ </div>
214
+ </div>
215
  </div>
src/view/admin/templates/header.php ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * @var string $cookiebot_logo
4
+ */
5
+ ?>
6
+ <?php
7
+ // phpcs:ignore WordPress.Security.NonceVerification.Recommended
8
+ if ( ! empty( $_GET['settings-updated'] ) ) :
9
+ ?>
10
+ <div class="cb-submit__msg">Changes has been saved</div>
11
+ <?php endif; ?>
12
+ <div class="cb-header">
13
+ <div class="cb-wrapper">
14
+ <a href="https://www.cookiebot.com">
15
+ <img
16
+ src="<?php echo esc_url( $cookiebot_logo ); ?>"
17
+ alt="Cookiebot logo">
18
+ </a>
19
+ </div>
20
+ </div>
src/view/admin/templates/main-tabs.php ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ use cybot\cookiebot\settings\pages\Dashboard_Page;
3
+ use cybot\cookiebot\settings\pages\Settings_Page;
4
+ use cybot\cookiebot\addons\config\Settings_Config;
5
+ use cybot\cookiebot\settings\pages\Support_Page;
6
+ use cybot\cookiebot\settings\pages\Debug_Page;
7
+
8
+ /**
9
+ * @var string $active_tab
10
+ */
11
+
12
+ $isnw = is_network_admin();
13
+ ?>
14
+ <div class="cb-main__tabs">
15
+ <?php if ( ! $isnw ) : ?>
16
+ <div class="cb-main__tabs_item <?php echo $active_tab === 'dashboard' ? 'active-item' : ''; ?>">
17
+ <a href="/wp-admin/admin.php?page=<?php echo esc_html( Dashboard_Page::ADMIN_SLUG ); ?>" class="cb-main__tabs__link">
18
+ <div class="cb-main__tabs__icon dashboard-icon"></div>
19
+ <span><?php esc_html_e( 'Dashboard', 'cookiebot' ); ?></span>
20
+ </a>
21
+ </div>
22
+ <?php endif; ?>
23
+ <div class="cb-main__tabs_item <?php echo $active_tab === 'settings' ? 'active-item' : ''; ?>">
24
+ <?php if ( $isnw ) : ?>
25
+ <a href="/wp-admin/network/admin.php?page=cookiebot_network" class="cb-main__tabs__link">
26
+ <?php else : ?>
27
+ <a href="/wp-admin/admin.php?page=<?php echo esc_html( Settings_Page::ADMIN_SLUG ); ?>" class="cb-main__tabs__link">
28
+ <?php endif; ?>
29
+ <div class="cb-main__tabs__icon settings-icon"></div>
30
+ <span><?php esc_html_e( 'Settings', 'cookiebot' ); ?></span>
31
+ </a>
32
+ </div>
33
+ <?php if ( ! $isnw ) : ?>
34
+ <div class="cb-main__tabs_item <?php echo $active_tab === 'addons' ? 'active-item' : ''; ?>">
35
+ <a href="/wp-admin/admin.php?page=<?php echo esc_html( Settings_Config::ADMIN_SLUG ); ?>" class="cb-main__tabs__link">
36
+ <div class="cb-main__tabs__icon plugins-icon"></div>
37
+ <span><?php esc_html_e( 'Plugins', 'cookiebot' ); ?></span>
38
+ </a>
39
+ </div>
40
+ <?php endif; ?>
41
+ <div class="cb-main__tabs_item <?php echo $active_tab === 'support' ? 'active-item' : ''; ?>">
42
+ <a href="/wp-admin/<?php echo $isnw ? 'network/' : ''; ?>admin.php?page=<?php echo esc_html( Support_Page::ADMIN_SLUG ); ?>" class="cb-main__tabs__link">
43
+ <div class="cb-main__tabs__icon support-icon"></div>
44
+ <span><?php esc_html_e( 'Support', 'cookiebot' ); ?></span>
45
+ </a>
46
+ </div>
47
+ <?php if ( ! $isnw ) : ?>
48
+ <div class="cb-main__tabs_item <?php echo $active_tab === 'debug' ? 'active-item' : ''; ?>">
49
+ <a href="/wp-admin/admin.php?page=<?php echo esc_html( Debug_Page::ADMIN_SLUG ); ?>" class="cb-main__tabs__link">
50
+ <div class="cb-main__tabs__icon debug-icon"></div>
51
+ <span><?php esc_html_e( 'Debug info', 'cookiebot' ); ?></span>
52
+ </a>
53
+ </div>
54
+ <?php endif; ?>
55
+ </div>
src/view/frontend/scripts/cookiebot-js.php CHANGED
@@ -11,8 +11,8 @@
11
  <?php if ( (bool) get_option( 'cookiebot-iab' ) !== false ) : ?>
12
  data-framework="IAB"
13
  <?php endif; ?>
14
- <?php if ( (bool) get_option( 'cookiebot-ccpa' ) !== false ) : ?>
15
- data-georegions="{'region':'US-06','cbid':'<?php echo esc_attr( get_option( 'cookiebot-ccpa-domain-group-id' ) ); ?>'}"
16
  <?php endif; ?>
17
  <?php if ( (bool) get_option( 'cookiebot-gtm' ) !== false ) : ?>
18
  <?php if ( empty( get_option( 'cookiebot-data-layer' ) ) ) : ?>
11
  <?php if ( (bool) get_option( 'cookiebot-iab' ) !== false ) : ?>
12
  data-framework="IAB"
13
  <?php endif; ?>
14
+ <?php if ( (bool) get_option( 'cookiebot-multiple-config' ) !== false && ! empty( get_option( 'cookiebot-second-banner-regions' ) ) && ! empty( get_option( 'cookiebot-second-banner-id' ) ) ) : ?>
15
+ data-georegions="{'region':'<?php echo esc_attr( get_option( 'cookiebot-second-banner-regions' ) ); ?>','cbid':'<?php echo esc_attr( get_option( 'cookiebot-second-banner-id' ) ); ?>'}"
16
  <?php endif; ?>
17
  <?php if ( (bool) get_option( 'cookiebot-gtm' ) !== false ) : ?>
18
  <?php if ( empty( get_option( 'cookiebot-data-layer' ) ) ) : ?>
src/view/frontend/scripts/google-consent-mode-js.php CHANGED
@@ -2,7 +2,18 @@
2
  /** @var string $data_layer */
3
  ?>
4
  <script data-cookieconsent="ignore">
5
- (function(w,d,l){w[l]=w[l]||[];function gtag(){w[l].push(arguments)}
6
- gtag("consent","default",{ad_storage:d,analytics_storage:d,wait_for_update:500,});
7
- gtag("set", "ads_data_redaction", true);})(window,"denied","<?php echo esc_js( $data_layer ); ?>");
 
 
 
 
 
 
 
 
 
 
 
8
  </script>
2
  /** @var string $data_layer */
3
  ?>
4
  <script data-cookieconsent="ignore">
5
+ window.<?php echo esc_js( $data_layer ); ?> = window.<?php echo esc_js( $data_layer ); ?> || [];
6
+ function gtag() {
7
+ dataLayer.push(arguments);
8
+ }
9
+ gtag("consent", "default", {
10
+ ad_storage: "denied",
11
+ analytics_storage: "denied",
12
+ functionality_storage: "denied",
13
+ personalization_storage: "denied",
14
+ security_storage: "granted",
15
+ wait_for_update: 500,
16
+ });
17
+ gtag("set", "ads_data_redaction", true);
18
+ gtag("set", "url_passthrough", true);
19
  </script>