title: How to display this message within the correct row, not within all rows
body: <p>Below is the code where it is displaying the delete message but it is displaying it in each row, this is incorrect, it should on;y be displayed in the row the file was deleted from:</p>
  
  <pre><code>   var counter = 0;
  
  function stopImageUpload(success, imagefilename){
  
        var result = '';
        counter++;
  
        if (success == 1){
           result = '&lt;span class="imagemsg'+counter+'"&gt;The file was uploaded successfully!&lt;/span&gt;&lt;br/&gt;&lt;br/&gt;';      
           $('.listImage').eq(window.lastUploadImageIndex).append('&lt;div&gt;' + htmlEncode(imagefilename) + '&lt;button type="button" class="deletefileimage" image_file_name="' + imagefilename + '"&gt;Remove&lt;/button&gt;&lt;br/&gt;&lt;hr/&gt;&lt;/div&gt;'); 
        }
        else {
           result = '&lt;span class="imageemsg"&gt;There was an error during file upload!&lt;/span&gt;&lt;br/&gt;&lt;br/&gt;';
        }
  
  
        $(".deletefileimage").on("click", function(event) {
  
           var image_file_name = $(this).attr('image_file_name');
  
      jQuery.ajax("deleteimage.php?imagefilename=" + image_file_name)
        .done(function(data) {
          $(".imagemsg" + counter).html(data);
         });
  
         $(this).parent().remove();
  
      });
  
        return true;   
  }
  </code></pre>
  
  <p>The result variable is called here in the imageupload.php:</p>
  
  <p>CALLBACK:</p>
  
  <pre><code>  &lt;script language="javascript" type="text/javascript"&gt;window.top.stopImageUpload(&lt;?php echo $result ? 'true' : 'false'; ?&gt;, '&lt;?php echo $_FILES['fileImage']['name'] ?&gt;');&lt;/script&gt;
  </code></pre>
  
  <p>Here is the link to the application <a href="https://helios.hud.ac.uk/u0867587/Mobile_app/QandATable3.php" rel="nofollow">here</a>.</p>
  
  <p>Please do this, click on the "Add" button twice, in both rows use the file inputs to upload an image. In both rows it will state that file upload was a success and it will display a name of both file at the bottom of their respective rows. Now delete a file by clicking on the delete button, you will see that the message (File was Deleted) is displayed in both rows, it should only be displayed within the row the file was deleted from</p>