I have a view folder product_types. The name of the controller file is product_types_controller and the class I have is ProductTypesController. I'd normally keep the _ format that rails prefers but I need to keep the current page syntax for search index reasons.
How do I get this controller to show up for mysite.com/product-types and all pages in the folder product_types to appear for mysite.com/product-types/some-page? Do I need to name the pages with - or should I use the _ syntax as well and just change the routes.
This is for a Rails 2.3.8 site.
Thanks
For Rails 3 you have to do this differently:
resources "product-types", :as => :product_types, :controller => :product_types
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With