简体   繁体   English

边缘浏览器XMLHttpRequest中止不起作用

[英]Edge browser XMLHttpRequest abort is not working

var xhr = new XMLHttpRequest();
var method = "GET";
var url = "https://developer.mozilla.org/";
xhr.open(method,url,true);
xhr.send();
xhr.abort();

When i run this code in Microsoft edge browser xhr call abort is not working. 当我在Microsoft Edge浏览器中运行此代码时, xhr调用中止不起作用。 I test this code in Chrome and Mozilla, its working fine. 我在Chrome和Mozilla中测试了此代码,可以正常工作。

I faced this same issue, this is a bug in Edge. 我遇到了同样的问题,这是Edge中的错误。 https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/14673124/ https://developer.microsoft.com/zh-cn/microsoft-edge/platform/issues/14673124/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM