Support » Plugin: GDPR Cookie Consent (CCPA Ready) » Setting expiry on Accept notice

  • Resolved psudan

    (@psudan)


    Hi there,

    Is it possible to set an expiry on the consent itself. I would like to have the popup reload/reset automatically on a weekly basis irrelevant if the user has accepted or not before!

    Thanks,

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author webtoffee

    (@webtoffee)

    Hi @psudan,

    You may use the below code snippet to alter the viewed_cookie_policy expiration period. Copy it to your active theme’s functions.php file.

    add_action('wp_footer','cli_set_expire',20);
    function cli_set_expire()
    { 
    	if(class_exists('Cookie_Law_Info_Public')) //first time visit and class exists
    	{
    	?>
    	<script type="text/javascript">
    
    		CLI_ACCEPT_COOKIE_EXPIRE = 7;
    		
    	</script>
    	<?php
    	}
    }

    If you like the plugin, leave us a review.

    keesjan

    (@keesjan)

    Hi, and what about reload popup only when basic consetn is given?

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Setting expiry on Accept notice’ is closed to new replies.