How to post html form data to controller using ruby on rails 3.1
I am using ruby on rails 3.1. And am trying to post html form data to controller for saving the record in database. But I am getting routing error like this 'No route matches [POST] first/save' .But when I tried to run this link in address bar like '127.0.0.1:3000/first/save' it is working fine. Can any one please tell me where am doing wrong. My routes are like: Rails.application.routes.draw do root 'first#hello' get 'first/save' end And my html form is like: <form accept-charset="UTF-8" method='post' action='/first/save'> <label for='S.No'>S.No</label> <input type="text" name="s_no"