Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Chouby

    (@chouby)

    Hi!

    Yes. There are ways to share cookies across domains but it’s no easy. And there are important security implications. As far as I know WPMUDEV developped such feature in their domain mapping plugin (*for multisite*). But Nothing’s ready for Polylang when using the multiple domains options
    There is no issue if you use the subdomains option (the subdomain name is the language code).

    Thread Starter Sergio De Falco

    (@sgr33n)

    So, unfortunately, since that the cookie is stored just for the default language, other users cannot access and interact with WP, e.g. commenting.

    I think for now it’s better opt for another setting.

    Thanks for your explanation ??

    Thread Starter Sergio De Falco

    (@sgr33n)

    I was thinking that maybe could be enough, not to share cookies across domains, but to have a different subdomain cookie stored. If e.g. I connect to it.example.com/wp-admin Polylang redirects to https://www.example.com/wp-login.php?redirect_to=http%3A%2F%2Fit.example.com%2Fwp-admin%2F&reauth=1 If could be possible to have a different login page on it.example.com/wp-login.php the login issue could be solved.

    Plugin Author Chouby

    (@chouby)

    If you are using only subdomains, putting this in your wp-config.php should log you on all subdomains:

    define( 'COOKIE_DOMAIN', 'example.com' );
    define( 'ADMIN_COOKIE_PATH', '/' );

    Thread Starter Sergio De Falco

    (@sgr33n)

    Good, thanks!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Language in subdomain and login cookie’ is closed to new replies.