Hey All,
Among a complex series of forms which together comprise an industry standard report,
I have a file 'NotesPhotos.php' containing a hidden iframe
<iframe name="I1" id="I1" src="uploadPhotos.php" style="visibility:hidden; height:120px; width: 265px;"></iframe>
And what is basically a Two Column Three Row table wherein each cell contains a defalut.gif image.(no_photo.gif).
OnClick -ing, an individual cell in the table, the Iframe is dynamically positioned adjacent to the referring cell and displayed (un-hidden) , while the cell.id/name is passed to a form within the iframe
<form name="photo_upload_form" id="photo_upload_form" method="POST" action="SavePhoto.php" enctype="multipart/form-data" >
Whereupon... a third file -- 'SavePhoto.php' -- then...
1. Creates a unique directory (if not exists) named for the form's record.id,
2. Re-Sizes the uploaded image (maintaining aspect ratio),
3. Writes the Re-Sized Uploaded Image to the unique directory folder for the record
and finally...
4. Sets the img.src of the referring cell in NotesPhotos.php to the newly uploaded and resized image.
In this way, I am able to upload/resize and insert up to 6 images per NotesPhotos form page (with maximum of two NotesPhotos pages per report and a maximum possible total of 12 photos per report)
All in All, this works reasonably well EXCEPT for the fact that uploading the photos to the server is REALLY SLOW from a mobile broadband connection.
Looking for an alternative, I found 'Rad Upload' a java applet that promises the ability to upload an entire directory in one fell swoop (in which case our users could pre-load their images prior to beginning their report),
And/Or the ability to Re-Size the images PRIOR TO UPLOADING which would -hopefully- diminish the time/per image upload.
The trouble I am having with this approach is figuring out how to pre-view(browse) and or select the individual java-applet-uploaded images (now on the server) into our NotesPhotos.php form page as before.
Please, any suggestions would be greatly appreciated.