Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge pull request #142 from codyrobbins/master
Added a warning about #1769 to the routing guide
  • Loading branch information
vijaydev committed Jun 13, 2013
2 parents 41a398f + d1c0d9b commit cf5bcf7
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions guides/source/routing.md
Expand Up @@ -171,6 +171,12 @@ A singular resourceful route generates these helpers:

As with plural resources, the same helpers ending in `_url` will also include the host, port and path prefix.

WARNING: A [long-standing bug](https://github.com/rails/rails/issues/1769) prevents `form_for` from working automatically with singular resources. As a workaround, specify the URL for the form directly, like so:

```
form_for @geocoder, url: geocoder_path do |f|
```

### Controller Namespaces and Routing

You may wish to organize groups of controllers under a namespace. Most commonly, you might group a number of administrative controllers under an `Admin::` namespace. You would place these controllers under the `app/controllers/admin` directory, and you can group them together in your router:
Expand Down

0 comments on commit cf5bcf7

Please sign in to comment.