Can someone help me over this last roadblock...
I'm working through the tutorial above in Rails 2.0 http://www.netbeans.org/kb/60/ruby/model.html
And when I make it to step: "Code Sample 5: post_comment action" I can not get this to run under Rails 2.0. Errors. Seems to blow up on the 'Comment.new' line What is outdated or wrong about the syntax below?
def post_comment @comment = Comment.new( "post_id" => flash[:post_id], "created_at" => Time.now, "comment" => params[:comment]['comment'] ) if @comment.save flash[:notice] = 'Comment was successfully added.' redirect_to :action => 'show', :id => flash[:post_id] end end
Thanks, Kelly Greer kellygreer1@nospam.com change nospam to yahoo