【发布时间】:2013-11-12 12:23:52
【问题描述】:
我觉得如果我知道如何调用 xhr.addEventListener (????) 的第一个属性,这可能会起作用,
var string= "I wan't to be sent as an attribute";
var xhr = new XMLHttpRequest()
xhr.addEventListener("load", uploadComplete(????, string), false)
function uploadComplete (evt, attr) {
cosnole.log(attr);
console.log(evt.target.responseText)
}
【问题讨论】:
标签: javascript ajax xmlhttprequest jqxhr