1

I am making a plugin which allows user to upload images, Here is a brief summary of how it works.

It uses an <input type="file" name="images[]" multiple> and then I use jQuery in which I handle the 'change' event, so that when user has selected images in the dialog. They show up in a div on my page in the form of thumbnails.

What I am trying to do is I want to give user the ability to remove images that they didn't mean to select.

At first I tried using single file select elements and when user would select a file, a new file select element would show up. That way I was just able to remove that element. But there was a limitation of being able to select just one file.

So here's what I want to know: how can I use multiple file select elements, and still be able to remove specific files once the user has selected them? I wish to do this all on the client side.

0

1 Answer 1

0

Use this plugin :

http://www.jqueryrain.com/?bnUGGtpn

After you have selected images (more than one) and they and you click Ok the files get selected and show up in thumbnail format.You can then delete the unwanted images.

This can help you.

2
  • Actually I am trying to make my own plugin, and i know I am close.. It is just that when you put that 'multiple' attribute to your input element... It turns it into a completely different thing.. Commented Aug 22, 2014 at 15:12
  • found a way without using the plugin?
    – cs04iz1
    Commented Aug 26, 2015 at 9:38

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.