Forum: Ruby on Rails how to redirect to a specific page??

385179d88397bbf7e2ed65db7aaecc16?d=identicon&s=25 Pratik S. (pratik_s)
on 2013-07-21 05:34
I have Rails version 2.3.8.I am using Netbeans 6.9.1 as IDE. I want to
redirect localhost:3000 to a specific page. i opened routes.rb file and
uncommented the line

 map.root :controller => "Welcome"
I created a controller named Welcome and a view named index. I also
deleted the default index file as suggested in some of the
websites.However, the page is not getting redirected to new index page.
What is the problem??
Aa082c8b00a50928e5860dcd70bf2368?d=identicon&s=25 tamouse m. (tamouse_m)
on 2013-07-21 08:48
(Received via mailing list)
On Jul 20, 2013, at 8:34 PM, Pratik S. <lists@ruby-forum.com> wrote:

> I have Rails version 2.3.8.I am using Netbeans 6.9.1 as IDE. I want to
> redirect localhost:3000 to a specific page. i opened routes.rb file and
> uncommented the line
>
> map.root :controller => "Welcome"
> I created a controller named Welcome and a view named index. I also
> deleted the default index file as suggested in some of the
> websites.However, the page is not getting redirected to new index page.
> What is the problem??

Did you remove public/index.html?
5f94b9b346c2aa648a80bc259978e5bc?d=identicon&s=25 Colin Law (Guest)
on 2013-07-21 16:29
(Received via mailing list)
On 21 July 2013 04:34, Pratik S. <lists@ruby-forum.com> wrote:
> I have Rails version 2.3.8.I am using Netbeans 6.9.1 as IDE. I want to
> redirect localhost:3000 to a specific page. i opened routes.rb file and
> uncommented the line
>
>  map.root :controller => "Welcome"
> I created a controller named Welcome and a view named index. I also
> deleted the default index file as suggested in some of the
> websites.However, the page is not getting redirected to new index page.
> What is the problem??

If it is not getting redirected then what do you see instead?

Also what do you see in development.log when you try to go to the page.

If you are new to Rails then if you have not already done so then work
right through a good tutorial such as railstutorial.org (which is free
to use online).  That will show you the basics of rails.

Colin
Please log in before posting. Registration is free and takes only a minute.
Existing account

NEW: Do you have a Google/GoogleMail, Yahoo or Facebook account? No registration required!
Log in with Google account | Log in with Yahoo account | Log in with Facebook account
No account? Register here.