Skip to content
This repository was archived by the owner on Dec 1, 2023. It is now read-only.

credentials bug on IOS7 #348

Closed
Rockergmail opened this issue Aug 4, 2016 · 4 comments
Closed

credentials bug on IOS7 #348

Rockergmail opened this issue Aug 4, 2016 · 4 comments

Comments

@Rockergmail
Copy link

when using credentials on IOS7.0.4, http will add headers below:
Access-Control-Request-Method
Access-Control-Request-Headers

due to the reason above, it turns my method to OPTIONS, but I just want to use POST and send cross origin cookie to server.

@Rockergmail
Copy link
Author

I test credentials option with jQuery on IOS7.0.4, it is OK

@lococo--0
Copy link

lococo--0 commented Oct 20, 2016

@Rockergmail conquered? i meet the same problem

@Rockergmail
Copy link
Author

@lococo--0 Firstable, settingVue.http.headers.post={}; in main.js to cover the default header set by author, which will tigger the OPTION method. Secondly, post something like this:
this.$http.post( SERVER_API, { data: "just data" }, { credentials: true, emulateJSON: true } ).then( function (response) { ... }, function (response) { ... } )
Last but not the least, don't forget update the vue-resource to the lastest version.

@lococo--0
Copy link

the OPTIONS method .. em .. puzzled me .. OK .. thx.. i'll try

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants