It appears that Firefox 3.5.2 broke XMLHttpRequest.setRequestHeader(). According to the W3C docs, in giant bold green type:
The setRequestHeader() method appends a value if the HTTP header given as argument is already part of the list of request headers.
Rather than appending, it’s overwriting the existing value entirely.
The particular case where I ran into this was when using jQuery to send a remote form request. My setup code includes the following line.
When firing off an Ajax remote form request with Safari or older (pre-3.5) versions of Firefox, the header would contain the following.
With Firefox 3.5.2 I see this instead.
And the HTTP error returned from the server.
406 Not Acceptable
The workaround is simple.
I have to set that header parameter with all of the types that should be accepted as a response to a remote form request.
The downside to this is that non-broken browsers almost defintely include duplicate values, but at least it still works.
Ex.: Safari with the workaround in place.