I am available for freelance work! Click here to email me.

Escaping Params Containing Periods

Saturday, November 22nd, 2008

Just a quick one. Say you have a route like the following:
map.resources :users
And you’re using email addresses to look up users like:
/users/jim@somewhere.com
You’re going to run into an error along the lines of:
Missing template users/show.com.erb in view path blah/app/views
Which obviously isn’t what you want. To fix this, change your route to the following:
map.resources :users, :requirements => [...]

Posted in Ruby on Rails | Tags: , | Comments

Purify - Issue Tracker

Jim Neath is a 26 year old Freelance Ruby on Rails developer from Manchester, UK.

Recommend Me

Categories