Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

HTML DOM FileUpload disabled property

FileUpload disabled property

FileUpload Object Reference FileUpload Object


Example

Example 1

Disable the FileUpload button:

Output result:

Try it »


Definition and Usage

The disabled property can set or return whether the file upload button is available.

A disabled input element is neither available nor clickable. You can set the disabled property until some other condition is met (such as selecting a checkbox, etc.). Then, you need to use JavaScript to remove the disabled value and switch the input element back to available.

Syntax

Set the disabled attribute:

element

.disabled=true|false

Return the disabled attribute:

element

.disabled


Browser support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the disabled attribute


FileUpload Object Reference FileUpload Object