What is different between post and get method?
Both methods are used to send the data from the client to the server on the HTTP protocol. More specifically, when you try to log in to the website, the browser will send the data or request to the server and wait for a response. Once the browser receives the response from the server, your information will show up on the screen. But what is the difference between these two methods? The main difference is the way your browser sends the data to the server. This difference can have a significant influence on designing your website. Let me explain these two methods to you.
First, the post method won’t show the data within your URL so that people can get higher security protection. The data will be stored in an HTTP header. The advantage of the post method is security, comparing to other means. The data is invisible on the way to the server. This can prevent your website from hacking your data in the middle of the transformation. However, the disadvantage is the website can not be added to the bookmark, which uses URL as a connection. Besides, it can not be stored in your browser cached. If your website needs to have an offline mode or store the user data in the cached, be aware of this.
Second, the get method is often used on the data, not relating to personal information and for instance, searching websites or navigation items. Unlike the post method, keep the data invisible, get method directly show the data in the URL. This method uses key-value in the URL so the server can quickly parse the URL to get the user information. For instance, when we search the keywords on Google, it will send “https://www.google.com/search?q=my + cake” to the server asking for a website related to “my cake.”