Rails 3 routing - passing params from routes.rb

后端 未结 1 698
太阳男子
太阳男子 2020-12-29 03:44

In rails 2.3.5 you could do something like this inside the routes.rb file:

map.root :controller => \"pages\", :action => \"show\", :id => 3
<         


        
1条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2020-12-29 04:10

    Are you sure the following doesn't work?

    root :to => "pages#show", :id => 3
    

    0 讨论(0)
提交回复
热议问题