0

I am getting the following error:

ERROR: Cookies are blocked or not supported by your browser. You must enable cookies to use WordPress.

When trying to login to a network site on a different domain with version 5.0.2WordPress.

I can login to the primary site, but when going to the dashbaord of the secondary site it redirects to the login screen on the different domain and gives the cookie error.

Relevant wp-config.php settings:

/* Multisite */
define('WP_ALLOW_MULTISITE', true);
define('MULTISITE', true);
define('SUBDOMAIN_INSTALL', true);
define('DOMAIN_CURRENT_SITE', 'number1.co.za');
define('PATH_CURRENT_SITE', '/');
define('SITE_ID_CURRENT_SITE', 1);
define('BLOG_ID_CURRENT_SITE', 1);

/* MU Domain Mapping */
define( 'SUNRISE', 'on' );

How can I fix this?

1 Answer 1

0

The problem was I had the old multi-site method, which used sunrise.php.

I removed wpcontent/sunrise.php and the SUNRISE setting in wp-config.php

I then added the relevent settings from the accepted answer on a similar question and it worked.

define('ADMIN_COOKIE_PATH', '/');
define('COOKIE_DOMAIN', '');
define('COOKIEPATH', '');
define('SITECOOKIEPATH', ''); 

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.