Has anyone used an app where you can choose multiple selections submit these to a page/script and have them download to the users desktop as a zip file.
Basically, I want to be able to have the user download multiple images from my web page and have them transferred dynamically in a zip file.
To simplify this, I would assume these would be passed to the script in an array. I have no problem with this.
so if the array is:
$myImages = array('one.jpg', 'two.jpg', 'three.jpg');
I would like to be able to pass these to the code below. I am not really sure how I would do this or if it was possible. Obviously the array would have to somehow replace the variable $filename
header("Content-Type: application/zip");
header("Content-Disposition: attachment; filename=$filename");
$f = readfile($filename);
fpassthru($f);
Maybe I am going about this completely wrong. If so I would appreciate any direction or help on this. Thanks for your time