首先,jsp的form要这样声明
js: var aa = document.getByElementId("a").Value
通过JQuery:$('input[type="file"]').attr('name');$('input[type="file"]').val();
取不到,因为file是文件流。你可以使用,用js把type="file"里面的地址赋值给hidden,然后再取。