Guest User

Untitled

a guest
May 27th, 2018
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.59 KB | None | 0 0
  1. ActionController::Routing::Routes.draw do |map|
  2.  
  3. map.connect :controller=> 'forum', :action => 'index'
  4.  
  5. map.resources :users
  6.  
  7. map.resources :session, :controller => "session"
  8.  
  9. map.connect 'login', :controller => 'session', :action => 'new'
  10. map.connect 'signup', :controller => 'users', :action => 'new'
  11. map.connect 'logout', :controller => 'session', :action => 'destroy'
  12.  
  13. map.resources :forum
  14.  
  15. map.namespace(:admin) do |admin|
  16. admin.resources :forums
  17. end
  18.  
  19. map.connect ':controller/:action/:id'
  20. map.connect ':controller/:action/:id.:format'
  21. end
Add Comment
Please, Sign In to add comment