Ticket #11687 (closed enhancement: fixed)

Opened 2 years ago

Last modified 2 years ago

Move Upload Files options to options-media.php

Reported by: scribu Owned by:
Priority: normal Milestone: 3.0
Component: Administration Version: 2.7
Severity: normal Keywords: has-patch 2nd-opinion
Cc:

Description

Currently, the group of options related to file uploads is put in options-misc.php, when it should actually be in options-media.php.

Attachments

11687.diff Download (7.5 KB) - added by scribu 2 years ago.
11687.2.diff Download (5.6 KB) - added by nacin 2 years ago.
Moves "uploading files" options to options-media from options-misc
11687.3.diff Download (1.4 KB) - added by Denis-de-Bernardy 2 years ago.
untested

Change History

scribu2 years ago

  • Keywords has-patch added
  • Version set to 2.7

11687.diff moves Upload Files to options-media.php and gets rid of options-misc.php since it's empty.

No use keeping an empty options-misc.php file like the way it is in the patch.

If we're going to empty out options-misc.php, though, wouldn't it still need to be kept around in case any plugins add options to it? (We could throw deprecation warnings for any plugins hooking into it, and perhaps then only add it to the navigation if there's something hooked in.)

Didn't really know what to do with the options-misc.php file. Feel free to improve the patch.

Hmm, I honestly don't know what we'd do here. It would break plugins for sure, but we do need to consolidate the media options, so I guess that's a small price to pay.

What's with the Track Links Update Times option? That's not media, but should it really be an option? I'm not sure where we'd move it if we keep it in core.

nacin2 years ago

Moves "uploading files" options to options-media from options-misc

  • Keywords 2nd-opinion added

Okay, new patch moves the media-related options in options-misc.php to options-media.php.

After that, this leaves options-misc.php with a single option. Second opinion needed there on how to deal with that last option and options-misc.php in general.

In case anyone was hooking into do_settings_fields('misc', 'default') to add media-related options to options-misc.php, it wasn't moved with the media-related options, so plugins would need to be adjusted. do_settings_fields('media', 'uploads') was added to the options that were moved over.

comment:6   dd322 years ago

I'm going to commit this for now, I think it might be time to retire the misc. settings page and push it into the other menu's.

as for the empty page, theres 2 options:

  1. Move them onto another page
  2. only show the menu if there are other settings which should be displayed on that page.

For option 1: they could be moved to Settings -> General

I like 2. Maybe plugins with 1 or two settings could use it, instead of creating a separate settings page.

comment:8   dd322 years ago

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

(In [13529]) Move Upload folder settings to Options -> Media. Props nacin. Fixes #11687

comment:9   dd322 years ago

See #12437 for removal of the Misc. page.

  • Status changed from closed to reopened
  • Resolution fixed deleted

Shouldn't the !is_multisite() check be retained? MU sites don't allow per-blog settings for these.

untested

untested patch restores the is_multisite() calls

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

(In [13545]) Restore MultiSite checks on Upload settings, Add proper whitelisting. Props Denis-de-Bernardy. Fixes #11687

Note: See TracTickets for help on using tickets.