# Getting Started with Rails - post\_comment\_url

**URL:** <https://www.ruby-forum.com/t/getting-started-with-rails-post-comment-url/165639>\
**Category:** Rails\
**Created:** [April 16, 2009, 12:04am UTC](https://www.ruby-forum.com/t/getting-started-with-rails-post-comment-url/165639 "2009-04-16T00:04:14Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [April 16, 2009, 12:04am UTC](https://www.ruby-forum.com/t/getting-started-with-rails-post-comment-url/165639/1 "2009-04-16T00:04:14Z")

</div>

Hi,  
Thanks for a wonderful Getting Started with Rails. I am up to the last  
section and just added the comments part.  
So while testing and looking over comments\_controller.rb;  
I see the reference to post\_comment\_url calll where is this defined.  
Below is the message I am getting.  
Thanks

ActionController::RoutingError (post\_comment\_url failed to generate  
from {:post\_id=\>#\<Post id: 1, name: “lin”, title: “post 1”, content:  
“content 1”, created\_at: “2009-04-15 16:56:44”, updated\_at:  
“2009-04-15 16:56:44”\>, :action=\>“show”, :id=\>#\<Comment id: nil,  
commenter: “jake lin”, body: “this is a new comment”, post\_id: 1,  
created\_at: nil, updated\_at: nil\>, :controller=\>“comments”}, expected:  
{:action=\>“show”, :controller=\>“comments”}, diff: {:post\_id=\>#\<Post  
id: 1, name: “lin”, title: “post 1”, content: “content 1”, created\_at:  
“2009-04-15 16:56:44”, updated\_at: “2009-04-15  
16:56:44”\>, :id=\>#\<Comment id: nil, commenter: “jake lin”, body: “this  
is a new comment”, post\_id: 1, created\_at: nil, updated\_at: nil\>}):  
(eval):16:in `post_comment_url' app/controllers/comments_controller.rb:18:in`create’

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [April 25, 2009, 11:52am UTC](https://www.ruby-forum.com/t/getting-started-with-rails-post-comment-url/165639/2 "2009-04-25T11:52:12Z")

</div>

Same problem here!!

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [August 13, 2009, 6:00pm UTC](https://www.ruby-forum.com/t/getting-started-with-rails-post-comment-url/165639/3 "2009-08-13T18:00:04Z")

</div>

Ro wrote:

> Same problem here!!

Arrgh! I’m also having the same problem! Can someone point me in the  
right direction of a solution?

It’s so frustrating to get this far with rails, but not be able to  
finish the “Getting Started” Tutorial!

I am using Rails 2.3.2 and Ruby 1.8.6. The tutorial does not indicate  
that Ruby 1.9 is required, does anyone know if it is?

I’ve had trouble upgrading Ruby in the past, but I’ll try again now.

Thanks to anyone who can help!
