The difference between the Get and Post Request. Let’s check some of these differences
GET | POST |
1) Just in case of Get request, only a limited amount of data is often to be sent because data is sent in the header. | Just in case of a post request, a big amount of data is often sent because data is delivered in the body. |
2) The get request is not secured because data is revealed in the URL bar. | Post request is secured because data is not revealed in the URL bar. |
3) Get requests that can be bookmarked. | Post requests cannot be bookmarked. |
4) Getting a request is idempotent . It means second appeal will take no notice until response of first request is delivered | Post request is non-idempotent. |
5) Get requests are more systematic and used more than Post. | Post request is less systematic and used less than get. |
These are two common methods for the request- response in middle of a server and client are:
GET- Data is requested from a specified source.
POST- Processed the specified data from the source and submitted it.
The string of query (name/value pairs) is delivered inside the URL of a GET request:
GET/RegisterDao.jsp?name1=value1&name2=value2
The data is sent in the requested header in the case of GET request and we all know that. It is a default Request kind. Want to see what information is delivered to the server? Let’s see here
The string for query (name/value pairs) is sent in the HTTP message body for the Post Requests:
POST/RegisterDao.jsp HTTP/1.1 Host: www.intellinuts.com name1=value1&name2=value2
We all know that in case of post requests the original data is sent in a message body. Let’s see how the information is passed to the server in the case of a post request.