SOME TIMES there is no X-Requested-With header, sometimes there is.
I checked in firebug and found that, don\'t know why.
So when I use requ
Provide more information. What kind of ajax requests are you making?
If you are submitting forms which contain an input field of type file that is most likely the reason that the header is missing.
As you can't submit a file with ajax, all the javascript frameworks use the "hidden iframe" trick internally to get the work done for you.
Check this post with a similar problem and my answer to it.
X-Requested-With header not set in jquery ajaxForm plugin
Otherwise there should be no reason for such a behavior from jQuery as it always sets the header. If the issue isn't related to file-inputs please post relevant codesnippets
from jQuery Source
xhr.setRequestHeader("X-Requested-With", "XMLHttpRequest");