First I would like to say thank you to everyone who contributes to this forum! I have learned so much in the short time I have been using this product by searching/reading your questions/replies.
Unfortunately, I am unable to find an answer to the recent problem I am having trying to create a form to upload a single ZIP file and then unzip it. Prior to using Scriptcase I was using CodeCharge Studio which basically allowed me to upload/save the ZIP file to a temp directory of my choice and allowed me to to write a PHP based script and call it in the “afterprocessfile” event which did the unzipping, writing the files to a directory/sub-directory structure and insert each file’s name/path into a MySQL table. Unfortunately, each ZIP file has, at a minimum, one folder with files in it, let’s call it folder “A”. Most of the time the ZIP file has two folders in it, folder “A” and folder"B". Files that are in folder “B” need to be referenced to the corresponding files in folder “A” using their filenames. This is where the PHP script comes into play.
I think I can re-purpose my PHP based script to handle the unzipping of the file, etc. but I haven’t been able to figure out how to use the Multi-Upload/database(filename) fieldtype in a form to allow my client to upload a file without saving the ZIP file to a table. After selecting/DragnDrop a file you must click the upload button to upload it to the temp directory defined in my project but that is as far as I want to go. I don’t want to have to click on the submit button to exit the application because it wants to insert the file and/or the binaryvalue into a table. I want to be able to run my unzip script once the upload to the temp file is completed and then re-direct to a “Upload Successful” or “Upload Failed” page based on the return value in my script.
If anyone has any thoughts, ideas or possible solutions, I would greatly appreciate a reply.
Thanks!