PHP not identifying ajax call
I have a PHP script which is displaying a drop-down box.Now when I select a drop down box an ajax call is made to the PHP script , which works fine , I can see in firebug that the call has been made and correct parameter is passed.I am using this code in php to identify if the call has been made
isset($_SERVER['HTTP_X_REQUESTED_WITH']) &&
($_SERVER['HTTP_X_REQUESTED_WITH'] == 'XMLHttpRequest')
But this check always fails and I do not get any response.Ho开发者_运维百科w can I debug this?
did you check in firebug -net tab - if the header HTTP_X_REQUESTED_WITH is being sent?
精彩评论