$( "#fileUpload" ).click( function (){ |
var file=$( "#file" ); |
if ($.trim(file.val())== '' ){ |
alert( "请选择文件" ); |
return false ; |
} |
document.forms[0].submit(); |
}); |