javascript - Cross Domain Request in IE -


i have cross domain js request working firefox , chrome not ie have found following code (just beggining time saving)

jquery.ajaxtransport('text html xml json', function(options, useroptions, jqxhr){.... 

that adds transport ie, , works fine

the problem have xdomainrequest object doesn't allow me change content type, it's being sent plain/text , need application/json

i'm using java jersey rest container, there way can intercept calls in plain/text content-type , switch application/json ?

or other thoughs on how might work

thanks in advance

here resource

@post @path("/register") @produces(mediatype.application_json) @consumes(mediatype.application_json) public statusresult register(userregistrationrequest urr) {     //calls controller register producer, , returns result     statusresult result = usercontroller.register(urr);     return result; } 

i tried adding consumes mediatype.plain_text, doesn't work

i can see server being called, errors regarding enconding type not supported (or not being able transform)


Comments

Popular posts from this blog

c++ - Function signature as a function template parameter -

algorithm - What are some ways to combine a number of (potentially incompatible) sorted sub-sets of a total set into a (partial) ordering of the total set? -

How to call a javascript function after the page loads with a chrome extension? -