Checking if cookies accepted
-
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
The topic ‘Checking if cookies accepted’ is closed to new replies.