When should POST be used and when would get be better to use?
My general rule of thumb is to use Get when you are making requests to the server that aren’t going to alter state. Posts are reserved for requests to the server that alter state. One practical difference is that browsers and webservers have a limit on the number of characters that can exist in a URL.
Why would you use GET instead of POST?
GET is used for viewing something, without changing it, while POST is used for changing something. For example, a search page should use GET to get data while a form that changes your password should use POST . Essentially GET is used to retrieve remote data, and POST is used to insert/update remote data.
Can you use post instead of put in HTML?
Yes, you can. HTML forms, for example, use POST for all writes. If POST can do work of PUT method, why PUT method is required? It didn’t used to be. In HTTP/1.0, the specified methods were HEAD, GET, and POST. PUT was relegated to Appendix D: Additional Features. If I use POST method over PUT method, what will be disadvantages? PUT is idempotent.
Why is it important to use post instead of get?
The common response is always use POST. Problem solved. Security breaches in recent years involving mishandled and unsecured information between the browser and the server have helped to underscore this importance. But why? What difference does it make if you use POST versus GET requests in your applications?
When to use post instead of put rest?
Meaning, suppose you update a record to increment it, then you cannot use POST. Because each time a user makes that update the record will be different, and so the user cannot just go on trying again and again and expect the same result.
When to use post method or PUT method?
The POST method is used to request that the origin server accept the entity enclosed in the request as a new subordinate of the resource identified by the Request-URI in the Request-Line. It essentially means that POST request-URI should be of a collection URI. PUT method is idempotent.