console.log(typeof(res.header['Set-Cooki
发布于 4 年前 作者 wanjing 17411 次浏览 来自 问答

 wx.request({

  url: url,

  method: ‘POST’,

  header: { 

    “Content-Type”: “application/x-www-form-urlencoded”,

    “Cookie”: get(‘Cookie’)

  },

  data: params,

  success: function (res) {

    console.log(typeof(res.header[‘Set-Cookie’]));//在手机上是string,在mac 开发工具上是array

  }

})

1 回复

麻烦提供能复现问题的代码片段https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html),我们定位下问

回到顶部