Jump to main content Jump to doc navigation

session_cookie_domain

Other versions: 3.x — Other languages: EN RU — Found a problem? Please edit this page or report an issue.

Name: Session Cookie Domain Type: String Default: localhost

Use this setting to customize the session cookie domain.

You will need to clear your local cookies in your browser after changing this setting.

This setting is useful to change if you are running multiple Contexts on one top-level domain, but want to share logins across them. For example, changing the setting to:

.mydomain.com

will allow all MODX sessions to persist across any *.mydomain.com site, allowing logins to work across subdomains.

This setting isn't in MODX by default, as it's best to let PHP calculate this on its own. Only set this if you are sure of what you are doing.