TrentonMcManus TrentonMcManus - 1 month ago 9
HTML Question

What are HTTP 'method' capitalization best practices?

I have seen HTTP methods written in all caps and in all lowercase letters. Is there any reason why you would want to write

POST
rather than
post
in the method attribute of a form element, for example?

Do some browsers handle capitalized
POST
and
GET
differently than lowercase
post
and
get
?

Answer Source

Browsers handle GET and POST case-insensitively (I'm sure it's described somewhere in the HTML5 spec).

That being said: method names are case-sensitive in HTTP, so, for clarity, I would advise to use the notation you'll also see in the HTTP request (that is, uppercase in this case).