FileUpload.form

JavaScript 1.0+, Jscript 3.0+ Nav2+, IE4+, Opera3+ Syntax

							fileupload.form

Description

The form property of the FileUpload object is used to reference the form object that contains the FileUpload box.

Example

Listing 7.243 shows an example of how the form property can be used to extract any attributes of the form containing the FileUpload box. The page contains two boxes in which a file can be specified to be uploaded. The checkFiles() function verifies whether a file has been chosen for each upload box. If a file hasn't been chosen, the script will alert the user.

Listing 7.243 Using the FileUpload form Property
 <html> <head> <title>Using FileUpload form property</title> </head> <body> <script language="JavaScript"> ...

Get Pure JavaScript now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.