Home Articles FAQs XREF Games Software Instant Books BBS About FOLDOC RFCs Feedback Sitemap
irt.Org
#

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

You are here: irt.org | FAQ | JavaScript | Form | Q1742 [ previous next ]

If it were possible, the following would do it. However on Netscape Navigator 4 on Linux this generates the error: "Warning: Cannot find callback list in XtCallCallbacks":

<form name="myForm">
<input type="file" name="myFile">
</form>

<script language="JavaScript"><!--
if (document.myForm.myFile.click) {
  document.myForm.myFile.click();
}
//--></script>

©2018 Martin Webb