[英]Error in Chrome only: XMLHttpRequest failed to load resource
I am running a WebApi and a WebClient application under IIS express (localhost) and receive this error only when I run them under Chrome. 我在IIS express(localhost)下运行WebApi和WebClient应用程序,并且仅当我在Chrome下运行它们时才收到此错误。 It works fine under IE. 在IE下工作正常。
At this point I am attempting to just log in a user and I receive two error messages that I am not sure what they mean - 在这一点上,我尝试仅登录用户,并且收到两条错误消息,我不确定它们是什么意思-
Failed to load resource: http://localhost:59822/api/accounts/login the server responded with a status of 401 (Unauthorized) 无法加载资源: http:// localhost:59822 / api / accounts / login服务器以401(未授权)状态响应
XMLHttpRequest cannot load http://localhost:59822/api/accounts/login . XMLHttpRequest无法加载http:// localhost:59822 / api / accounts / login 。 Invalid HTTP status code 401 无效的HTTP状态代码401
This most likely happens due to the security settings in Chrome. 这很可能是由于Chrome中的安全设置所致。
By default the same-origin policy is rigorously enforced. 默认情况下,严格执行同源策略 。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.