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!

Generate dynamic filepath to File field

Status
Not open for further replies.

GoSooJJ

Programmer
Feb 24, 2001
76
US
Assume that I have 20 images with sequence number like "happy_1.jpg" to "happy_20.jpg" then I need to upload all 20 images to server. However I don't like to click 20 times to enter the images into File field. Is there anyway that I can generate them in javascript and fill into the each File fields? If this is not possible then can it be done from server side? I have research for whole day but no luck. Thank you.
 
Hmmm, just stop and think about what you are saying.
"I want javascript to automatically upload files from my local hard disk to my server"
If that were possible then next time you visit some dodgy site the entire content of "my documents" is uploaded to that server, how would you like that?

The above is just to try and explain to you why such a thing is not possible.

To make such a multi file uploader you might use java applet or active x. With such a control you might drag and drop an entire folder on the applet for uploading.
There might be one already available, look for upload applet.



Greetings, Harm Meijer
 
Thank you for your reply Harm. I understand now. It's security reason that you can not copy to File type field. Looks like there's no short-cut.
 
There is one solution that I was recently involved with implementing... SWFUpload. It's a flash multi-file upload "thingy" that is open source.

Check out the demos at least:


Personally I implemented the 6.2 version - since the 7.0 betas were, um, beta.

Cheers,
Jeff

[tt]Jeff's Blog [!]@[/!] CodeRambler
[/tt]

Make sure your web page and css validates properly against the doctype you have chosen - before you attempt to debug a problem!

FAQ216-6094
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top