How to Select Multiple Files using HTML Input Tag ? Last Updated : 29 Jul, 2024 Comments Improve Suggest changes Like Article Like Report Using the input tag to upload multiple files has become possible after the release of HTML 5. Since many of us, work on HTML and still use tags such as <input> tag for taking input from the user and <form> tag for using forms on our website, it is necessary to know how to implement multiple files feature using HTML. We can assign 'multiple' attribute with the value of multiple like below: Syntax: <input type="file" id="files" name="files" multiple="multiple">OR <input type="file" id="files" name="files" multiple>Note: We can use just multiple as a property. Well, it is very simple. HTML 5 has a property for input tag which is ‘multiple’. Below example illustrates the above approach:Example: Using this property, you can input multiple files. For selecting files, you must use either CTRL or SHIFT and select the number of files to be uploaded. html <!DOCTYPE html> <html> <head> <title> Select multiple files using HTML Input tag </title> <style> h1 { color: green; } .container { text-align: center; width: 850px; margin: 35px; } .property { width: 400px ; float: left; border: 2px solid black; padding: 10px; } .attribute { width: 400px ; float: right; border: 2px solid black; padding: 10px; } </style> </head> <body> <div class="container"> <h1>GeeksforGeeks</h1> <b>A Computer Science Portal for Geeks</b> <br><br> <div class="property"> <p> Input Multiple Files using Input Tag, <b>'multiple property'</b> </p> <form action="/action_page_inputtags_multiplefiles.php"> <label for="files">Select Multiple files:</label> <input type="file" id="files" name="files" multiple> </form> </div> <div class="attribute"> <p> Input Multiple Files using Input Tag, <b>'multiple attribute'</b> </p> <form action="/action_page_inputtags_multiplefiles.php"> <label for="files">Select Multiple files:</label> <input type="file" id="files" name="files" multiple="multiple"> </form> </div> </body> </html> Output: But if you are using HTML 4 or lower versions of HTML than, either you need to use multiple input tags or you may use plugins such as Flash or Silverlight to insert multiple input files. You may also use JavaScript to upload multiple files. However, the use of HTML 4 and lower versions are not encouraged as with HTML 5, many new features have been introduced, as well as the dependency of using third-party plugins for various operations is reduced significantly. By the use of multiple properties of the input tag, you can upload multiple files. Comment More infoAdvertise with us Next Article How to Select Multiple Files using HTML Input Tag ? S SagarBapodara Follow Improve Article Tags : Web Technologies HTML HTML-Questions Similar Reads How to set a value to an input file using HTML? In HTML, we will use the type attribute to take input in a form and when we have to take the file as an input, the file value of the type attribute allows us to define an element for the file uploads. It displays a browse button on our computer screen, and when we click on it, it asks the user for p 2 min read How to specify multiple forms the select field belongs to in HTML ? The task is to specify multiple forms the select field belongs to. In simple wording, we have to find out which form the specific select belongs to. You can achieve this task by using the form attribute. select element - It is used to create a drop-down list in HTML.form element - It is used to crea 2 min read How to specify the type of an input element using HTML ? In this article, we will specify the type of an input element using HTML. The HTML <input> type attribute is used to specify the type of <input> element to display. The default type of <input> type attribute is text. Syntax: <input type="value"> Attribute Values: button: It i 4 min read How to select/deselect multiple options in dropdown using jQuery ? To select and deselect multiple options in a drop-down menu, we will use the HTML and CSS codes. HTML code helps to define the basic structure of the webpage and CSS will benefit in designing the web page. Some essential properties used in the code are as follows- <div> - This is a division ta 4 min read How to select all Text in HTML Text Input when clicked using JavaScript? To select the text in HTML Text Input we can use the JavaScript DOM methods and we will select the text when we click the text box.Using document.getElementById() methodSyntax:<input onClick="this.select();" > or document.getElementById("ID").select();Example 1: We will use "this.select()" in 1 min read HTML DOM Input FileUpload multiple Property The Input FileUpload multiple Property in HTML DOM is used to set or return one or multiple files selected with the file upload button. It contains a Boolean value which is true when the user is allowed to select more than one file. This property is used to reflect the HTML multiple attributes. Synt 2 min read How to create a File Input using jQuery Mobile ? jQuery Mobile is a web based technology used to make responsive content that can be accessed on all smartphones, tablets and desktops. In this article, we will be creating a File Input Area using jQuery Mobile. Approach: Add jQuery Mobile scripts needed for your project. <link rel=âstylesheetâ hr 1 min read HTML DOM Input Text select() Method The DOM Input select() method selects all the text content of a textarea or an input element that contains the text field. Syntax: element.select(); Parameters: This method does not accept any parameters. Example: This example selects the content of the input text field. HTML <!DOCTYPE html> 1 min read HTML | <select> multiple Attribute The HTML <select> multiple Attribute is a Boolean Attribute. It specifies that the user is allowed to select more than one value that presents in <select> element. Syntax: <select multiple> Example: html <html> <body> <center> <h1 style="color:green; font- 1 min read How to Get Multiple Selected Values of Select Box in PHP? Given a list of items, the task is to retrieve the multiple selected values from a select box in PHP. Use multiple attributes in HTML to select multiple values from drop-down list. Selecting multiple values in HTML depends on operating system and browsers. For Windows users: hold down + CTRL key to 2 min read Like