WPIntell

Source evidence

Checking if cookies accepted

Surbma | GDPR Proof Cookie Consent & Notice Bar · support · 2021-03-04T09:28:00+00:00

mixedsentiment
mediumseverity
0.78relevance
5replies
Evidence linked to opportunitycommercial context

Proof Health

Open evidence

Commercial opportunities need traceable source links before they are treated as build-worthy.

5 / 25 rows with source links

20.0% of this page's analysis has direct source links.

0 build-decision rows missing links

0 rows here require auditable proof before promotion.

20 rows with no attached evidence

0 rows have source counts but still need direct links.

Conversation

support
yaseico resolved
Hi, I am using an affiliate plugin for woo-commerce ( YITH WooCommerce Affiliates) which sets a cookie when a visitor arrives at the site. If the visitor is arriving for the first time then I need to be able to check if they have accepted cookies before the cookie is written by the other plugin. I tried to search for the information about your plugin but could not find the information I think I need. I have a code sample on how to do that with the affiliate plugin but I don’t know what hook to use that allows me to check if the cookies have been accepted by your plugin. So I would like to use code in my functions.php file something like: if ( function_exists( ‘surbma-cookies-have-been-accepted’ ) && ! surbma_cookies_accepted() ) return false; This approach would be used for any plugin that write cookies of course. Hope that makes sense. Could you let me know how I can check if surbma cookies have been accepted? Thanks Tim Hi, this should work inversely. There is no reason for other plugin developers to implement cookie compatibility with cookie consent plugins, as there are a lot of solutions. But indeed, you can make your own integration. My plugin is checking the cookie consent with JavaScript. This method is a cache proof method, hence it is doing so. I can not support you with this kind of job, so you need to find a developer. But my next big update will give you options to add any custom scripts, that will be blocked until cookie categories are accepted by the visitor. If this is something, you want, it will be added to the plugin. Hi @surbma , thanks for your reply. The next update you mention sounds like it is something I could definitely use yes. I appreciate that you can’t support integration jobs. But can I just check to make sure I understand your reply so that I can discuss with a developer. If I wanted to integrate with your cookie plugin with custom code, then what hook would we use that allowed us to determine when a user clicked “ok” in your cookie plugin? Or are you suggesting there is no hook available and we should use another method? Thanks Tim There is no need for any hooks, as cookies are saved in the browser, which can be read by JS. A developer will understand this. ok thanks, now I understand. I appreciate your help and feedback. I like your plugin a lot compared to the many others available so look forward to your updates. Thanks Tim Thank you! It is good to know, you like it. 🙂

Comments

5 shown
Surbma 2021-03-05T06:50:00+00:00

Hi, this should work inversely. There is no reason for other plugin developers to implement cookie compatibility with cookie consent plugins, as there are a lot of solutions. But indeed, you can make your own integration. My plugin is checking the cookie consent with JavaScript. This method is a cache proof method, hence it is doing so. I can not support you with this kind of job, so you need to find a developer. But my next big update will give you options to add any custom scripts, that will be blocked until cookie categories are accepted by the visitor. If this is something, you want, it will be added to the plugin.

yaseico 2021-03-05T08:29:00+00:00

Hi @surbma , thanks for your reply. The next update you mention sounds like it is something I could definitely use yes. I appreciate that you can’t support integration jobs. But can I just check to make sure I understand your reply so that I can discuss with a developer. If I wanted to integrate with your cookie plugin with custom code, then what hook would we use that allowed us to determine when a user clicked “ok” in your cookie plugin? Or are you suggesting there is no hook available and we should use another method? Thanks Tim

Surbma 2021-03-05T08:45:00+00:00

There is no need for any hooks, as cookies are saved in the browser, which can be read by JS. A developer will understand this.

yaseico 2021-03-05T09:03:00+00:00

ok thanks, now I understand. I appreciate your help and feedback. I like your plugin a lot compared to the many others available so look forward to your updates. Thanks Tim

Surbma 2021-03-05T09:19:00+00:00

Thank you! It is good to know, you like it. 🙂