使用IFrame或者Frameset都可以监视是否文件已经传输到客户端了。
var obj_IFrame = document.getElementById("detail");
obj_IFrame.onreadystatechange = function() {
if (obj_IFrame.readyState && (obj_IFrame.readyState == 'interactive' || obj_IFrame.readyState == 'complete') && obj_IFrame.src != "about:blank") {
endRequest();
}
};