0

This is what i am trying to acchomplish, i have created an iframe, within my iframe i have input a src to a PHP file. when the php file opens up within the iframe it has a choose file input dialog. I have created a button seperate from the iframe in which i would like to use to open up input dialog. here is example below:

<iframe name="iframe001"id="iframe001" src="%%%myvalue1%%%" width="480px" height="500px"scrolling="no" ></iframe>

here is the php file(Form portion) that i open

<form action="NewResizeUpload.php" method="post" enctype="multipart/form-data">
<img src="" id="image">
<input type="file" input id="input" name="image" onchange="handleFiles()" />
<button>Upload</button>

The question is how do i call for the open choose file dialog this is what i am currently using but does not work when i load php file into iframe

function ChooseFile(){
document.getElementById('input').click();
INOH
  • 365
  • 2
  • 9
  • 27
  • 1
    What's your question about this? – Barmar Aug 24 '16 at 18:06
  • 1
    Please [edit] your question to be on-topic: Questions seeking debugging help ("**why isn't this code working?**") must include: ►the desired behavior, ►a specific problem or error *and* ►the shortest code necessary to reproduce it **in the question itself**. Questions without a clear problem statement are not useful to other readers. See: "**How to create a [mcve]**", [What topics can I ask about here?](http://stackoverflow.com/help/on-topic), and [ask]. – Makyen Aug 24 '16 at 18:09
  • sorry edited question above – INOH Aug 24 '16 at 18:13
  • thanks for the info. – INOH Aug 24 '16 at 18:51

0 Answers0