diff options
author | Rohit Arondekar <rohit.arondekar@gmail.com> | 2010-07-07 22:15:15 -0700 |
---|---|---|
committer | Rohit Arondekar <rohit.arondekar@gmail.com> | 2010-07-07 22:15:15 -0700 |
commit | dc364fdc595405aa3d5735e60d46ad3f9544a65b (patch) | |
tree | 3fcea4bcf55bd37b783f6ea227b75596194e63e8 | |
parent | 64c75d6618b6bc21576e95ceb31467d1984ecb33 (diff) | |
download | rails-dc364fdc595405aa3d5735e60d46ad3f9544a65b.tar.gz rails-dc364fdc595405aa3d5735e60d46ad3f9544a65b.tar.bz2 rails-dc364fdc595405aa3d5735e60d46ad3f9544a65b.zip |
API Docs: Fixes to the Routing docs
-rw-r--r-- | actionpack/lib/action_dispatch/routing.rb | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/actionpack/lib/action_dispatch/routing.rb b/actionpack/lib/action_dispatch/routing.rb index 89007fab74..c664fb0bc2 100644 --- a/actionpack/lib/action_dispatch/routing.rb +++ b/actionpack/lib/action_dispatch/routing.rb @@ -31,7 +31,7 @@ module ActionDispatch # Think of creating routes as drawing a map for your requests. The map tells # them where to go based on some predefined pattern: # - # AppName::Applications.routes.draw do |map| + # AppName::Application.routes.draw do |map| # Pattern 1 tells some request to go to one place # Pattern 2 tell them to go to another # ... @@ -62,7 +62,7 @@ module ActionDispatch # # redirect_to show_item_path(:id => 25) # - # Use <tt>root</tt> as a shorthand to name a route for the root path "". + # Use <tt>root</tt> as a shorthand to name a route for the root path "/". # # # In routes.rb # root :to => 'blogs#index' @@ -72,7 +72,7 @@ module ActionDispatch # # # and provide these named routes # root_url # => 'http://www.example.com/' - # root_path # => '' + # root_path # => '/' # # Note: when using +controller+, the route is simply named after the # method you call on the block parameter rather than map. @@ -91,9 +91,7 @@ module ActionDispatch # # Routes can generate pretty URLs. For example: # - # match '/articles/:year/:month/:day', :constraints => { - # :controller => 'articles', - # :action => 'find_by_date', + # match '/articles/:year/:month/:day' => 'articles#find_by_id', :constraints => { # :year => /\d{4}/, # :month => /\d{1,2}/, # :day => /\d{1,2}/ |