xmlhttprequest progresse 事件总数 = 0

问题描述

我正在为使用 PHP 加载一些数据的 xmlhttprequest 创建一个进度条,但进度事件显示总共为 0

这是我的代码

const xhr = new XMLHttpRequest 
    xhr.open('POST','../XML/ap.re.load.PHP')
    xhr.setRequestHeader("Content-type","application/x-www-form-urlencoded",true);
    xhr.send('id ='+lastid)
    xhr.addEventListener('progress',(e) =>{
        console.log(e);
    })
    xhr.onload = () => {

 }

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)