Make WordPress Core

Opened 16 years ago

Closed 12 years ago

#7013 closed feature request (fixed)

Multiple image insert via media uploader

Reported by: duncanmc's profile duncanmc Owned by:
Milestone: 3.5 Priority: normal
Severity: normal Version:
Component: Media Keywords:
Focuses: Cc:

Description

There must be an option for inserting multiple images. Sometimes I upload around one hundred of images and want to write comments between them. In order to insert them via panel, I must enter the media manager around one hundered times! Media manager itself is not so fast so it takes a very long time. There must be an option for multiple image insert.

BTW, version 2.7 is too late for adding this option. It must be in 2.6 or maybe in 2.5.2

Attachments (4)

autoclose.diff (1.3 KB) - added by scribu 14 years ago.
almost working
media.php.patch (3.3 KB) - added by ocean90 14 years ago.
the idea
media.php.2.diff (1.4 KB) - added by ocean90 14 years ago.
the idea without bugs
media-bulk-image-uploader.php.zip (3.5 KB) - added by martythornley 12 years ago.

Download all attachments as: .zip

Change History (30)

#1 @duncanmc
16 years ago

  • Milestone changed from 2.7 to 2.6

#2 @ionfish
16 years ago

  • Keywords needs-patch added
  • Priority changed from high to normal
  • Severity changed from major to normal

"It must be" doesn't make things happen, providing patches does.

#3 @duncanmc
16 years ago

  • Milestone changed from 2.9 to 2.8

#4 @ryan
15 years ago

  • Milestone changed from 2.8 to 2.9
  • Resolution set to wontfix
  • Status changed from new to closed
  • Type changed from enhancement to feature request

Unless you can provide a patch for this, this type of functional overhaul will be part of the media features we include in 2.9. 2.8 will be a small release focused on a few specific features wince it only has about 3 weeks development time.

#5 @jacobsantos
15 years ago

  • Milestone 2.9 deleted

#6 @ocean90
14 years ago

  • Component changed from Administration to Media
  • Keywords 2nd-opinion added
  • Milestone set to 3.0
  • Resolution wontfix deleted
  • Status changed from closed to reopened
  • Version 2.5.1 deleted

Maybe we could implement this in 3.0. I think we should give it a try.

We can add a checkbox on the right, if its checked it will close the box. On default its not checked.http://grab.by/2JHq[[BR]]
Maybe we can work with a filter, like #12381.

if ( apply_filters('enable_multiple_images', true) ) {
  $checked = 'checked=""';
else
  $checked = 'checked="checked"';

And then to media_upload_header():

<span class="alignright"><input type="checkbox" <?php $checked;?> /> <label>Auto close</label></span>

#7 @scribu
14 years ago

  • Milestone changed from 3.0 to 3.1

The checkbox idea sounds good, but I think this can wait until 3.1.

It can be added by a plugin, using JavaScript.

@scribu
14 years ago

almost working

#8 @scribu
14 years ago

I think I spoke too soon.

autoclose.diff adds a checkbox.

The problem is that the iframe contents goes blank and I can't figure out why.

#9 @scribu
14 years ago

  • Milestone changed from 3.1 to 3.0

#10 @scribu
14 years ago

  • Milestone changed from 3.0 to 3.1

I found that the iframe content is refreshed before send_to_editor() is called.

As ryan said, the checkbox would require a functional overhaul.

#11 @ocean90
14 years ago

Yes, thats right, its the function media_send_to_editor($html) with an exit.

So I try at the moment to add the checkbox to the form (media.php line 1530) and then add a new parameter to media_send_to_editor:

media_send_to_editor($html, $autoclose) {
  [...]
  if ( $autoclose == true);
   exit;

  return;

I think it not so tricky as you think.

@ocean90
14 years ago

the idea

#12 @scribu
14 years ago

Regarding media.php.patch:

It's the same problem: when you click the "Insert into post" button, a full POST request is made inside the iframe.

To get the HTML for the editor, you would need to make an AJAX request instead - probably using jQuery's serializeArray() function - so that the user's position in the iframe isn't lost.

@ocean90
14 years ago

the idea without bugs

#13 @nacin
14 years ago

Media will likely get a big overhaul in 3.1. I wouldn't spend *too* much time on this until then :)

#14 @nacin
14 years ago

  • Milestone changed from Awaiting Triage to Future Release

#15 @scribu
12 years ago

  • Keywords changed from needs-patch, 2nd-opinion to needs-patch 2nd-opinion

Marked #19622 as duplicate.

#16 @jane
12 years ago

  • Summary changed from Multiple image insert via media manager to Multiple image insert via media uploader

#17 @azaozz
12 years ago

The right way to do this would be to decide on the workflow, UX and UI first and then code it. It seems adding "just-another-checkbox" there won't be the optimal solution.

Some possibilities are:

  • Two insert image buttons at the bottom of each image properties box, "insert (and continue)" and "insert and close".
  • Adding "insert all images" button under the image properties boxes, above the Insert Gallery box.
  • A checkbox next to the Insert Image button (the proposed solution above) that would keep the gallery popup open after inserting the image. IMHO this is the most awkward option, still needs two clicks, etc.

If we go with "insert all images" the user most likely will have to edit each individual image later to add captions, titles, alt, etc.

#18 @jane
12 years ago

@azaozz: Why couldn't the same 'upload, metadata, insert' flow be used, just inserting them individually rather than dropping in a gallery?

#19 @ocean90
12 years ago

  • Keywords 3.5-early added; 2nd-opinion removed

I wish this for the next version.

#20 @sabreuse
12 years ago

  • Cc sabreuse@… added

#21 @martythornley
12 years ago

  • Cc marty@… added

I have just added a zip containing a little plugin I wrote a while back. It is based on the Faster Image Insert plugin that is in the repository. We have been using it since the old uploader but it works with the new drag and drop as well.

Being a plugin, it it needs to hook into several places to get it to operate but the working version shows how nice it would be to be able to check off any number of images.

A couple little things to point out...
1) It works with multisite and multisite or not, you can just drop in mu-plugins and it goes.
2) It has a couple little filters that would be nice to add too, allowing other plugins to NOT add images to the editor but to redirect them however you want. My image gallery plugin ties into it and adds images to it's own metabox for example. I'd love to see that work into the media upload process to let plugins be more versatile.

#22 @ocean90
12 years ago

  • Keywords 3.5-early removed
  • Milestone changed from Future Release to 3.5

#23 @MikeHansenMe
12 years ago

  • Cc mdhansen@… added
  • Keywords close added

With the new media uploader you can add multiple image at one time opening each one to comment. Proposing close on this ticket.

#24 @helenyhou
12 years ago

  • Keywords needs-patch close removed

So, close as fixed? And on which revision?

#25 @MikeHansenMe
12 years ago

Perhaps we should not close this until it fully replaces the older uploader. Right now it is accessible via the Beta Media on post/pages. However, the topic of this ticket will no longer be an issue.

#26 @nacin
12 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

Going to close this as fixed for 3.5. koopersmith has been using other tickets to track this item's progress, chiefly #21390.

Note: See TracTickets for help on using tickets.