0

我们有一段代码将多个文件上传到服务器,有趣的是,这段代码在 Chrome 和 Mozilla 上运行良好,但在 Internet Explorer 中失败,收到以下错误

XMLHttpRequest:网络错误 0x2ee2,由于错误 00002ee2 无法完成操作

我们尝试了SCRIPT7002 中提到的解决方案:XMLHttpRequest:网络错误 0x2ef3,由于错误 00002ef3 无法完成操作,但仍然遇到类似问题

我们使用以下 本指南更改了 Internet Explorer 的超时值,但它没有用。

我们找出导致问题的代码行

///////////////////////////////////////////////////////////////////////
        // Private Helper for making servlet calls
        _servercall: function(urlStr, input, isAsync, dataT, ajaxcallback) {
            // Using the core $.ajax method
            $.ajax({
                // the URL for the request
                url : urlStr,
                async : isAsync,
                // the data to send (will be converted to a query string)
                data : input,
                // whether this is a POST or GET request
                type : "GET",
                // the type of data we expect back
                dataType : dataT,
                // code to run if the request succeeds;
                // the response is passed to the function
                success : function(json) {
                    console.log("Server call - Success");
                    ajaxcallback(json);
                },
                // code to run if the request fails; the raw request and
                // status codes are passed to the function
                // This needs to be better handled, more graceful error, ToDo
                error : function(xhr, status) {
                    console.log("Server call - error. Status " + status);
                    JCAAlert("com.ptc.windchill.enterprise.attachments.attachmentsResource.DO_APPLET_UPLOAD_ERROR");
                    this.cleanupUploadFields(this.wizardStep, null);
                },
                // code to run regardless of success or failure
                complete : function(xhr, status) {
                    console.log("The request is complete! Status " + status);
                }
            });
        },

此代码在 IE 上的文件号 12 之前工作正常,但是一旦我们选择超过 12 个文件,它就会失败并出现上述错误?

这是ajax限制还是什么?

查看错误快照

4

1 回答 1

3

它现在正在工作。

我跟着下面的文章

https://comm.support.ca.com/kb/why-cant-i-open-more-than-6-proxy-sessions-in-internet-explorer-11/kb000012203

I 将每台服务器的最大连接数 (HTTP 1.0) 增加到 50

然后

将每台主机的最大连接数 (HTTP1.1) 更改为 50

&

将每台服务器的最大 webscoket 连接数设置为 50

它工作正常,我可以上传文件。

谢谢你的帮助。

于 2019-03-27T11:58:15.790 回答