rails/rails — Issue #3316: ActiveResource element_path not adding prefixes
Author: bmorton
Created: 2011-10-13 09:52:17+00:00
State: open

I am attempting to follow the example at: http://api.rubyonrails.org/classes/ActiveResource/Base.html#method-c-element_path

It states that this should return as such:

```
Comment.element_path(1, :post_id => 5)
# => /posts/5/comments/1.json
```

Using a simple Comment model, this is what irb returns for me:

```
ruby-1.9.3-rc1 :001 > Comment.element_path(1, :post_id => 5)
=> "/comments/1.json?post_id=5"
```

Here's my Comment model:

```
class Comment < ActiveResource::Base
self.site = "http://localhost/"
end
```

I expected the output to be as the example shows.