This is awesome.
r.match("/:page_slug").defer_to do |request, params|
page = Page.first(:slug => params[:page_slug])
params.merge(
:controller => 'pages',
:action => 'show',
:id => page.id) unless page.nil?
end
April 26th, 2008
/ Trackback