Forum: Ruby on Rails Custom login page

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
53d3b6134f292ed40bc81a12689d23f2?d=identicon&s=25 alamodey (Guest)
on 2009-01-22 14:19
(Received via mailing list)
Hi,

I'm new to Rails. I'd like to have a customized login page for each
user. Just like Twitter how you go to www.twitter.com/username and you
can login from there. How do I do that? Thanks.
280b78a61a968391b7e07e912be102a8?d=identicon&s=25 Robert Walker (robert4723)
on 2009-01-22 14:57
alamodey wrote:
> Hi,
>
> I'm new to Rails. I'd like to have a customized login page for each
> user. Just like Twitter how you go to www.twitter.com/username and you
> can login from there. How do I do that? Thanks.

I'm not sure exactly how Twitter implemented their login page, but my
guess is that they are just styling the layout with CSS rules associated
to the user account.
5772c599ccab3081e0fffb1d54f3b6de?d=identicon&s=25 Andrew Timberlake (andrewtimberlake)
on 2009-01-22 15:53
(Received via mailing list)
On Thu, Jan 22, 2009 at 3:57 PM, Robert Walker <
rails-mailing-list@andreas-s.net> wrote:

> to the user account.
> --
> Posted via http://www.ruby-forum.com/.
>
> >
>
If you want to have the username on the url like they have, you can use

map.connect ':username', :controller => <controller_name>, :action =>
<action_name> and you will access the username via params[:username]
You will need to have that as one of the last entries in your routes
file
and you'll have to be careful of usernames conflicting with your other
controller paths

--
Andrew Timberlake
http://ramblingsonrails.com
http://www.linkedin.com/in/andrewtimberlake

"I have never let my schooling interfere with my education" - Mark Twain
This topic is locked and can not be replied to.