2amigos/yiiwheels-docs — pull request #10 by bartaakos (2014-07-22 11:47:47+00:00)
Title: renderJson use text/plain if application/json is not available

We use jQueryFileUpload in a project where we faced a problem in connection with headers.
Basicly this plugin in IE and Opera uses iframe solution for file uploads. The problem is that these browsers don't support application/json and require text/json for response.

https://github.com/blueimp/jQuery-File-Upload/wiki/Setup#content-type-negotiation

The solution is simply just checking whether we can send application/json header or not.