3

when I generate a two word named controller, like FooBar rails creates a controller and path like foo_bar this is not pretty. I would like to have the paths at least be FooBar.

Possible? Suggestions?

cbrulak
  • 15,436
  • 20
  • 61
  • 101

1 Answers1

3

Depends on how your route is defined in routes.rs. For example:

# if you have named routes
map.foobar '/foobar/:action', :controller => 'foobar'

# if you have resources, this will generate
map.resources :foo_bar, :as => 'foobar'

This is for Rails 2.3.*, it's slightly different in Rails 3.

Slobodan Kovacevic
  • 6,848
  • 3
  • 29
  • 33