1
0
mirror of https://git.teknik.io/Teknikode/Teknik.git synced 2023-08-02 14:16:22 +02:00

Added X-Requested-With header to ajax calls.

This commit is contained in:
Uncled1023 2016-10-26 17:44:51 -07:00
parent 446df72e00
commit e8eea8404e
2 changed files with 3 additions and 1 deletions

View File

@ -15,6 +15,7 @@
type: "POST",
url: form.attr('action'),
data: form.serialize(),
headers: {'X-Requested-With': 'XMLHttpRequest'},
xhrFields: {
withCredentials: true
},
@ -45,6 +46,7 @@
type: "POST",
url: form.attr('action'),
data: form.serialize(),
headers: {'X-Requested-With': 'XMLHttpRequest'},
xhrFields: {
withCredentials: true
},

View File

@ -64,7 +64,7 @@
<customHeaders>
<add name="Access-Control-Allow-Credentials" value="true" />
<add name="Access-Control-Allow-Methods" value="GET, PUT, POST, DELETE, OPTIONS" />
<add name="Access-Control-Allow-Headers" value="Accept, Content-Type" />
<add name="Access-Control-Allow-Headers" value="Accept, Content-Type, X-Requested-With" />
<add name="strict-transport-security" value="max-age=31536000; includeSubdomains" />
</customHeaders>
</httpProtocol>