How to create a file upload button with HTML?

HTMLWeb DevelopmentFront End Technology

To how to create a file upload button with HTML, the code is as follows −

Example

 Live Demo

<!DOCTYPE html>
<html>
<head>
<h1>File upload button example</h1>
<p>Click on the "Choose File" button to upload a file:</p>
<form>
<input type="file" id="FILE" name="filename">
</form>
</body>
</html>

Output

The above code will produce the following output −

On clicking the “Choose file” button −

raja
Published on 06-May-2020 17:39:01
Advertisements