Topic: Why my session domain to all isnt working?

Hello Guys,

I have a little problem with my login session and Nifty Authentication.
if i set my initializers/session_store.rb to :domain => :all
and i try to login, my subdomain need a new login.

but if i set the :domain => mydomain.domain.com
i dont need to login to access this domain.

i have tryed to :domain => '.domain.com'
and like my :all i need to register on each domain.

by firebug show me 2 different sesion for each sub domain and main domain.

thanks if you have an idea.

Re: Why my session domain to all isnt working?

I'm running into this same thing.   Works perfectly in dev environment (only sets one cookie for the session at the TLD), but on production it sets two cookies (one for TLD and one for subdomain).  Makes it so the user must log in at each subdomain.

Any ideas on why it would perform differently in Dev vs Production?

Re: Why my session domain to all isnt working?

I'm not exactly sure how to correctly answer your question... but I do know that cookies are handled differently between domains and subdomains.

I think *.* is shared between all domains and *.*.* is only shared within itself. I could have it mixed up. You might want to do some google searching to get a correct answer.

Learning rails, one day at a time.

http://keilmiller.com