Re:Bootstrapped. 10 Months. Learned Rails. Finally Launched....
by seats on Monday April 18, 2011 @06:45PM
(#2461049)
Take a look at high voltage -
Re:Bootstrapped. 10 Months. Learned Rails. Finally Launched....
by marcamillion on Monday April 18, 2011 @07:45PM
(#2461186)
This looks interesting, but not sure it will do what I need - which is having Rails re-route requests to index.html or root_path based on if they are logged in or not...or am I missing something ?
Re:Bootstrapped. 10 Months. Learned Rails. Finally Launched....
by seats on Monday April 18, 2011 @08:51PM
(#2461295)
Doesn't solve your problem directly, but it's a nice way to have static pages in your app in a manageable way.
You'd want to do something along the lines of what they show in the override section and test for your authenticated session within the controller, branching appropriately.
I wanted them to see compversions.com.
If I have index.html - as far as I found anyway - in my public directory, all requests to compversions.com (logged in or not) will either redirect to compversions/home/index or compversions.com/index.html.
So, as far as my research told me at the time (remember I am just learning Rails still, so I could be wrong anyway) was that if I wanted logged in users to see compversions.com when they are logged in and on the root_path, there couldn't be a index.html, otherwise Rails routing would default to index.html.