Displaying 1 result from an estimated 1 matches for "insect_name".
2006 Aug 09
1
Improvement: SiteMapper - working ideas as a possible RoR''s routing replacement
...evel1.add( :insect ) do |level2|
level2.route( ''gallery/insect'',
:controller=>''gallery'',
:type=>''insect''
)
level2.add( :description ) do |level3|
level3.route( [ ''gallery/insect/(.*?).html'', :insect_name ],
:controller=>''gallery'',
:action=>''show''
)
end
end
end
# then you can recognize an url to a ceratin route
route = mapper.recognize( ''/gallery/insect/135.html'' )
puts route.parameters.join( '', '&...