4

The HTTP Accept header can specify priority using the q specifier, such as

application/xml;q=0.8

I had a look in the RFC but could see any mention of whether the q specifier is subject to localization or not. For instance, could a European browser send the figure as q=0,8 instead if the Accept-Language was set accordingly?

If not, there must be some documentation somewhere that specifies that HTTP uses the period notation and is culture invariant in its headers I guess?

2 Answers 2

3

Section 3.9 of RFC-2616 (the HTTP/1.1 spec) defines a Quality Value (the value assigned to 'q' in your example) as:

qvalue         = ( "0" [ "." 0*3DIGIT ] )
               | ( "1" [ "." 0*3("0") ] )

so all HTTP applications must use a decimal point, not a comma or anything else, regardless of where in the world they reside.

Sign up to request clarification or add additional context in comments.

1 Comment

Thanks, that's exactly what I was looking for and failed to find :)
1

A technical protocol is always culture-independent - it's technical, not American or anything. Of course you can not localize anything in a HTTP header. You can also not localize the header fields by translating them to the language that it is used in the country the browser is run or written in.

2 Comments

Technical protocols are usually “culture-independent,” which means in practice that they are based on US English, to the extent that they use expressions resembling a human language. There is however no guarantee that every protocol always follows this principle. Ultimately, such things are defined in each protocol specification.
This is of course correct, but I think if you are asking these questions about the HTTP protocol, you are following the wrong line of thought ;).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.