What is difference between GET and POST methods in php?

Both GET and POST methods are used to send information to the server. Both are sending information in different ways.

Difference between GET and POST method -

GET method
  • Information sent with the GET method is visible to everyone (all variable names and values are displayed in the URL). So, the GET method is not secured.
  • GET method doesn't send binary data (images and documents). It sends only ASCII characters.
  • GET method sends information in a limit. The limit is upto 2000 characters. 
  • GET should never be used for sending passwords or other sensitive information.
  • The variables are displayed in the URL, It is possible to bookmark the page.
POST method
  • Information sent with the POST method is invisible to others. The POST method is secured and developers prefer to use POST method.
  • POST method used to send binary data as well as ASCII characters.
  • Post has no limits on the amount of information to send.
  • Post is used for sending passwords or other sensitive information.
  • The variables are not displayed in the URL, It is not possible to bookmark the page.

Comments

Popular posts from this blog

Why entrance animation not working in Elementor?

Why position relative leaves empty space below the div?