I am using something like this to get an image via jquery ajax.
$.ajax({
url: imageurl,
type:'GET',
contentType: 'image/png',
success: success,
error: error,
timeout: 5000
});
I can see that my request headers include
Access-Control-Request-Headers:origin, content-type, accept
On the other hand, If i set up a img element like
<img src="imageurl" ...
and observe the request headers I don't see any "Access Control Request Headers".
Just wondering what is the reason for $.ajax() adding this header. Why is it adding this for a images which should be a valid Cross-site HTTP request. Will it be a good practice or even possible to remove this header?