Routing to the welcome page

Hello

I want to setup the welcome page as the default page. so, i added the
last line belove to my config/routes.rb file but nothing changes.

ActionController::Routing::Routes.draw do |map|

map.connect ‘:controller/:action/:id.:format’
map.connect ‘:controller/:action/:id’
map.connect ‘’, :controller=>‘main’, :action=>‘welcome’
end

it still do not open the main/welcome when i type
http://localhost:3000/”. what’s the problem?

Thanks.

Bahadır Doğan wrote:

Hello

I want to setup the welcome page as the default page. so, i added the
last line belove to my config/routes.rb file but nothing changes.

ActionController::Routing::Routes.draw do |map|

map.connect ‘:controller/:action/:id.:format’
map.connect ‘:controller/:action/:id’
map.connect ‘’, :controller=>‘main’, :action=>‘welcome’
end

it still do not open the main/welcome when i type
http://localhost:3000/”. what’s the problem?

Thanks.

two things:

a) put
map.connect ‘’, :controller=>‘main’, :action=>‘welcome’
on the top line

b) remove the index.html file that is in pubic … it may be overriding
the route defined. (via the server which redirects there ; lighttpd /
ngnix / what-ever-server )

thank you.that solved the problem.