AJAX request in jQuery. How to get rid of the header Access-Control-Request-Headers?


Warning: count(): Parameter must be an array or an object that implements Countable in /home/styllloz/code-flow.club/qa-theme/donut-theme/qa-donut-layer.php on line 274
0 like 0 dislike
5 views
Hello. Should be using JavaScript to pull data from an xml file generated on a remote server. All that could think of is to make an ajax request to the xml file.
But jQuery instead of GET-request sends an OPTIONS request.
It turned out that this request is being sent Firefox'ohms in the case of cross-domain request, when sent non-standard headers. In the case of jQuery it seems:
Access-Control-Request-Headers: x-requested-with

How to get rid of this header? Or maybe there are other ways to extract information from xml?
by | 5 views

3 Answers

0 like 0 dislike
It's such a security policy cross domain AJAX like crossdomain.xml in flash, the remote server need to allow it to use. If it is possible, then the theory — metajack.im/2010/01/19/crossdomain-ajax-for-xmpp-http-binding-made-easy/, is there a working way blog.dgorbunov.ru/2009/05/jquery-mochiweb-options.html
by
0 like 0 dislike
You can configure nginx in the native script the server so that it unloaded some remote xml request /getxml?params.
by
0 like 0 dislike
by

Related questions

0 like 0 dislike
2 answers
0 like 0 dislike
2 answers
0 like 0 dislike
1 answer
0 like 0 dislike
2 answers
110,608 questions
257,186 answers
0 comments
23,008 users