Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Opening a file upload box when an image is clicked

Status
Not open for further replies.

POPDUM

Programmer
Feb 8, 2008
8
AT
Hi,

I am relatively new to Javascript, but I think it is possible to do the following, but I don't know exactly how.

I have a screen with 10 images in screen A. When the user clicks an image, a file upload box needs to pop up (screen B) where the user can change the image (<input type="file"). Once they click "Upload", the upload proceeds, and when it is done, the image is uploaded or an error message displayed in the parent screen (screen A) with the 10 images and screen B disappears.

I seem to think that using iFrames might be a solution. Is that true or is there a better way?

Any help will be greatly appreciated!
 
you can fire the "click" event on the INPUT to open the file-upload. and "onchange" to go futher when file is selected.

- Lowet

[gray]Why can't all browsers parse pages the same way? It should be the Web designer who decides how to display the content, not the browser![/gray]
 
Thanks Lowet for the info, as it was very useful.

I however have another problem, but I will post it in a different thread
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top