Jan 5, 2001, 11:53 AM
I've written a script for an internal project that allows my users to post HTML pages they've created to our site here, at work.
Uploading Associated Files
My problem is that the people I'm dealing with aren't exactly Compuer savvy... In fact, they're generating their pages via MS Word 97.
My script takes their .html file, converts it using a template, and strips out the bad MS HTML, replacing it with clean code... That all works wonderfully. The problem occurs when the user decides to put pictures in their page.
I've been able to parse the code, and get the filenames, and disk location of all of their images, and present them with an upload form with an input type="file" box... Once again, it all works great...
The problem is, one cannot initialize, or default the value of the input type="file" tag. I would like to make this upload of extra files as transparent to the users as possible, so I figured I would just input the value with the script, letting them know that I needed x number of images, and give them an "OK" button or something... Well, since the value attribute doesn't work, I can't exactly do that...
My question is this: Is there any way to get those files onto the web server without making my users have to remember the names of all their images, and browse their drive to find them? I've seriously thought of just giving them the path to the file to copy and paste it into the input field, but that is extremely hokey...
Any suggestion would be appreciated.