php程序出现接口访问跨域的解决办法
我们通常在进行接口调用时,会出现报错: Access to XMLHttpRequest at ‘http:/xxxxxxxxxx from origin ‘http://xxxxxxxxxx’ has been blocked by CORS policy: No ‘Access-Control-Allow-Origin’ header is present on the requested resource. 这种错误就是表示出现了跨域。那么什么是跨域访问呢? 就是不同域名,端口之间相互调用数据,会出







