文档归类:服务器
nginx上加好Access-Control-Allow-Origin头部,跨域依旧失败的问题nginx文档也已说明,只需要在指令后面加上“always”参数即可add_header Access-Control-Allow-Origin * always;
add_header Access-Control-Allow-Methods 'GET, POST, OPTIONS';
add_header Access-Control-Allow-Headers 'DNT,X-Mx-ReqToken,Keep-Alive,
User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Authorization,Range' always;...
我只是想看完而已»