My routes.rb has the followin开发者_C百科g 2 lines:
match "/", :to => "main#index"
match "main/index", :to => "main#index"
When I type localhost:3000/main/index in a browser I see the proper page (views/main/index.html.erb).
However, if I type just localhost:3000 I see public/index.html (I expect to see views/main/index.html.erb as well).
What am I missing ?
Remove public/index.html:
rm public/index.html
This is happening because static files (those in public/) are served in priority to the routes.
加载中,请稍侯......
精彩评论