For the method attribute what are the differences between POST and GET?

In the form element, the method attribute can send data via either POST or GET. But I’m having trouble understanding which one to use and when? I tried to find an answer at w3schools, but just wasn’t getting it. Can someone give me a simple answer with examples?
Cheers,
Mark

1 Like

always use POST for sensitive data (login form, register form and so forth). POST will not display the information in the address/url bar.

get will display the information in the URL bar which means the page can be bookmarked (unlike post), get is useful for searching, lets say you have a search box, then get is a good idea.

26 Likes

Thank you for your explanation.