Hi Jason,
Thanks for the form action, i've put it in place and then tried to upload replacement images but it still deletes all the cropped photos rather then the one that is relevant to the new uploading file field that is being submitted.
I've been racking my brain all morning and have finally found a solution that works.
This looks at the submitted form, checks the file filed to see if it's empty, if it is nothing happens, if it isn't it deletes a specific file from the server.
Here is the code I used just in case anyone else needs a solution.
<?php
$WA_DeleteFileResult1 = false;
if(isset($_POST["submit_x"])){
if (!empty($_FILES['new_img1']['name'])) {
//Delete Cropped Image
$WA_DeleteFileResult1 = WA_FileAssist_DeleteFile("../../assets/uploads/events/images/", "".$row_DLA_Event['ID'] ."img1-cropped.jpg");
}}
?>
Now all of the 12 file upload boxes will upload new images and delete a specific file from the server per filed (12 uploads, 12 files deleted) all on the fly.
Thanks for your help.
Lee