Hi, if in rails 2.3 we can use this syntax map.connect '' '', :controller => ''people'', :action => ''action'' the result it will simplify from http://localhost:3000/people/action to http://localhost:3000/ but in rails 3.2, we can''t use map.connect right? i try to use : match '' people/action '' => '' people # action '', as: ''shows'' the result, it just only generate for paths and url.. the url still the same... do anyone know how to do it?? Thank.. -- 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-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/iVoZBabLfpkJ. For more options, visit https://groups.google.com/groups/opt_out.
radical wrote in post #1069978:> if in rails 2.3 we can use this syntax > map.connect '' '', :controller => ''people'', :action => ''action'' > > the result it will simplify from > http://localhost:3000/people/action to http://localhost:3000/ > > but in rails 3.2, we can''t use map.connect right? > i try to use : > match '' people/action '' => '' people # action '', as: ''shows''If you create a new Rails 3.2 app and look at the config/routes.rb file you''ll lots of examples of route mappings. Including this one... # You can have the root of your site routed with "root" # just remember to delete public/index.html. # root :to => ''welcome#index'' -- Posted via http://www.ruby-forum.com/. -- 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-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit https://groups.google.com/groups/opt_out.
I think my topic title might be wrong due to my bad english.. actually, i try to change the change the url from http://localhost:3000/people/l <http://localhost:3000/people/action>ist to http://localhost:3000/ <http://localhost:3000/people/action>sales_contact and not to set a root for website if in rails 2.3 map.connect ''Person'' , :controller=> ''people'', :action => ''list'' the result it change url from http://localhost:3000/people/l<http://localhost:3000/people/action> ist to http://localhost:3000/ <http://localhost:3000/people/action> sales_contact if in rails 3.2?? -- 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-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/M5WQm4p9QQQJ. For more options, visit https://groups.google.com/groups/opt_out.
nvm, i already know how to used it.. they just rename the ''map.connect'' to ''match''... lol so we just need to use this code match ''Person'' , :controller=> ''people'', :action => ''list'' -- 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-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/axGb8ZuCGRcJ. For more options, visit https://groups.google.com/groups/opt_out.