Created
April 11, 2012 08:07
-
-
Save vindia/2357783 to your computer and use it in GitHub Desktop.
Namespaced routing for subdomains in Rails
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Rails::Application.routes.draw do | |
constraints :subdomain => 'admin' do | |
namespace(:admin, :path => '/') do | |
resources :books | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment