You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 3, 2020. It is now read-only.
However, when I run the same JavaScript from within Chrome, Firefox, or Safari, none of them add a Content-Type.
I know that POST requests should usually have a Content-Type. However, when a POST request has no body, it doesn't need a Content-Type. In my case I am using a header to better support browsers that can't handle DELETE requests. It is normal for a DELETE request to have no body (and thus no Content-Type).
Unfortunately it has been too long since I opened the issue to remember exactly why I cared about this enough to write it up. I tried looking back through the old code, but I can't give you a firm answer. I suspect it had to do with Ruby on Rails executing slightly different controller code. It may also have been causing some issues with Rack Lint.
Since nobody else has commented on this issue in the last year, you might as well close it.
This seems related to #260
When I make ajax requests with jQuery via capybara-webkit, something is setting the content type to
application/json, text/javascript, */*; q=0.01
.The following is an example of an AJAX request gets that Content-Type.
However, when I run the same JavaScript from within Chrome, Firefox, or Safari, none of them add a Content-Type.
I know that POST requests should usually have a Content-Type. However, when a POST request has no body, it doesn't need a Content-Type. In my case I am using a header to better support browsers that can't handle DELETE requests. It is normal for a DELETE request to have no body (and thus no Content-Type).
It looks like the latest from Qt seems to insist on a Content-Type too: https://qt.gitorious.org/qt/qtbase/source/70accc289a077b2d05250676ed33369eeaa7df49:src/network/access/qhttpnetworkrequest.cpp#L162
However that code doesn't explain the Content-Type I am seeing.
The text was updated successfully, but these errors were encountered: