On Wed, Jun 23, 2010 at 9:51 AM, Joe <j...@dev-hq.co.uk> wrote: > I see code like this used in examples: > > config.gem 'rack-rewrite', '~> 1.0.0' > require 'rack/rewrite' > config.middleware.insert_before(Rack::Lock, Rack::Rewrite) do > rewrite '/wiki/John_Trupiano', '/john' > r301 '/wiki/Yair_Flicker', '/yair' > r302 '/wiki/Greg_Jastrab', '/greg' > r301 %r{/wiki/(\w+)_\w+}, '/$1' > end
> Where does this code go? Look at your app and see where you find 'config.gem' entries. Or read about using Rack middleware. It should be pretty obvious :-) > How can I make this apply to a whole group? And you've already gotten that answer -- use a regular expression. If you don't recognize that your own example includes one, you're probably in deep bandini already :-) Good luck, -- Hassan Schroeder ------------------------ hassan.schroe...@gmail.com twitter: @hassan -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-t...@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.