如comment_controller.rb中所示:
- def create
- @comment = Comment.new(params[:comment])
- @comment.save
- end
- def create
- @comment = Comment.new(params[:comment])
- @comment.save
- end