1.All the name value pairs are submitted as a query string.
2.It’s not secured as submitted text is visible in plain text format in the Location bar of the web browser.
3.Length of the submitted string is restricted.
4.If get method is used and if the page is refreshed it would not prompt before the request is submitted again.
1.All the name value pair’s are submitted in the Message Body of the request structure.
2.Length of the string (amount of data submitted) is not restricted or limited.
3.Post Method is secured because Name-Value pairs cannot be seen in location bar of the web browser.
4.If post method is used and if the page is refreshed it would prompt before the request is submitted again.
As a general thumb rule if the form submitted changes the state or data on server then the request method used can be post otherwise if the data submitted doesn’t affect the server then the request method used can be post.
When we submit a search string to search string then the request method can be "get" because the submission will not change the state of server.
Asked In: Many Interviews |