What does 'Accept: */*' mean under Client

2019-04-24 11:37发布

问题:

I was comparing headers of same HTTP Post request for Firefox and Internet Explorer and I see that for IE.

I was wondering:

What does Accept: */* mean under Client section of Request Headers?

回答1:

The accept: header defines the content type the client accepts, or expects to be returned by the server. Depending on the situation this can be text/css, text/html, image/png, .. etc. - just some mime type.

The * character is considered the wildcard. accept: */* simply means that any data of whatever mimetype is accepted and the server may choose what to return to the requesting client.

Also, please escape the * characters in your question to \*



回答2:

It's answered in the specification. See http://greenbytes.de/tech/webdav/rfc2616.html#header.accept and http://greenbytes.de/tech/webdav/draft-ietf-httpbis-p2-semantics-21.html#header.accept