Hi @barbarawebnauta,
Please check here in the section “The Cookie Audit Table” for styling audit table.
We are storing a cookie “viewed_cookie_policy” for each activity ( accept / reject ). If user accepts, the value will be “yes”. If the user rejects, the value will be “no”. According to that site owner can restrict their cookies. Also, Reject will delete all the cookies that are stored in non-necessary category by the admin.
Try below JS code in your site like this, here it will enable for GA ( Google Analytics ) if the consent is yes.
<script type="text/javascript"
src="//cdnjs.cloudflare.com/ajax/libs/jquery-cookie/1.4.1/jquery.cookie.min.js">
var consent_value = $.cookie("viewed_cookie_policy");
if (consent_value == 'yes')
{
enableGoogleAnalytics(); // enable GA inside this function
}
}