Javascript Reference
Categories: InputTypeFile

javascript InputTypeFile defaultValue

@March 15, 2008, 1:22 a.m.
defaultValueFirefox/Netscape/NN 4 IE 4 Chrome/Safari/DOM n/a  

Read/Write  

Returns the string assigned to the value attribute of the element in the source code (except in IE for Windows, which returns an empty string). A user must manually select a file for uploading, so pre-setting or attempting to alter this value is a waste of time.

 
Example
 
var initVal = document.entryForm.myFileUpload.defaultValue;
 
Value

String.

 
Default

None.


Powered by Linode.