Home  >  Article  >  Web Front-end  >  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
WBOYOriginal
2016-05-16 18:54:201187browse

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">

Statement:
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
Previous article:_javascript tricks thought of by document.body and document.documentElementNext article:_javascript tricks thought of by document.body and document.documentElement

Related articles

See more