Make WordPress Core

Opened 3 years ago

Closed 3 years ago

Last modified 2 months ago

#22604 closed defect (bug) (fixed)

media-new.php opens in new window when browser-uploader is clicked

Reported by: macbrink Owned by: nacin
Milestone: 3.5 Priority: normal
Severity: normal Version: 3.5
Component: Media Keywords: dev-feedback has-patch commit dev-reviewed
Focuses: Cc:


When uploading images for a post in post.php, when you click to select the browser-uploader, media-new.php is opened in a new window. In the original window, the media uploader is still open. This is very confusing for users.


Attachments (5)

22604.diff (940 bytes) - added by nacin 3 years ago.
22604.2.diff (2.3 KB) - added by nacin 3 years ago.
22604.3.diff (2.3 KB) - added by nacin 3 years ago.
22604.4.diff (2.5 KB) - added by nacin 3 years ago.
22604.5.diff (2.5 KB) - added by nacin 3 years ago.
Checks the priority from remove_action(), in case a plugin decides it wants this message (which it can attach forcibly to a different priority).

Download all attachments as: .zip

Change History (16)

@nacin3 years ago

comment:2 @nacin3 years ago

  • Keywords has-patch commit added
  • Milestone changed from Awaiting Review to 3.5

I did this on purpose, as you can upload multiple images at once. If you click "Edit", then save, maybe go back a few screens, you end up with a blank media-new.php page (no "Edit" links) as it manages to reset itself.

In hindsight, probably not my best idea. I'm fine with just removing target="_blank". If you're using media-new.php for any purpose but the browser uploader, you're probably doing it wrong and will realize the media manager is faster.

comment:3 @nacin3 years ago

I completely misread this report and thought this was about the "Edit" links on media-new.php opening in a new window, not opening media-new.php in a new window.

There's nothing we can do about media-new.php opening in a new window. It isn't ideal, but it just doesn't make sense otherwise. The browser uploader is nothing more than a "oh noes" fallback at this point. It has limited use.

comment:4 @nacin3 years ago

  • Keywords dev-feedback added; has-patch commit removed

@nacin3 years ago

comment:5 @nacin3 years ago

  • Keywords has-patch added

Per discussion in IRC:

  • The browser uploader is only necessary for files over 100MB, in Opera or IE, when Flash or Silverlight is used. The HTML4 runtime works in IE9 (and presumably IE10).
  • WP.com is going to remove the browser uploader warning and link and see what happens. The 100MB warning will appear for affected browsers, and that will include a browser uploader link.
  • We should do the same in RC2. It's a crappy experience to have it open in a new window, so let's see if we can avoid it.
  • If we get any, *any* bug reports, we restore it for RC3 and final.

Patch attached.

@nacin3 years ago

comment:6 @koopersmith3 years ago

Yay. Patch looks good at a glance.

comment:7 @nacin3 years ago

  • Keywords commit added

comment:8 @nacin3 years ago

Can we use global $post etc. in the templates themselves?

@nacin3 years ago

@nacin3 years ago

Checks the priority from remove_action(), in case a plugin decides it wants this message (which it can attach forcibly to a different priority).

comment:9 @ryan3 years ago

  • Keywords dev-reviewed added

Looks good.

comment:10 @nacin3 years ago

  • Owner set to nacin
  • Resolution set to fixed
  • Status changed from new to closed

In 22889:

Media: Remove the link to the browser uploader. The only need for it is large files (> 100MB) in certain browsers (IE, Opera), so we will show the link then only. fixes #22604.

comment:11 @slackbot2 months ago

This ticket was mentioned in Slack in #core-flow by boren. View the logs.

Note: See TracTickets for help on using tickets.