讨论数量:
后端是不是不是https,前端是https,后端也必须是。 另外跨域,就是返回header头里加东西 ->withHeader('Access-Control-Allow-Origin', “*” ->withHeader('Access-Control-Allow-Headers', “”) ->withHeader("Access-Control-Max-Age", 7200) ->withHeader("Access-Control-Allow-Credentials", true) ->withHeader("Cache-Control", "no-store") ->withHeader('Access-Control-Allow-Methods', 'GET,POST,OPTIONS');
推荐文章: