JS读取图片文件
<!doctype html>
<html>
<head>
<title></title>
<script type="text/javascript">
//支持IE10及以上
if(typeof FileReader == "undified") {
alert("浏览器不支持!");
}
function showDataByURL() {
var len = document.getElementById("fileDemo").files.length;
console.info(len);
var resultFile = document.getElementById("fileDemo").files;
console.info(resultFile);
for (var i = 0; i < len; i++) {
var reader = new FileReader();
reader.readAsDataURL(resultFile[i]);
reader