You are here: Reference > HTML > attributes > MULTIPLE (input:file)

MULTIPLE attribute (input:file)

Browser support:
3.6
Sets whether more than one file can be selected with the current input:file element.
Note: The MULTIPLE attribute is supported in Firefox from version 3.6.
By default, the input:file element only supports single file selection, so only one file can be uploaded with one input:file control at a time. With the MULTIPLE attribute you can allow users to upload more than one file with one input:file control during a form submission. To select multiple files, hold down the CTRL or SHIFT key while selecting.
JavaScript page for this attribute: multiple. You can find other example(s) there.

Possible values:

This attribute has no values.
Specifying the MULTIPLE attribute with an arbitrary value has the same effect as specifying it with no value.
For example, all of the following declarations have the same effect: multiple, multiple="true", multiple="false", multiple="on", multiple="multiple".
Although Boolean attributes may be used with no value in HTML, for XHTML compatibility, always use the MULTIPLE attribute in the following format: multiple="multiple".

Example HTML code 1:

This example illustrates the use of the MULTIPLE attribute:
<form method="post" enctype="multipart/form-data" action="#URL#">
    Select one or more files to upload: <input type="file" name="uploadFile" size="60" multiple="multiple" />
    <br />
    To select multiple files, hold down the CTRL or SHIFT key while selecting.
    <br /><br />
    <input type="submit" value="Upload" />
</form>
Did you find this example helpful? yes no

Supported by tags:

Related pages:

External links:

User Contributed Comments

Post Content

Post Content