nginx解决跨域问题,配置

跨域请求:

在被请求项目的nginx配置文件中添加如下配置:

add_header Access-Control-Allow-Credentials true;
add_header Access-Control-Allow-Origin $http_origin;

猜你喜欢

转载自blog.csdn.net/hechenhongbo/article/details/112495879