I'm trying to make a simple JSON POST with custom header like this :
$.ajax({
type: 'POST',
url: 'http://oe.com/social/identity/auth/bydeviceid/AZERTYD',
dataType: 'json',
success: function(data) {
alert('success');
}
});
I receive the following error:
No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'null' is therefore not allowed access.
I've also noticed that my code is sending a OPTIONS
request and not POST even I mentioned a POST
request. How do I solve this?