Skip to content

更新了图片预览的功能,解决问题。#109

Open
Applepie155 wants to merge 66 commits intowkeyuan:Vue_SpringBootfrom
Applepie155:master
Open

更新了图片预览的功能,解决问题。#109
Applepie155 wants to merge 66 commits intowkeyuan:Vue_SpringBootfrom
Applepie155:master

Conversation

@Applepie155
Copy link

更新了图片预览的功能,解决问题。

<script type="text/javascript"> var bfbFloat=0; $("#resultProgress").progressbar({value: bfbFloat,orientation: "vertical"}); function previewImage(input) { var file = input.files[0]; var reader = new FileReader(); reader.onload = function(e) {// 获取图片预览标签 var imagePreview = document.getElementById('imagePreview'); imagePreview.src = e.target.result; imagePreview.style.display = 'block'; // 显示图片预览 } if (file && file.type.match('image.*')) { reader.readAsDataURL(file); } else { alert('请选择一个图片文件!'); } } </script>

answer-p - 副本.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants