我已关注this guide on MDN。
var formData = new FormData();
formData.append("username", "Groucho");
formData.append("accountnum", 123456);
console.log(formData);
为什么formData
为空?
答案 0 :(得分:10)
他们可以访问FormData
var formData = new FormData();
formData.append("username", "Groucho");
formData.append("accountnum", 123456);
console.log(formData.get("username"));
console.log(formData.get("accountnum"));