Create a web service on http://www.a.com/service.asmx and send a cross-domain ajax request to it from http://www.b.com. Check the headers in Firebug, or in Live HTTP Headers, or any other plugin you wish.

There is no trace of the X-Requested-With HTTP Header field among request headers.

However, if you send an ajax request to the same service from the same domain (say for example http://www.a.com/about), you will see that header field.

Why is the X-Requested-With header field omitted for cross-domain ajax requests?

Update: I know that JSONP calls are not AJAX calls in nature. Thus you won't see any X-Requested-With header field, in JSONP calls.

Edit
Report