Skip to content

Commit

Permalink
Update README instructions for subclassed PagesController
Browse files Browse the repository at this point in the history
  • Loading branch information
mhoran committed Feb 23, 2012
1 parent 8884f70 commit 9c7c0ad
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions README.md
Expand Up @@ -96,7 +96,7 @@ Create a PagesController of your own:
Override the default route: Override the default route:


# in config/routes.rb # in config/routes.rb
resources :pages match "/pages/*id" => 'pages#show', :as => :page, :format => false


Then modify it to subclass from High Voltage, adding whatever you need: Then modify it to subclass from High Voltage, adding whatever you need:


Expand All @@ -115,10 +115,6 @@ Then modify it to subclass from High Voltage, adding whatever you need:
end end
end end


Remember that if you create your own PagesController, you'll need to review your custom routes so they point to it, that is, <code>pages#show</code> instead of <code>high_voltage/pages#show</code>, like this:

match '/:id' => 'pages#show', :as => :static, :via => :get

Testing Testing
------- -------


Expand Down

0 comments on commit 9c7c0ad

Please sign in to comment.