Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #24990
    Leslie
    Participant

    Re: Cookie Notice

    Hello what I would like to do is have the Cookie Notice reappear every time someone visits our website.

    I have set the default to 1 day for remembering a person’s visit to our site.

    However you could have more than one person working on the same computer within any given day in which case I would like the Cookie Notice to reload each and every time a user has left our site and someone revists on the same computer?

    Is this possible please?

    Our website is:

    http://www.paulcrowley.co.uk

    Thank you.

    Regards

    Leslie

    #24991
    Leslie
    Participant

    Hi Further to my question above, I did find this on the web but don’t know how to action it:

    File cookie-notice.php i’ve changed the code at line 150+ to

    $this->times = array(
    ‘session’ => array( __( ‘session’, ‘cookie-notice’ ), 0 ),
    ‘day’ => array( __( ‘1 day’, ‘cookie-notice’ ), 86400 ),
    ‘week’ => array( __( ‘1 week’, ‘cookie-notice’ ), 604800 ),
    ‘month’ => array( __( ‘1 month’, ‘cookie-notice’ ), 2592000 ),
    ‘3months’ => array( __( ‘3 months’, ‘cookie-notice’ ), 7862400 ),
    ‘6months’ => array( __( ‘6 months’, ‘cookie-notice’ ), 15811200 ),
    ‘year’ => array( __( ‘1 year’, ‘cookie-notice’ ), 31536000 ),
    ‘infinity’ => array( __( ‘infinity’, ‘cookie-notice’ ), PHP_INT_MAX )
    );
    The new thing is here the “Session”-Option.

    And in front.js i changed line 17 to:

    document.cookie = cnArgs.cookieName + ‘=’ + cookie_value + (parseInt( cnArgs.cookieTime ) > 0 ? ‘;expires=’ + cnLater.toGMTString() : ”)+ ‘;’ + ( cnArgs.cookieDomain !== undefined && cnArgs.cookieDomain !== ” ? ‘domain=’ + cnArgs.cookieDomain + ‘;’ : ” ) + ( cnArgs.cookiePath !== undefined && cnArgs.cookiePath !== ” ? ‘path=’ + cnArgs.cookiePath + ‘;’ : ” );

    #25417
    josschuurmans
    Participant

    Hi Leslie, where did you find those instructions on the web? I would like to add the option ‘2 years’.

    Cheers,
    Jos

    #25759
    Beppe
    Participant
    This reply has been marked as private.
Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.