Hi all!
I've deployed askbot on subdomain and I have another django application (blogs) that runs on main domain. Both share the same database, so users are registered and logged in only with askbot.
But now I want users that logged in on subdomain will be "logged in" on main domain automatically, and vice versa of course.
I added SESSION_COOKIE_DOMAIN = 'maindomain.com' to both askbot and blogs, but it doesn't help. What is common solution for this?
P.S. Tow applications are different django instances that everyone in its own virtualenv with own 'settings.py' file.
Thanks!
edit:
Configs are same for two sites:
CACHES = {
'default': {
'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
'LOCATION': '127.0.0.1:11211',
'KEY_PREFIX': 'production'
}
}
CACHE_MIDDLEWARE_ANONYMOUS_ONLY = True
#SESSION_ENGINE = 'django.contrib.sessions.backends.cache'
SESSION_COOKIE_DOMAIN = '.domain.org'
SESSION_COOKIE_NAME = "sesid"
I've tried various session engines, but seems that problem is not here..
Please try SESSION_COOKIE_DOMAIN = '.maindomain.com'
(With the leading "dot" before "mydomain")
Does that help?
Asked: Jul 14 '11
Seen: 74 times
Last updated: Jul 20 '11
Copyright Askbot, 2010-2011. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.