Home Articles FAQs XREF Games Software Instant Books About Feedback Search Site-Map
irt.org logo

Q780 Can you simulate a click on an <input type="file"> button?

irt.org | Knowledge Base | JavaScript | Form 11 | Q780 [ previous next ]

Q780 Can you simulate a click on an <input type="file"> button?

You should be able to simulate a click on any form element using the click() method:

<FORM NAME="myForm">
<INPUT TYPE="file" NAME="myFile">
</FORM>

<SCRIPT LANGUAGE="JavaScript"><!--
document.myForm.myFile.click();
//--></SCRIPT>

Although using Netascape Navigator 4.5 on Linux, the above generates the error message: "Warning: Cannot find callback list in XtCallCallbacks"

Feedback on 'Q780 Can you simulate a click on an <input type="file"> button?'


Provide feedback ...
AddThis Social Bookmark Button

Provide feedback ... AddThis Social Bookmark Button


Last Updated: 6th July 2009. Maintained by: Martin Webb and Michel Plungjan
irt.org liability, trademark, document use, privacy statement and software licensing rules apply.
Copyright © 1996-2009 irt.org, All Rights Reserved.