2
这里是到目前为止生成的html(使用GWT
作为前端),到目前为止我已经复制了GWT FileUpload类。在上传文件时处理网络问题
<input type="file" id="input" onchange="handleFiles(this.file)">
工作正常的HandleFileUploadServet.java
帮助,因为Java作为后端。
要处理,使用addSubmitCompleteHandler
form.addSubmitCompleteHandler(new SubmitCompleteHandler() {..
即相当于
.submit(function(){
//handle file response
})
工作正常。
这是问题,上传文件时如果网络断开,浏览器抛出没有error/exception/response
。
我想通知用户,存在网络问题。
但浏览器不断提交表单而不是从该状态返回。
任何提示?
谢谢你的时间。