harttle.github.io icon indicating copy to clipboard operation
harttle.github.io copied to clipboard

2016/12/28/cors-with-cookie

Open harttle opened this issue 6 years ago • 4 comments

CORS 跨域发送 Cookie | Harttle Land

http://harttle.land/2016/12/28/cors-with-cookie.html

harttle avatar May 02 '18 18:05 harttle

感谢博主分享,请问在Safari上怎么从代码层或网络配置以实现cookie发送到服务端?

By Johnathon 2018-01-11T05:54:12Z

harttle avatar May 03 '18 01:05 harttle

在正常模式下浏览器会自己携带cookie,是否携带网站代码无法干涉

By Yang Jun 2018-02-08T09:40:24Z

harttle avatar May 03 '18 01:05 harttle

今天面试被问到这个了,赶紧来补补

By Nick 2018-03-23T08:21:22Z

harttle avatar May 03 '18 01:05 harttle

感谢提供这么好的Blog和Code. 我试了下,其它都是OK的,只有带Cookie的那个例子不行. 返回:I got your cookie: undefined 我看了下server.js, 似乎是: res.status(200).end('I got your cookie: ' + req.headers.cookie);
没有获取到cookie,然后看chrome的控制台,确实没有带cookie. Chrome是最新的Version 66.0.3359.139 (Official Build) (64-bit) 非常不理解哪里不对, 希望您能帮忙看看,谢谢!

linkerlin avatar May 03 '18 15:05 linkerlin