• Installing this plugin on wordpress 6.4.3 breaks the user authentication mechanism. Cookie policies are set correctly. However when a user logs on they just get taken back to the logon page.

    Feel like this plugin needs some regression testing with WP 6.4.3 and later, as somethig has changed in the authentication mechanism which is incomplatible with this plug in (v2.1)

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter encirclesupport

    (@encirclesupport)

    I’ve managed to get this working on 6.4.3

    I replaced the samesite_setcookie function for the following code:

    function samesite_setcookie($name, $value, array $options) {
    setcookie($name, $value,$options);
    }

    It looks like the original code was wiping out other cookies set in the same request. Just replaced with the stock php setcookie function.

    Hi,

    I have the same issue, it’s not working anymore, but I’m not sure I understand what you did.

    Did you replace this whole part?

    function samesite_setcookie($name, $value, array $options) {
    $header = ‘Set-Cookie:’;
    $header .= rawurlencode($name) . ‘=’ . rawurlencode($value) . ‘;’;

    if (!empty($options['expires']) && $options['expires'] > 0) {
        $header .= 'expires=' . \gmdate('D, d-M-Y H:i:s T', (int) $options['expires']) . ';';
        $header .= 'Max-Age=' . max(0, (int) ($options['expires'] - time())) . ';';
    }


    and what did you replace it with exactly?

    Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Not working on WordPress 6.4.3’ is closed to new replies.