本机开发运行时http://127.0.0.1 不在以下 request 合法域名列表中问题

文章正文
发布时间:2025-11-13 06:13

wx.request({ url: 'http://127.0.0.1/weixinService/OrderServlet', data: { x: '', y: '' }, header: { 'content-type': 'application/json' // 默认值 }, success: function (res) { console.log(res.data) } }) 我在开发环境,本机电脑上,weixinService服务也是部署在本机电脑上,本机运行小程序时,抛异常提示