Check out FormData to delete a record

I have a FormData object:

var form = jQuery("#options section.active form")[0];
var data = new FormData(form);

      

The form is really sequential and I want to replace one of the entries before loading the ajax (the goal is to take out the image and replace it with the same image, but resize and compress), but I don’t know how to find out the key which is used for the image. When I know the key, I would use FormData.delete

and thenFormData.set

If you know a better workaround, I'm pleased too, thanks.

Edit: I want to validate an element in javascript, for example:

Console.log(data);

      

+3


source to share





All Articles