Home > Web Front-end > JS Tutorial > File file control, select a file (picture, flash, video) to preview and display immediately_form special effects

File file control, select a file (picture, flash, video) to preview and display immediately_form special effects

WBOY
Release: 2016-05-16 18:54:20
Original
1251 people have browsed it

We usually use the file control to upload files. To preview, sometimes the page will be refreshed. As a result, the file control is cleared. Many people ask if they can not clear or reassign the value. This is impossible for security reasons. So how to preview without refreshing? Here I will write down the method I used.
Select page:

Copy code The code is as follows:



Display:
Copy code The code is as follows:

< ;div id="showimg">

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template