• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer
Logo

CITROWEB

First choice for your online presence

  • home page
  • Services
    • Web design, web development and consulting
    • Online stores with WooCommerce
    • Technical support for WooCommerce stores
    • Search engine marketing
      • SEO: Your website receives more relevant visitors
      • SEA: Search engine advertising for your website
    • Web hosting packages and domains
  • Blog
  • Contact us
Home » Blog » WordPress multisite and cookie settings in wp-config.php

WordPress multisite and cookie settings in wp-config.php

9. July 2022

Error Image: I created a new site in my multisite environment and replaced the subdomain address for that site with its own domain. The domain records are configured correctly, but still I can’t log into the dashboard on the new site.

The multisite or network feature of WordPress has been an essential part of the core system since version 3.0. In the past, you had to access the possibilities of Multisite via plugins first, but today this feature is part of the basic framework of WordPress. With the current version, it is possible to run sites with different domains within one installation, without being limited to subdomain solutions and directories.

Important: For a setup with subdomain or individual domains, the constant COOKIE_DOMAIN must be set. Otherwise the main domain of the installation will be entered as cookie domain in ms-default-constants and the login will not work. The browser sends cookies only to the matching domain!

Solution

In the wp-config.php the line define( ‘COOKIE_DOMAIN’, ” ); should be inserted.

To make sure that the login with defined constant is not nevertheless hindered by existing cookies, the salt keys must be regenerated and the old ones replaced with them.

Filed Under: development, WordPress

Primary Sidebar

Search

Recent Posts

  • Remove “Thank you for your trust in WordPress” from the bottom of the dashboard
  • Remove WordPress logo from toolbar
  • Change login cookie lifetime in WordPress
  • WordPress multisite and cookie settings in wp-config.php
  • Update GUIDs in WordPress after domain move

Footer

Logo




© 2023 CITROWEB
  • Data protection
  • imprint
  • Deutsch