I\'ve been looking into packaged apps for Firefox OS and I\'m relying on the Simulator since I don\'t have a build of the OS on a device. I\'m having trouble with XHR reque
For Backbone or other Javascript framework using JQuery $.ajax under the hood use:
$.ajaxSetup( {
xhr: function() {return new window.XMLHttpRequest({mozSystem: true});}
});
I don't think that you need to use CORS. My app is working fine in simulator without CORS but fails to call remote REST server if launched on local server.
Be aware that if you forgot to set
dataType: "text"
for some $.ajax calls (for example load html template) you can get XMLDocument as a result while desktop browsers returns string.