0
我想创建一个文件输入形式的对象形式,我怎么能做到这一点 。如何创建文件输入的表单对象javascript中的对象形式
<html>
<head>
<script src="https://code.jquery.com/jquery-1.10.2.js"></script>
</head>
<body>
<form id="helooo">
<input type="text" name="foo1" value="" />
<input type="text" name="foo2" value="" id="r1"/>
<input type="file" name="f1" value="" id="r2"/>
<button type="submit" id="s1"> ab</button>
</form>
<script>
$(".quote_save").click(function() {
var oElements = {};
$('form'){
oElements[this.name] = = this.value;
});
});
</script>
</body>
</html>
乳清你复制我的答案吗? –
你的回答和我的回答之间有很大的区别 – lalithkumar
是的,只要你编辑... –