I am working on a website where the gallery photos are extremely seasonal related. The site owner would like to be able to replace all images at once instead of first deleting all images and afterwards uploading new ones or the other way arround.
I know how I can delete multiple photos at once using a checkbox with each image and after that loop over the results and delete them from the database, i.e.
foreach ($photos as $photo)
$thumb_file = $thumb_path . $photo['photo'];
$photo_file = $photo_path . $sphoto['photo'];
I am also familiar on how to upload multiple photos at once i.e.
for ($i = 0; $i < count($_FILES['file']['name']); $i++)
...... //rest of function
But I have no idea how to combine these two into one. Every help would be highly appreciated
Thank you in advance