Subdomains question

Hello,

I have followed

http://www.robbyonrails.com/articles/2009/01/11/subdomain-accounts-with-ruby-on-rails-explained and How to do Basecamp-style subdomains in Rails – Signal v. Noise

posts on working with subdomains (without the use of subomain-fu and other plugins). In those examples a user only can log into his/her account through his/her own subdomain.

I wonder is there a way to log into one's account (subdomain) from the domain.

Example:

Logging from www.foo.com/session/new,

should redirect me to,

elioncho.foo.com

Any ideas? Thanks,

Hi there,

You could just authenticate off of the Person/User model (whatever you name that) without scoping it to the account. Then just redirect_to account_path(@user.account) or something along those lines.

Good luck!

Cheers, Robby