Commit Graph

7852 Commits

Author SHA1 Message Date
Sergey Biryukov
3e16f7510a Comments: Make sure the comment data passed to the preprocess_comment filter includes the comment_agent and comment_author_IP values.
Props zodiac1978, SergeyBiryukov.
Fixes #51044.
Built from https://develop.svn.wordpress.org/trunk@48822


git-svn-id: http://core.svn.wordpress.org/trunk@48584 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-19 01:57:08 +00:00
Sergey Biryukov
8b3a813e1a Plugins: Avoid a PHP notice if the update-supported key in plugin data is not set.
Props sanzeeb3.
Fixes #51052.
Built from https://develop.svn.wordpress.org/trunk@48820


git-svn-id: http://core.svn.wordpress.org/trunk@48582 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-18 20:38:09 +00:00
Sergey Biryukov
e50ac120a3 Site Health: Ensure that the tests returned by WP_Site_Health::get_tests() always have the required array keys: direct and async.
This avoids PHP notices if these keys were accidentally removed using the `site_status_tests` filter.

Props khag7, Ov3rfly, desrosj, Clorith.
Fixes #50858.
Built from https://develop.svn.wordpress.org/trunk@48808


git-svn-id: http://core.svn.wordpress.org/trunk@48570 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-17 02:03:04 +00:00
Sergey Biryukov
d9135ad9d0 Site Health: Add site environment type to the debug information.
Follow-up to [47919], [48188], [48372].

Props joostdevalk, Clorith.
Fixes #50887.
Built from https://develop.svn.wordpress.org/trunk@48802


git-svn-id: http://core.svn.wordpress.org/trunk@48564 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-16 18:27:04 +00:00
Sergey Biryukov
7cb2ca73a2 Site Health: Rename the $upload_max_size variable to $upload_max_filesize, for consistency with the PHP setting name.
Follow-up to [48535], [48538], [48539], [48544], [48800].

See #50945.
Built from https://develop.svn.wordpress.org/trunk@48801


git-svn-id: http://core.svn.wordpress.org/trunk@48563 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-16 17:54:05 +00:00
Sergey Biryukov
88e668d8e6 Site Health: Only display the warning about the post_max_size PHP value when it's lower than upload_max_filesize.
Previously, the warning was displayed even if the value was higher than `upload_max_filesize`, which made the report inaccurate, as these values don't necessarily have to match.

Props oakesjosh, jeroenrotty, desrosj, Clorith.
Fixes #50945.
Built from https://develop.svn.wordpress.org/trunk@48800


git-svn-id: http://core.svn.wordpress.org/trunk@48562 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-16 17:48:08 +00:00
Sergey Biryukov
54184bf872 Docs: Fix typo in the $image parameter description in is_gd_image().
Follow-up to [48798].

See #50833.
Built from https://develop.svn.wordpress.org/trunk@48799


git-svn-id: http://core.svn.wordpress.org/trunk@48561 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-16 14:02:03 +00:00
Sergey Biryukov
12c8f0e678 Code Modernization: Introduce is_gd_image() to check for PHP 8 GdImage object instances.
In PHP 8, the GD extension uses `GdImage` objects instead of resources for its underlying data structures.

This updates the existing `is_resource()` calls for image resources in core to accomodate for `GdImage` instances as well.

Props ayeshrajans, jrf.
Fixes #50833.
Built from https://develop.svn.wordpress.org/trunk@48798


git-svn-id: http://core.svn.wordpress.org/trunk@48560 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-16 13:33:09 +00:00
Sergey Biryukov
a5edb2a8a1 Filesystem API: Use correct variable when closing the file handle in WP_Filesystem_FTPext::get_contents().
Props gothick@gothick.org.uk.
Fixes #51029.
Built from https://develop.svn.wordpress.org/trunk@48797


git-svn-id: http://core.svn.wordpress.org/trunk@48559 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-15 20:56:02 +00:00
Sergey Biryukov
440eb31bb7 Site Health: Recognize define( 'WP_AUTO_UPDATE_CORE', 'minor' ) as an acceptable value.
Previously, it was only incidentally recognized as valid due to a loose comparison with `true`.

With the strict comparison added to `WP_Site_Health_Auto_Updates::test_constants()`, this was no longer the case.

Follow-up to [47841].

Props sterndata, mukesh27, avixansa, desrosj, SergeyBiryukov.
Fixes #50912.
Built from https://develop.svn.wordpress.org/trunk@48792


git-svn-id: http://core.svn.wordpress.org/trunk@48554 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-14 20:39:08 +00:00
Sergey Biryukov
1f85e7484f Docs: Consistently use third-person singular verbs for various filter descriptions, per the documentation standards.
See #50768.
Built from https://develop.svn.wordpress.org/trunk@48782


git-svn-id: http://core.svn.wordpress.org/trunk@48544 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-11 00:34:08 +00:00
Sergey Biryukov
5c0361aeb1 Coding Standards: Remove a few more extra brackets from some conditions in wp-admin/includes/plugin.php.
Follow-up to [48764].

See #50767.
Built from https://develop.svn.wordpress.org/trunk@48766


git-svn-id: http://core.svn.wordpress.org/trunk@48528 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-09 01:56:05 +00:00
Sergey Biryukov
004e3f897f Coding Standards: Fix WPCS issues in wp-admin/includes/plugin.php.
Includes minor code layout fixes for better readability.

Props rnaby for initial patch.
See #50767, #43848.
Built from https://develop.svn.wordpress.org/trunk@48764


git-svn-id: http://core.svn.wordpress.org/trunk@48526 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-08 21:04:04 +00:00
Sergey Biryukov
f5a4ac614e Coding Standards: Simplify some parts of user_can_access_admin_page() for better readability.
Props rnaby, valentinbora, khag7.
Fixes #43848.
Built from https://develop.svn.wordpress.org/trunk@48762


git-svn-id: http://core.svn.wordpress.org/trunk@48524 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-08 20:24:05 +00:00
Sergey Biryukov
132942b9fa Docs: Document the return value of get_settings_errors() using hash notation.
Props stevenlinx, webdevmattcrom, atachibana.
Fixes #42786.
Built from https://develop.svn.wordpress.org/trunk@48760


git-svn-id: http://core.svn.wordpress.org/trunk@48522 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-08 12:39:06 +00:00
Sergey Biryukov
961f455a00 Comments: Update DB version number used to trigger the upgrade routine for changing the comment_type DB field value in comments table.
Follow-up to [47597], [47626], [48225], [48227], [48748].

Props desrosj.
See #49236.
Built from https://develop.svn.wordpress.org/trunk@48751


git-svn-id: http://core.svn.wordpress.org/trunk@48513 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-07 16:32:03 +00:00
Sergey Biryukov
6b5e748dee Docs: Correct usage of the dynamic auto_update_{$type} filter.
This ensures that the canonical name of the filter is used in Site Health debug data, as well as on plugin and theme screens, so the developer reference site remains correct.

Props johnbillion.
Fixes #50868.
Built from https://develop.svn.wordpress.org/trunk@48750


git-svn-id: http://core.svn.wordpress.org/trunk@48512 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-07 16:14:03 +00:00
Sergey Biryukov
5221a27593 Site Health: Consistently pass an object to the auto_update_{$type} filter in Site Health debug data.
Previously, some instances of the filter received an array from a plugin or theme update response, potentially triggering PHP notices.

Props bpayton, pbiron.
Fixes #50852.
Built from https://develop.svn.wordpress.org/trunk@48745


git-svn-id: http://core.svn.wordpress.org/trunk@48507 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-07 13:28:05 +00:00
Sergey Biryukov
3a32284b26 Posts, Post Types: Use a consistent wording in messages about a locked post.
Props ramiy.
Fixes #50859.
Built from https://develop.svn.wordpress.org/trunk@48743


git-svn-id: http://core.svn.wordpress.org/trunk@48505 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-06 13:14:08 +00:00
Sergey Biryukov
7e1e4f379a Site Health: Check if session_status() exists before calling it.
Props bgermann.
Fixes #50862.
Built from https://develop.svn.wordpress.org/trunk@48742


git-svn-id: http://core.svn.wordpress.org/trunk@48504 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-06 00:25:07 +00:00
Sergey Biryukov
ee213e333b Comments: Remove a few more unnecessary instances of esc_html() in WP_Comments_List_Table::comment_status_dropdown().
Core translations are considered safe, and these labels are not escaped in any other instances.

Follow-up to [48521], [48722], [48724].

See #40188, #50815.
Built from https://develop.svn.wordpress.org/trunk@48741


git-svn-id: http://core.svn.wordpress.org/trunk@48503 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-05 13:53:06 +00:00
Sergey Biryukov
aaf49752b2 Plugins: Move the "Successfully installed the plugin" string to the correct Plugin_Upgrader method.
The string refers to the installation, and belongs in the `::install_strings()` method, not in `::upgrade_strings()`.

Props sswebster, nateinaction, SergeyBiryukov.
Fixes #50837.
Built from https://develop.svn.wordpress.org/trunk@48734


git-svn-id: http://core.svn.wordpress.org/trunk@48496 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-04 17:54:04 +00:00
whyisjake
b84d7f1fd3 Site Health: Display auto-update properly for plugins that don't support auto-updates.
Properly filter `auto_update_plugin` when displaying the table.

Fixes #50822.
Props Gwendydd, pbiron, audrasjb, SergeyBiryukov, whyisjake.


Built from https://develop.svn.wordpress.org/trunk@48731


git-svn-id: http://core.svn.wordpress.org/trunk@48493 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-04 17:37:02 +00:00
Sergey Biryukov
315db55458 Comments: Restore the ::has_items() call in WP_Comments_List_Table::extra_tablenav() for now, until unit tests are updated accordingly.
Follow-up to [48722].

Fixes #40188. See #50815.
Built from https://develop.svn.wordpress.org/trunk@48724


git-svn-id: http://core.svn.wordpress.org/trunk@48486 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-04 16:26:03 +00:00
Sergey Biryukov
b615c45103 Comments: Use the existing static variable instead of calling ::has_items() again in WP_Comments_List_Table::extra_tablenav().
Additionally, removed unnecessary `esc_html()` on the Filter button label. Core translations are considered safe, and this label is not escaped in any other instance.

Props whyisjake, SergeyBiryukov.
Fixes #40188.
Built from https://develop.svn.wordpress.org/trunk@48722


git-svn-id: http://core.svn.wordpress.org/trunk@48484 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-04 15:58:06 +00:00
Sergey Biryukov
e2c8e2fa5a Administration: Allow wp_credits() to accept $version and $locale parameters.
This can be helpful for plugin developers to get credits information for older versions or different locales.

Props ramiy.
Fixes #35910.
Built from https://develop.svn.wordpress.org/trunk@48715


git-svn-id: http://core.svn.wordpress.org/trunk@48477 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-08-03 12:53:08 +00:00
whyisjake
224fdb27b8 Upgrade/Install: Ensure the proper count of plugins that have auto-update enabled.
As certain plugins may not support updates, this count needs to accurately reflect that in the navbar.

Fixes 50808.
Props knutsp, audrasjb, pbiron, dd32, apedog, afragen, chriscct7, garyc40, whyisjake, SergeyBiryukov.

Built from https://develop.svn.wordpress.org/trunk@48703


git-svn-id: http://core.svn.wordpress.org/trunk@48465 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-31 17:21:04 +00:00
whyisjake
b4497ef13f Upgrade/Install: Allow for WordPress.org to remotely disable auto-updates for plugins/themes
As auto-updates are rolled out across WordPress.org, the API response can modulate the response, ensuring that a rolled out could be stalled or staggered if needed for security or performance reasons.

Fixes #50824.
Props dd32, whyisjake, SergeyBiryukov.


Built from https://develop.svn.wordpress.org/trunk@48701


git-svn-id: http://core.svn.wordpress.org/trunk@48463 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-31 17:03:05 +00:00
whyisjake
078db63c4b Upgrade/Install: Pass the plugin file path into the plugin_auto_update_debug_string filter.
Adds better tooling for when user specific plugins can be updated, but platform specific ones cannot.

Fixes #50821.
Props bpayton, pbiron, audrasjb, SergeyBiryukov, whyisjake. 


Built from https://develop.svn.wordpress.org/trunk@48696


git-svn-id: http://core.svn.wordpress.org/trunk@48458 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-30 21:50:02 +00:00
Sergey Biryukov
cf137e7c1b Comments: Pass the $which parameter to the manage_comments_nav action.
This brings some consistency with the  `manage_users_extra_tablenav` and `manage_users_extra_tablenav` actions.

Props Tkama, wpgurudev.
Fixes #50736.
Built from https://develop.svn.wordpress.org/trunk@48693


git-svn-id: http://core.svn.wordpress.org/trunk@48455 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-30 13:27:04 +00:00
Sergey Biryukov
72b87b3d74 Themes: Pass correct variable to is_php_version_compatible() in wp_theme_update_row().
This applies to the Themes screen in Multisite network admin.

Follow-up to [48660].

Props pbiron, afragen.
Fixes #48507. See #48491.
Built from https://develop.svn.wordpress.org/trunk@48689


git-svn-id: http://core.svn.wordpress.org/trunk@48451 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-29 21:08:02 +00:00
whyisjake
e6bfdde581 Upgrade/Install: Only show auto-update for themes that support the feature.
Similar to the changes for plugins in [48669], let's only show the UI for themes when updates are supported for that theme.

See #50280.
Props dd32.

Built from https://develop.svn.wordpress.org/trunk@48688


git-svn-id: http://core.svn.wordpress.org/trunk@48450 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-29 20:01:08 +00:00
Sergey Biryukov
d351100eba Upgrade/Install: Pass correct argument to clear_destination in Theme_Upgrader::install().
Follow-up to [48390].

Props afragen, sabernhardt.
Fixes #9757.
Built from https://develop.svn.wordpress.org/trunk@48685


git-svn-id: http://core.svn.wordpress.org/trunk@48447 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-29 13:09:04 +00:00
Sergey Biryukov
c5ef3b7976 Media: Pass the $rel parameter to image_send_to_editor filter.
Props mihdan, pputzer.
Fixes #50765.
Built from https://develop.svn.wordpress.org/trunk@48684


git-svn-id: http://core.svn.wordpress.org/trunk@48446 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 21:21:05 +00:00
whyisjake
d8fd6d05a3 Upgrade/Install: Swap auto-update-supported to update-supported in update checks.
Ensures backwards compatability with external updaters.

See #50280.
Props everyone-in-the-core-updates-channel. 


Built from https://develop.svn.wordpress.org/trunk@48678


git-svn-id: http://core.svn.wordpress.org/trunk@48440 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 18:28:06 +00:00
desrosj
6209a40fd9 Upgrade/Install: Clarify the descriptions for install_(plugin|theme)_overwrite_actions.
See #9757.
Built from https://develop.svn.wordpress.org/trunk@48677


git-svn-id: http://core.svn.wordpress.org/trunk@48439 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 18:16:07 +00:00
desrosj
1aa48c68f5 Upgrade/Install: Correct spelling of “overwrite” in new hooks and array indexes.
See #9757.
Built from https://develop.svn.wordpress.org/trunk@48676


git-svn-id: http://core.svn.wordpress.org/trunk@48438 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 17:56:04 +00:00
Sergey Biryukov
e4b2ad02b6 Administration: Don't override the $mode global in WP_Screen::render_view_mode() if it's already set.
Follow-up to [48398], [48423], [48424], [48450].

See #49715.
Built from https://develop.svn.wordpress.org/trunk@48670


git-svn-id: http://core.svn.wordpress.org/trunk@48432 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 16:55:04 +00:00
whyisjake
0f1f9bdb03 Upgrade/Install: Enhance auto-updates to be disabled for plugins that don't suport updates.
This removes the toggle UI when updates aren't available. When plugins use the filter, the UI is updated to show that they are being controlled via code. And then removed entirely when not available.

See #50798.
Fixes #50280.

Props elrae, pbiron, SergeyBiryukov, audrasjb, azaozz, StephenCronin, whyisjake, dd32, TimothyBlynJacobs, desrosj.


Built from https://develop.svn.wordpress.org/trunk@48669


git-svn-id: http://core.svn.wordpress.org/trunk@48431 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 16:32:01 +00:00
Sergey Biryukov
2bf5b5749f Administration: Pull the table_view_mode filter for now.
The extensibility of list table view modes will be explored in a future release.

Props audrasjb.
See #49715.
Built from https://develop.svn.wordpress.org/trunk@48668


git-svn-id: http://core.svn.wordpress.org/trunk@48430 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 16:19:03 +00:00
Sergey Biryukov
3db534a988 Upgrade/Install: Disable the plugin/theme auto-updates UI if AUTOMATIC_UPDATER_DISABLED is defined and set as true.
Props pbiron, dd32.
Fixes #50798. See #50280.
Built from https://develop.svn.wordpress.org/trunk@48667


git-svn-id: http://core.svn.wordpress.org/trunk@48429 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 16:15:03 +00:00
Sergey Biryukov
4cfc383544 Upgrade/Install: Check WordPress and PHP version requirements when uploading a plugin or theme from ZIP file.
Props mariovalney, desrosj.
See #50593.
Built from https://develop.svn.wordpress.org/trunk@48666


git-svn-id: http://core.svn.wordpress.org/trunk@48428 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 16:07:02 +00:00
Sergey Biryukov
0dd2f9f5c5 Docs: Add missing documentation for various upgrade/install class properties and methods.
Props ramiy.
Fixes #42923.
Built from https://develop.svn.wordpress.org/trunk@48661


git-svn-id: http://core.svn.wordpress.org/trunk@48423 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 11:57:03 +00:00
Sergey Biryukov
a745f035ab Themes: Display a message on Themes list table if a theme update requires a higher version of PHP or WordPress.
This applies to the Themes screen in Multisite network admin.

Props afragen, SergeyBiryukov.
Fixes #48507. See #48491.
Built from https://develop.svn.wordpress.org/trunk@48660


git-svn-id: http://core.svn.wordpress.org/trunk@48422 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 11:34:04 +00:00
Sergey Biryukov
e349d92b53 Themes: Include theme name in available update messages, for better accessibility and consistency with other similar messages.
Follow-up to [48652-48654].

See #48491.
Built from https://develop.svn.wordpress.org/trunk@48659


git-svn-id: http://core.svn.wordpress.org/trunk@48421 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 11:31:01 +00:00
Mike Schroder
8c3d56919e Upgrade/Install: Improve wp_opcache_invalidate() performance.
Changes from using `preg_match()` based `.php` extension checking to using `substr()` in `wp_opcache_invalidate()`.

Props jnylen0, aaroncampbell, SergeyBiryukov, desrosj, mikeschroder.
Fixes #50784.
Built from https://develop.svn.wordpress.org/trunk@48657


git-svn-id: http://core.svn.wordpress.org/trunk@48419 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 08:09:05 +00:00
whyisjake
26b706e27f Site Health: Incorrect file path in require_once.
Ensure that background updater can be loaded for testing to see if auto-updates can enable automatic updates.

Fixes #50793.
Props dd32.

Built from https://develop.svn.wordpress.org/trunk@48655


git-svn-id: http://core.svn.wordpress.org/trunk@48417 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 02:21:06 +00:00
Sergey Biryukov
0122e035b0 Themes: Display a message in theme grid and Theme Details modal if a theme update requires a higher version of PHP or WordPress.
This applies to the Themes screen and the Customizer theme browser.

Props afragen, SergeyBiryukov.
See #48491.
Built from https://develop.svn.wordpress.org/trunk@48652


git-svn-id: http://core.svn.wordpress.org/trunk@48414 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-28 00:09:02 +00:00
Sergey Biryukov
1f89186a3d Themes: Display a message in Theme Details modal if a theme requires a higher version of PHP or WordPress.
Props afragen, desrosj, SergeyBiryukov.
See #48491.
Built from https://develop.svn.wordpress.org/trunk@48636


git-svn-id: http://core.svn.wordpress.org/trunk@48398 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-27 13:12:04 +00:00
Mike Schroder
9ec7f2febd Docs: Correct wp_opcache_invalidate_file filter docs.
Changes incorrectly named `$filename` variable to `$filepath` and adjusts wording to align with PHP docs.

See #36455.
Built from https://develop.svn.wordpress.org/trunk@48632


git-svn-id: http://core.svn.wordpress.org/trunk@48394 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-27 09:08:05 +00:00
Sergey Biryukov
d8c62b5647 Posts, Post Types: Move get_post_states() back to the admin for now, require the file in WP_Customize_Nav_Menus::customize_register() instead.
This provides a minor performance improvement by only running the function in contexts where it's needed.

Follow-up to [47211], [47213], [47763], [48619].

See #46829, #49374.
Built from https://develop.svn.wordpress.org/trunk@48620


git-svn-id: http://core.svn.wordpress.org/trunk@48382 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-26 10:51:06 +00:00
Sergey Biryukov
aab535a576 Posts, Post Types: Make get_post_states() available on frontend.
This allows special pages to be denoted as such when editing a menu in the Customizer.

This applies to the Front Page, Posts Page, and Privacy Policy Page.

Follow-up to [47211], [47213], [47763].

Props dlh, whyisjake, SergeyBiryukov.
Fixes #46829. See #49374.
Built from https://develop.svn.wordpress.org/trunk@48619


git-svn-id: http://core.svn.wordpress.org/trunk@48381 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-26 01:14:06 +00:00
Sergey Biryukov
609acd89ed I18N: Merge duplicate "List view" and "Grid view" strings.
Props ramiy.
Fixes #50757.
Built from https://develop.svn.wordpress.org/trunk@48618


git-svn-id: http://core.svn.wordpress.org/trunk@48380 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-25 21:32:05 +00:00
Sergey Biryukov
c40a645510 Docs: Correct @see references for privacy hooks:
* `wp_privacy_personal_data_export_page`
* `wp_privacy_personal_data_erasure_page`

Hooks should be single-quoted when referenced.

Props pbiron, coffee2code.
See #49572, #meta5318.
Built from https://develop.svn.wordpress.org/trunk@48616


git-svn-id: http://core.svn.wordpress.org/trunk@48378 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-25 19:14:03 +00:00
Sergey Biryukov
7d305c8ff9 Docs: Correct @since tags for some WP_List_Table hooks:
* `views_{$this->screen->id}`
* `bulk_actions-{$this->screen->id}`
* `manage_{$this->screen->id}_sortable_columns`

Follow-up to [15491], [15578], [26401].

See #49572.
Built from https://develop.svn.wordpress.org/trunk@48615


git-svn-id: http://core.svn.wordpress.org/trunk@48377 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-25 18:55:03 +00:00
Sergey Biryukov
0ef0a1905b Docs: Remove outdated statement in bulk_actions-{$this->screen->id} filter description.
As of WordPress 4.7, developers can register their own bulk actions on list table screens.

Follow-up to [17297], [38647].

Props joyously, pbiron.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48614


git-svn-id: http://core.svn.wordpress.org/trunk@48376 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-25 18:13:02 +00:00
Sergey Biryukov
ef382e6aaf Site Health: Escape the displayed result of the request in REST API availability test.
Props siliconforks, gisselfeldt.
Fixes #50588.
Built from https://develop.svn.wordpress.org/trunk@48608


git-svn-id: http://core.svn.wordpress.org/trunk@48370 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-25 15:38:06 +00:00
Sergey Biryukov
b6f52721ed Administration: Use sentence case for "Mark as spam" bulk action links for sites and users, for consistency with comments.
Follow-up to [48352].

See #40244.
Built from https://develop.svn.wordpress.org/trunk@48595


git-svn-id: http://core.svn.wordpress.org/trunk@48357 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-24 00:27:03 +00:00
Sergey Biryukov
703a978a77 Administration: Capitalize Trash consistently in various messages.
When used as a noun referring to the "virtual" place, `Trash` should be capitalized.

Follow-up to [47233], [48352].

See #45317, #40244.
Built from https://develop.svn.wordpress.org/trunk@48594


git-svn-id: http://core.svn.wordpress.org/trunk@48356 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-24 00:21:03 +00:00
John Blackbourn
9bc7d0a776 Docs: Another pass at some inline docs fixes mostly made by PHPCBF.
See #49572, #50744
Built from https://develop.svn.wordpress.org/trunk@48590


git-svn-id: http://core.svn.wordpress.org/trunk@48352 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 21:11:05 +00:00
Sergey Biryukov
3f04e3bf5c I18N: Further adjust some update/install strings for consistency.
Follow-up to [48568], [48569].

See #50708, #50714.
Built from https://develop.svn.wordpress.org/trunk@48589


git-svn-id: http://core.svn.wordpress.org/trunk@48351 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 21:08:01 +00:00
Sergey Biryukov
5950e15042 I18N: Merge two "Return to top" strings.
Props ramiy, carike, whyisjake.
Fixes #50743.
Built from https://develop.svn.wordpress.org/trunk@48588


git-svn-id: http://core.svn.wordpress.org/trunk@48350 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 20:21:07 +00:00
Sergey Biryukov
161821d155 Site Health: Correct the quotes for the tested value of mock plugin data in auto-updates test.
Follow-up to [48584].

See #50662.
Built from https://develop.svn.wordpress.org/trunk@48587


git-svn-id: http://core.svn.wordpress.org/trunk@48349 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 20:13:05 +00:00
John Blackbourn
57a3f803ae Docs: First pass at some inline docs fixes mostly made by PHPCBF.
See #49572, #50744
Built from https://develop.svn.wordpress.org/trunk@48586


git-svn-id: http://core.svn.wordpress.org/trunk@48348 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 20:01:04 +00:00
John Blackbourn
7f898dd9c4 Docs: Use more appropriate variable names in the inline docs for action and filter parameters.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48585


git-svn-id: http://core.svn.wordpress.org/trunk@48347 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 19:06:03 +00:00
desrosj
231d21ebcd Site Health: Pass all expected parameters to auto_update_{$type}.
This prevents fatal errors when other hooked functions are expecting both parameters. 

Props dd32, desrosj, audrasjb, pbiron.
Fixes #50662.
Built from https://develop.svn.wordpress.org/trunk@48584


git-svn-id: http://core.svn.wordpress.org/trunk@48346 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 19:03:04 +00:00
Sergey Biryukov
0eb1b2a447 I18N: Update "Default Template" string to match the sentence case used in the block editor.
Props ramiy.
Fixes #50742.
Built from https://develop.svn.wordpress.org/trunk@48583


git-svn-id: http://core.svn.wordpress.org/trunk@48345 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 18:55:01 +00:00
desrosj
2c2508f98c General: Ensure the database upgrades from [48575] are run.
This corrects the database version to match the commit number the upgrade changes were made.

See #50413.
Built from https://develop.svn.wordpress.org/trunk@48582


git-svn-id: http://core.svn.wordpress.org/trunk@48344 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 18:43:04 +00:00
John Blackbourn
124972f2c6 Docs: Further corrections and improvements to various inline docblocks.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48576


git-svn-id: http://core.svn.wordpress.org/trunk@48338 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 07:39:02 +00:00
Aaron Jorbin
6cab8cce22 General: Update code for readability and inclusion
There are two pieces in here:

1) The update to change blacklist to blocklist is moved to disallowed_list. "Block" has a meaning in our code, and there could be ambiguity between this code and code related to blocks.

2) This improves backwards compatibility for code that was accessing the now deprecated code.

Previously: [48477], [48405], [48400], [48121], [48122], [48124], [48142], [48566]

Props: desrosj, SergeyBiryukov, johnjamesjacoby
Fixes: #50413


Built from https://develop.svn.wordpress.org/trunk@48575


git-svn-id: http://core.svn.wordpress.org/trunk@48337 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 03:14:06 +00:00
John Blackbourn
0bf9b04c53 Docs: Various formatting improvements to inline docblocks.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48574


git-svn-id: http://core.svn.wordpress.org/trunk@48336 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 00:52:05 +00:00
John Blackbourn
1fbcdb2213 Docs: Various corrections to inline docblocks.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48573


git-svn-id: http://core.svn.wordpress.org/trunk@48335 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-23 00:48:06 +00:00
whyisjake
dd642e7b00 i18n: Merge similar translation strings to "Update failed".
Fixes #50714.
Props ramiy, ocean90.

Built from https://develop.svn.wordpress.org/trunk@48569


git-svn-id: http://core.svn.wordpress.org/trunk@48331 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-22 22:10:02 +00:00
whyisjake
921ddab889 I18N: Merge similar "Installation failed" strings
Fixes #50708.

Props ramiy, ocean90, audrasjb.

Built from https://develop.svn.wordpress.org/trunk@48568


git-svn-id: http://core.svn.wordpress.org/trunk@48330 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-22 21:59:05 +00:00
desrosj
2cebcb6144 General: Rename remove_option_allowed_list() to remove_allowed_options().
This was missed in [48142] which renamed `add_option_allowed_list()` to `add_allowed_options()` for better readability. The two functions should have consistent names.

See #50413.
Built from https://develop.svn.wordpress.org/trunk@48566


git-svn-id: http://core.svn.wordpress.org/trunk@48328 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-22 18:52:02 +00:00
Sergey Biryukov
1373b2056d Docs: Correct type for the $theme parameter of theme_auto_update_debug_string filter.
Follow-up to [48546], [48549], [48552].

See #50663.
Built from https://develop.svn.wordpress.org/trunk@48561


git-svn-id: http://core.svn.wordpress.org/trunk@48323 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-22 00:29:03 +00:00
Sergey Biryukov
88e046f1e8 Site Health: Fix some typos in the test for plugin and theme auto-updates.
Follow-up to [48548], [48558], [48559].

See #50662.
Built from https://develop.svn.wordpress.org/trunk@48560


git-svn-id: http://core.svn.wordpress.org/trunk@48322 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-22 00:17:04 +00:00
Sergey Biryukov
c6034be779 Site Health: Correct inverted logic for themes in the test for plugin and theme auto-updates.
Follow-up to [48548], [48558].

See #50662.
Built from https://develop.svn.wordpress.org/trunk@48559


git-svn-id: http://core.svn.wordpress.org/trunk@48321 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-22 00:15:02 +00:00
Sergey Biryukov
93bf0c3b83 Site Health: Add the test for plugin and theme auto-updates to WP_Site_Health::get_tests().
This ensures that the test actually runs.

Follow-up to [48548].

See #50662.
Built from https://develop.svn.wordpress.org/trunk@48558


git-svn-id: http://core.svn.wordpress.org/trunk@48320 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-22 00:07:02 +00:00
Sergey Biryukov
a68d462439 Site Health: Use a consistent label for theme auto-updates in debug data.
Props audrasjb.
Fixes #50728.
Built from https://develop.svn.wordpress.org/trunk@48554


git-svn-id: http://core.svn.wordpress.org/trunk@48316 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 21:06:02 +00:00
Sergey Biryukov
94d4561906 Site Health: Simplify the logic for displaying whether auto-updates are enabled for plugins and themes.
Remove some extra variables.

Follow-up to [48546], [48549].

See #50663.
Built from https://develop.svn.wordpress.org/trunk@48552


git-svn-id: http://core.svn.wordpress.org/trunk@48314 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 18:44:04 +00:00
Sergey Biryukov
8a58ab36cc Site Health: Rename the filters added in [48546] for clarity.
See #50663.
Built from https://develop.svn.wordpress.org/trunk@48549


git-svn-id: http://core.svn.wordpress.org/trunk@48311 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 17:09:03 +00:00
whyisjake
9d2b92be26 Site Health: Add tests to check for potential issues with plugin and theme auto-updates.
Fixes #50662.
Props desrosj, audrasjb.

Built from https://develop.svn.wordpress.org/trunk@48548


git-svn-id: http://core.svn.wordpress.org/trunk@48310 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 17:07:05 +00:00
whyisjake
32f791da49 Site Health: Add auto-update information to for plugins and themes.
New filters:

* `plugin_auto_update_debug_str`
* `theme_auto_update_debug_str`

Fixes #50663.
Props pbiron, audrasjb, davidbaumwald.

Built from https://develop.svn.wordpress.org/trunk@48546


git-svn-id: http://core.svn.wordpress.org/trunk@48308 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 16:54:02 +00:00
Sergey Biryukov
548df4e3e6 I18N: Add context to some theme strings for consistency.
Props ramiy, ocean90.
Fixes #50709.
Built from https://develop.svn.wordpress.org/trunk@48545


git-svn-id: http://core.svn.wordpress.org/trunk@48307 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 16:33:05 +00:00
Sergey Biryukov
48841f9ab3 Site Health: Rename upload_max array key in file upload checks to max_effective_size for clarity.
Follow-up to [48535].

See #50038.
Built from https://develop.svn.wordpress.org/trunk@48544


git-svn-id: http://core.svn.wordpress.org/trunk@48306 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 16:20:03 +00:00
Sergey Biryukov
1c52ad8d3f Site Health: Move post_max_size and upload_max_filesize out of a translatable string in file upload checks.
Simplify some other strings, use a consistent format for translator comments.

Follow-up to [48535].

See #50038.
Built from https://develop.svn.wordpress.org/trunk@48539


git-svn-id: http://core.svn.wordpress.org/trunk@48301 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 15:53:04 +00:00
Sergey Biryukov
bec9fa5010 Site Health: Remove parse_ini_size(), use the existing wp_convert_hr_to_bytes() function instead.
Follow-up to [48535].

See #50038.
Built from https://develop.svn.wordpress.org/trunk@48538


git-svn-id: http://core.svn.wordpress.org/trunk@48300 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 15:40:03 +00:00
whyisjake
73a8fb4cc3 Site Health: Include new tests to check for the ability to upload files.
Several new checks:

* `max_file_uploads`
* `file_uploads`
* `post_max_size`
* `upload_max_filesize`
* `upload_max`
* `max_file_uploads`

In addition, new function `parse_ini_size()` that converts shorthand byte strings to bytes. Useful for size comparisons.

Fixes #50038.
Props dd32, donmhico, JavierCasares, SergeyBiryukov, ayeshrajans, Clorith, ipstenu, sabernhardt, whyisjake.

Built from https://develop.svn.wordpress.org/trunk@48535


git-svn-id: http://core.svn.wordpress.org/trunk@48297 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 15:21:02 +00:00
Sergey Biryukov
d1822e81ba Site Health: Use consistent error messages when switching plugin or theme auto-updates on or off.
Props ramiy.
Fixes #50721.
Built from https://develop.svn.wordpress.org/trunk@48534


git-svn-id: http://core.svn.wordpress.org/trunk@48296 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 14:42:05 +00:00
Sergey Biryukov
9ce7bd633b Docs: Improve description for edit_post().
Props stevenlinx.
Fixes #50713.
Built from https://develop.svn.wordpress.org/trunk@48529


git-svn-id: http://core.svn.wordpress.org/trunk@48291 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 12:49:03 +00:00
whyisjake
5c836585d1 Comments: Don't show the filter/pagination actions if there are no comments to list.
It doesn't make sense to be able to filter the comments list table when there are are no (trashed/spam) comments available.

Fixes #40188.
Props swissspidy, Jim_Panse, menakas, akbarhusen429, dinhtungdu, birgire, SergeyBiryukov, davidbaumwald, rebasaurus, whyisjake.


Built from https://develop.svn.wordpress.org/trunk@48521


git-svn-id: http://core.svn.wordpress.org/trunk@48283 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-21 00:29:02 +00:00
Sergey Biryukov
e4ce35dd11 I18N: Add context to some plugin and theme strings for consistency.
Props ramiy, audrasjb.
Fixes #50710.
Built from https://develop.svn.wordpress.org/trunk@48520


git-svn-id: http://core.svn.wordpress.org/trunk@48282 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-20 23:14:05 +00:00
Sergey Biryukov
82ce41ff51 I18N: Mark the strings with plugin and theme names in email notifications for translation.
Follow-up to [48517].

See #50350.
Built from https://develop.svn.wordpress.org/trunk@48519


git-svn-id: http://core.svn.wordpress.org/trunk@48281 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-20 21:25:06 +00:00
desrosj
02f200df1d Administration: Include the new plugin and theme versions in email notifications.
This helps administrators keep track of which versions of plugins and themes are running on their site when auto-updates occur.

Props audrasjb, pbiron.
Fixes #50350.
Built from https://develop.svn.wordpress.org/trunk@48517


git-svn-id: http://core.svn.wordpress.org/trunk@48279 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-20 18:28:03 +00:00
Andrew Ozz
efb77b4a65 Upgrade/install: Fix/clarify the "Upload in a zip format" string.
Props greenshady, mariovalney.
See #9757.
Built from https://develop.svn.wordpress.org/trunk@48509


git-svn-id: http://core.svn.wordpress.org/trunk@48271 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-19 17:11:02 +00:00
John Blackbourn
c3f787b8ff Docs: Miscellaneous docblock corrections.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48508


git-svn-id: http://core.svn.wordpress.org/trunk@48270 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-18 22:11:02 +00:00
whyisjake
da7a54d206 Administration: Fix an index inconsistency in get_admin_page_title() function.
Ensure that `get_admin_page_title()` returns a value from pages registered using `add_menu_page()`.

Fixes #46081.

Props grapestain, valentinbora, SergeyBiryukov, audrasjb.


Built from https://develop.svn.wordpress.org/trunk@48500


git-svn-id: http://core.svn.wordpress.org/trunk@48262 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-16 22:15:07 +00:00
whyisjake
a53b741359 Coding Standards: Update the docblock to remove superflous since.
The `@deprecated` DocBlock tag should start with the version followed by the description of what to use instead.

Fixes #44959.

Props keesiemeijer, sabernhardt.


Built from https://develop.svn.wordpress.org/trunk@48495


git-svn-id: http://core.svn.wordpress.org/trunk@48257 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-16 21:12:08 +00:00
Sergey Biryukov
64a4066874 Upgrade/Install: Check if the theme installer skin's overwrite property exists in Theme_Upgrader::install_strings().
This ensures consistency with `Plugin_Upgrader::install_strings()` and resolves an issue caused by the property not existing in other upgrader implementations.

Props schlessera, azaozz.
See #50670.
Built from https://develop.svn.wordpress.org/trunk@48493


git-svn-id: http://core.svn.wordpress.org/trunk@48255 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-16 13:19:03 +00:00
desrosj
fdd88e24ed General: Rename the $new_whitelist_options global variable.
This change renames `$new_whitelist_options` to `$new_allowed_options`. This makes the variable’s purpose more clear, and promotes using more inclusive language.

For backwards compatibility, the new variable is passed by reference to the old one.

Follow up to [48121].

Props ayeshrajans, desrosj, jorbin, SergeyBiryukov.
See #50413.
Fixes #50434.
Built from https://develop.svn.wordpress.org/trunk@48477


git-svn-id: http://core.svn.wordpress.org/trunk@48246 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-14 12:33:02 +00:00
John Blackbourn
5eb3f0ffcb Docs: Improve docs for arguments that accept a numerically indexed array of associative arrays.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48475


git-svn-id: http://core.svn.wordpress.org/trunk@48244 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-14 12:10:05 +00:00
John Blackbourn
4ff1233e75 Docs: Correct and improve inline docs for parameters that accept a callback function.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48473


git-svn-id: http://core.svn.wordpress.org/trunk@48242 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-14 11:56:04 +00:00
John Blackbourn
6b21db7fb9 Docs: Miscellaneous docblock corrections and improvements.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48462


git-svn-id: http://core.svn.wordpress.org/trunk@48231 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-13 22:10:07 +00:00
Sergey Biryukov
7c09c153d5 Upgrade/Install: Simplify compatibility checks for uploaded plugins and themes for better readability.
Use `$new_plugin_data` and `$new_theme_data` as a shorthand for the corresponding `$this->upgrader` properties.

Follow-up to [48390], [48448].

Props afragen.
See #9757.
Built from https://develop.svn.wordpress.org/trunk@48455


git-svn-id: http://core.svn.wordpress.org/trunk@48224 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-13 13:35:05 +00:00
Andrew Ozz
63a2cb3060 Upgrade/Install: Use wp_strip_all_tags() for the fields in the compare table on the "Update theme/plugin from uploaded zip" screen. Some may contain HTML.
See #9757.
Built from https://develop.svn.wordpress.org/trunk@48453


git-svn-id: http://core.svn.wordpress.org/trunk@48222 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 20:00:03 +00:00
Sergey Biryukov
9848b6b3e9 Plugins: Make delete plugin message less scary.
This adds a check if the plugin actually has an uninstall routine before saying that its data will be deleted too.

Props samful, joostdevalk, joyously, Chouby, SergeyBiryukov.
Fixes #50346.
Built from https://develop.svn.wordpress.org/trunk@48451


git-svn-id: http://core.svn.wordpress.org/trunk@48220 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 13:22:04 +00:00
Sergey Biryukov
c4543704e2 Administration: Restore the excerpt key for the Extended view mode for backward compatibility for now.
Props Offereins.
See #49715.
Built from https://develop.svn.wordpress.org/trunk@48450


git-svn-id: http://core.svn.wordpress.org/trunk@48219 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 11:36:04 +00:00
Sergey Biryukov
1556ecc000 Docs: Add a @since entry for the $hook_extra parameter added to WP_Upgrader::download_package().
Follow-up to [48399].

See #49686.
Built from https://develop.svn.wordpress.org/trunk@48449


git-svn-id: http://core.svn.wordpress.org/trunk@48218 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 11:02:03 +00:00
Sergey Biryukov
707534c2d8 Upgrade/Install: Use is_php_version_compatible() and is_wp_version_compatible() in plugin and theme requirement checks.
Follow-up to [48390].

Props afragen.
See #9757.
Built from https://develop.svn.wordpress.org/trunk@48448


git-svn-id: http://core.svn.wordpress.org/trunk@48217 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 10:55:03 +00:00
Sergey Biryukov
f83b8775b3 I18N: Move the "WordPress Backups" support URL to its own translatable string.
Follow-up to [48390].

See #9757.
Built from https://develop.svn.wordpress.org/trunk@48447


git-svn-id: http://core.svn.wordpress.org/trunk@48216 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 10:34:05 +00:00
Sergey Biryukov
3f1650122a Docs: Miscellaneous DocBlock corrections for plugin and theme updates.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48446


git-svn-id: http://core.svn.wordpress.org/trunk@48215 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 01:19:03 +00:00
Sergey Biryukov
cecf7b9823 Administration: Handle the result of Plugin_Upgrader::bulk_upgrade() for a plugin that is already at the latest version in the same way it is handled for themes.
This corrects a fragile check of the result in `wp_ajax_update_plugin()` that depended on the internal array pointer, and brings some consistency with `wp_ajax_update_theme()`.

Follow-up to [37714], [48401].
See #50448.
Built from https://develop.svn.wordpress.org/trunk@48445


git-svn-id: http://core.svn.wordpress.org/trunk@48214 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-12 01:16:05 +00:00
Sergey Biryukov
7b61df725e Revisions: Replace array_shift() with reset() in register_and_do_post_meta_boxes() for better performance.
Follow-up to [31829], [48422].

See #34560.
Built from https://develop.svn.wordpress.org/trunk@48436


git-svn-id: http://core.svn.wordpress.org/trunk@48205 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-11 12:30:02 +00:00
Sergey Biryukov
51856d435b Administration: Bring some consistency to handling list table view modes.
* Remove duplicate variables and DocBlocks.
* Add missing description for the `$mode` global.
* Use sentence case for "Compact view" and "Extended view" labels.

Follow-up to [48398], [48423].

Props afercia, Offereins, SergeyBiryukov.
See #49715.
Built from https://develop.svn.wordpress.org/trunk@48424


git-svn-id: http://core.svn.wordpress.org/trunk@48193 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 16:04:05 +00:00
Sergey Biryukov
0f92086ca0 Administration: Make some adjustments to WP_Screen::render_view_mode():
* Restore the `$mode` global for backward compatibility.
* Remove redundant check, as `$mode` is already set at this point, and already defaults to `list` via `get_user_setting()`'s second argument.
* Use sentence case for "View mode" and "Extended view" labels.

Follow-up to [48398].

See #49715.
Built from https://develop.svn.wordpress.org/trunk@48423


git-svn-id: http://core.svn.wordpress.org/trunk@48192 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 16:02:05 +00:00
Adam Silverstein
7d0162bc2e Revisions: optimize performance when post has large number of revisions.
Improve speed and reduce the memory footprint when loading posts with many revisions.

* Use a direct query in `wp_get_post_autosave` to avoid loading all revisions.
* Query for IDs vs full objects in `register_and_do_post_meta_boxes`.

Props pdfernhout, johnnyb, miqrogroove, ocean90, senatorman, DBrumbaugh10Up, martijn-van-der-kooij, pavelevap, mackensen, mikeyarce, whyisjake.
Fixes #34560.


Built from https://develop.svn.wordpress.org/trunk@48422


git-svn-id: http://core.svn.wordpress.org/trunk@48191 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 15:13:07 +00:00
Sergey Biryukov
b03053eb2a Docs: Correct documentation for customize_controls_head hook and _customizer_mobile_viewport_meta() function.
Follow-up to [48412].

See #47369.
Built from https://develop.svn.wordpress.org/trunk@48420


git-svn-id: http://core.svn.wordpress.org/trunk@48189 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 11:36:07 +00:00
whyisjake
28a390c2b2 Upgrade/Install: Use ARIA button class on plugin and theme auto-updates action links
According to the [accesability guidelines](https://developer.wordpress.org/coding-standards/wordpress-coding-standards/accessibility/#semantics-for-controls), the control should be a link when JavaScript is not available and a button the rest of the time.

In addition, handlers were added for spacebar usage, and some changes to the a11y speak verbiage.

Fixes #50516.
Props ryokuhi, audrasjb, afercia, whyisjake/



Built from https://develop.svn.wordpress.org/trunk@48418


git-svn-id: http://core.svn.wordpress.org/trunk@48187 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 06:18:04 +00:00
whyisjake
836ad98276 Upgrade/Install: Ensure cleanup after canceled update.
Ensure that the uploaded zip is hidden from the media library, where a task will remove failed installs after two hours.

Fixes #50612.

Props psykro, desrosj, joyously, azaozz, noisysocks, whyisjake. 

Built from https://develop.svn.wordpress.org/trunk@48417


git-svn-id: http://core.svn.wordpress.org/trunk@48186 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 06:08:06 +00:00
whyisjake
9397ad46ba Coding Standards: Some missed code formatting.
Unprops: whyisjake.


Built from https://develop.svn.wordpress.org/trunk@48415


git-svn-id: http://core.svn.wordpress.org/trunk@48184 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-10 01:01:03 +00:00
whyisjake
1158166d9c Administration: Remove multiple viewport meta tags from mobile pages.
In addition, add the `wp_admin_viewport_meta()` function, paired to the `admin_viewport_meta` filter to control attributes of the meta tag.

Fixes #47369.
Props BettyJJ, mukesh27, SergeyBiryukov, ajayghaghretiya1, msaggiorato, talldanwp, davidbaumwald, donmhico, audrasjb.


Built from https://develop.svn.wordpress.org/trunk@48412


git-svn-id: http://core.svn.wordpress.org/trunk@48181 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-09 23:29:08 +00:00
Sergey Biryukov
6bf6bc451f Docs: Miscellaneous DocBlock corrections.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48408


git-svn-id: http://core.svn.wordpress.org/trunk@48177 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-08 13:15:03 +00:00
Sergey Biryukov
c358ba7112 Upgrade/Install: Prevent the upgrade routine for updating the comment_type field in the comments table from running twice.
Follow-up to [47597], [48400].

See #50413, #49236.
Built from https://develop.svn.wordpress.org/trunk@48405


git-svn-id: http://core.svn.wordpress.org/trunk@48174 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-08 10:58:05 +00:00
desrosj
500508884e Administration: Fix failing tests as a result of [48397].
Because of changes to how PHP handles arrays used in `foreach()` loops in PHP >= 7.0, [48397] resulted in a failing test for PHP 5.6.

This calls `reset()` after using the `$results` array in the `foreach()` to ensure the array is treated the same and as expected.

Props azaozz, desrosj, SergeyBiryukov, xknown.
See #50448.
Built from https://develop.svn.wordpress.org/trunk@48401


git-svn-id: http://core.svn.wordpress.org/trunk@48170 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 20:38:03 +00:00
desrosj
a8521d48ac Upgrade/Install: Prevent some 5.5.0 upgrade routines from running twice.
This will prevent the options renamed for 5.5.0 from being converted twice. If a new update routine is added before 5.5 is released, the option values would be erased for anyone running `trunk` or nightlies without this change.

Props azaozz, desrosj, SergeyBiryukov, whyisjake.
Fixes #50413.
Built from https://develop.svn.wordpress.org/trunk@48400


git-svn-id: http://core.svn.wordpress.org/trunk@48169 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 19:21:06 +00:00
desrosj
8381fad76e Upgrade/Install: Add hook_extra parameter to the upgrader_pre_download filter.
This provides additional context to code running on this hook, including which plugin or theme update will be downloaded. It also brings consistency to this filter with others throughout the upgrade process.

Props obliviousharmony, desrosj.
Fixes #49686.
Built from https://develop.svn.wordpress.org/trunk@48399


git-svn-id: http://core.svn.wordpress.org/trunk@48168 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 19:15:06 +00:00
whyisjake
dcdabb5bb3 Administration: Introduce extensibility to posts and comments list table views, for accessibility purposes.
At default, expands the excerpt view to become an extended view. Includes a new `table_view_mode` filter to allow further configuration.

Fixes #49715.
Props joedolson, audrasjb, afercia, whyisjake.


Built from https://develop.svn.wordpress.org/trunk@48398


git-svn-id: http://core.svn.wordpress.org/trunk@48167 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 19:12:03 +00:00
desrosj
48da753ff0 Administration: Prevent repeat emails for identical plugin or theme auto-update attempt failures.
This change adds a throttle mechanism to plugin and theme auto-update failure emails using similar logic to the email sent for a Core auto-update.

The first time a plugin or theme auto-update fails, the package and `new_version` will be tracked in the `auto_plugin_theme_update_emails` option. An email for this specific update attempt will not be resent.

However, if this update fails again and non-repeat failures or successful updates are also present, then the failure information will be included in that email (an email needs to be sent for the new events regardless).

Props johnbillion, arpitgshah, desrosj, audrasjb, pbiron, earnjam.
Fixes #50448.
Built from https://develop.svn.wordpress.org/trunk@48397


git-svn-id: http://core.svn.wordpress.org/trunk@48166 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 19:00:02 +00:00
Andrew Ozz
49bbff551b Upgrade/install: Allow plugin and theme updates from a uploaded .zip file.
Props mariovalney, cyberhobo, imath, shaunandrews, mariovalney, earnjam, desrosj, dd32, folletto, swissspidy, melchoyce, pento, joshuawold, psykro, clorith, ahortin, galbaras, pingram3541, joyously, doobeedoo, karmatosed, poena, whyisjake, earnjam, sergeybiryukov, audrasjb, azaozz.

Fixes #9757.
Built from https://develop.svn.wordpress.org/trunk@48390


git-svn-id: http://core.svn.wordpress.org/trunk@48159 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 17:49:05 +00:00
John Blackbourn
3c41801c5c Administration: Reinstate the description for the admin_xml_ns hook which was accidentally removed in [47771].
See #46015.
Built from https://develop.svn.wordpress.org/trunk@48380


git-svn-id: http://core.svn.wordpress.org/trunk@48149 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 14:57:02 +00:00
John Blackbourn
913f5aaab9 Docs: Correct some @since entries added in 5.5.
See #49572
Built from https://develop.svn.wordpress.org/trunk@48377


git-svn-id: http://core.svn.wordpress.org/trunk@48146 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 14:14:04 +00:00
Andrea Fercia
aee4324b9e Accessibility: Media: Improve accessibility of the status and error messages in the Image Editor.
- improves focus management by moving focus to the notices, if any, or to the first "tabbable" element
- this avoids a focus loss and helps Braille-only and screen magnification users to be aware of the messages
- adds an ARIA role `alert` to all the notices 
- uses `wp.a11y.speak()` to announce messages to assistive technology
- this way, all visual users will see the messages while assistive technology users will get an audible message
- uses `wp.i18n` for translatable strings in `wp-admin/js/image-edit.js`

Props anevins, ryanshoover, antpb, SergeyBiryukov, afercia.
See #20491.
Fixes #47147.

Built from https://develop.svn.wordpress.org/trunk@48375


git-svn-id: http://core.svn.wordpress.org/trunk@48144 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 13:45:02 +00:00
Sergey Biryukov
181717c9ab Plugins: Make sure the HTML ID attributes in plugin action links are unique.
Follow-up to [47588].

Props mukesh27, roytanck, SergeyBiryukov.
Fixes #49916.
Built from https://develop.svn.wordpress.org/trunk@48374


git-svn-id: http://core.svn.wordpress.org/trunk@48143 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 13:43:02 +00:00
Andrea Fercia
22d0cd6c96 Accessibility: Allow post boxes on the Dashboard and Classic Editor pages to be reordered by using the keyboard.
So far, it has been possible to rearrange into a new order the post boxes (also known as "widgets" on the Dashboard and "meta boxes" on the Edit post page) only by using a pointing device, for example a mouse.

This change adds new controls and functionality to allow the boxes to be rearranged also with the keyboard. Additionally, audible messages are sent to the admin ARIA live region to notify screen reader users of the reorder action result.

Props joedolson, anevins, antpb, audrasjb, xkon, MarcoZ, karmatosed, afercia.
Fixes #39074.

Built from https://develop.svn.wordpress.org/trunk@48373


git-svn-id: http://core.svn.wordpress.org/trunk@48142 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-07 13:00:02 +00:00
whyisjake
81b809e3d6 Administration: Move more table strings to sentence casing.
WordPress as a project has moved largely to sentence casing for UI elements in the admin. This commit moves several string$

* Move to trash
* Mark as spam
* Permanently delete comment
* Approve comment
* In response to
* Bulk actions
* Not spam
* Sumitted on
* Delete permanently
* Add media
* Upload files
* Upload images
* Add media
* Bulk select
* Restore from trash
* Search media
* Attachment details
* Create gallery
* Edit gallery
* Cancel gallery
* Add to gallery
* Image details
* Replace image
* Cancel edit
* Edit image
* Choose image
* Select and crop
* Skip cropping
* Crop image
* Audio details
* Replace audio
* Add audio source
* Video details
* Replace video
* Add video source
* Select poster image
* Add subtitles
* Create audio playlist
* Edit audio playlist.
* Cancel audio playlist
* Create video playlist
* Edit video playlist
* Add to video playlist
* Filter media


Fixes #40244.
Props afercia, bhargavbhandari90, rcutmore, webzunft, manojlovic, jeremyfelt, desrosj, lschuyler, SergeyBiryukov, whyisjake. 


Built from https://develop.svn.wordpress.org/trunk@48352


git-svn-id: http://core.svn.wordpress.org/trunk@48121 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 21:52:21 +00:00
desrosj
bc7de32645 Coding Standards: Correct two coding standards issues introduced in [48277] and [48334].
See #50504, #50550.
Built from https://develop.svn.wordpress.org/trunk@48345


git-svn-id: http://core.svn.wordpress.org/trunk@48114 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 19:23:02 +00:00
desrosj
77af0e5982 Docs: Correct instances of “auto update” with “auto-update” for consistency.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48344


git-svn-id: http://core.svn.wordpress.org/trunk@48113 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 19:15:03 +00:00
Sergey Biryukov
8a815f22e7 Privacy: Simplify the logic for updating the meta values for personal data export requests from absolute to relative paths.
Follow-up to [48127].

See #44038.
Built from https://develop.svn.wordpress.org/trunk@48330


git-svn-id: http://core.svn.wordpress.org/trunk@48099 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-06 00:34:04 +00:00
Sergey Biryukov
87f464c283 Plugins: Use include_once instead of include in uninstall_plugin(), in case the plugin file is already included.
Props valchovski, pcfreak30.
Fixes #47796.
Built from https://develop.svn.wordpress.org/trunk@48326


git-svn-id: http://core.svn.wordpress.org/trunk@48095 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 20:32:03 +00:00
Dominik Schilling
56afcf2d68 Posts: Provide a HiDPI version for the avatar used in post locked dialogs.
Props wpdesk, audrasjb, ocean90.
Fixes #39633.
Built from https://develop.svn.wordpress.org/trunk@48318


git-svn-id: http://core.svn.wordpress.org/trunk@48087 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 13:00:07 +00:00
Sergey Biryukov
201c7fbf97 Administration: Bring the update nag in line with other admin notices.
In addition to more consistent display, this gives it a visible border on the About page.

Props desrosj, nikhilbhansi, afercia, SergeyBiryukov.
Fixes #50372.
Built from https://develop.svn.wordpress.org/trunk@48316


git-svn-id: http://core.svn.wordpress.org/trunk@48085 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 11:57:04 +00:00
Dominik Schilling
5b7774722e Users: Pass the WP_User object to the wpmu_delete_user, delete_user, and deleted_user actions.
See #43232.
Built from https://develop.svn.wordpress.org/trunk@48313


git-svn-id: http://core.svn.wordpress.org/trunk@48082 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-05 10:57:01 +00:00
Sergey Biryukov
6adad022e2 Docs: Correct spelling of "backward compatibility" per the Core Contributor Handbook glossary.
Follow-up to [45232].

See #49572.
Built from https://develop.svn.wordpress.org/trunk@48302


git-svn-id: http://core.svn.wordpress.org/trunk@48071 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-04 20:42:06 +00:00
Sergey Biryukov
43cbe21a3e Administration: Use HTTPS for XHTML Friends Network URL.
Props raajtram, jrf, passoniate, bookdude13, sabernhardt, audrasjb.
Fixes #48002.
Built from https://develop.svn.wordpress.org/trunk@48292


git-svn-id: http://core.svn.wordpress.org/trunk@48061 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-04 09:33:01 +00:00
Andrew Ozz
86317e3e85 Media: Show an error message when a .heic file is uploaded that this type of files cannot be displayed in a web browser and suggesting to convert to JPEG. The message is shown by using filters, plugins that want to handle uploading of .heic files can remove it.
Props mattheweppelsheimer, mikeschroder, jeffr0, andraganescu, desrosj, azaozz.
Fixes #42775.
Built from https://develop.svn.wordpress.org/trunk@48288


git-svn-id: http://core.svn.wordpress.org/trunk@48057 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-03 23:15:03 +00:00
Sergey Biryukov
054610e276 Text Changes: Remove use of "normal" in user-facing output.
This clarifies some messages referring to Site Health checks and maintenance mode, and makes them more accurate.

Props dartiss.
Fixes #50549.
Built from https://develop.svn.wordpress.org/trunk@48287


git-svn-id: http://core.svn.wordpress.org/trunk@48056 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-03 21:59:03 +00:00
Sergey Biryukov
8e43a329d4 Privacy: Hide views that have a count of 0 on privacy request tables, for consistency with other list tables.
Props pbiron, garrett-eclipse, mapk, melchoyce, estelaris.
Fixes #47495.
Built from https://develop.svn.wordpress.org/trunk@48284


git-svn-id: http://core.svn.wordpress.org/trunk@48053 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-03 16:28:04 +00:00
Andrea Fercia
b8e3d63fdd Accessibility: Plugins: Accessibility and CSS improvements for the Plugins pages.
- improves checkboxes alignment on the "Plugins" page table in the responsive view 
- improves spacing between form controls on the "Add Plugins" page in the responsive view 
- the layout of the "filter bar" on the "Add Plugins" page is now based on CSS Flexbox 
- removes italic type from a paragraph in the "Favorites" page

Props passoniate, garethgillman, maxpertici, audrasjb, sabernhardt, afercia.
See #47327.
Fixes #49231.

Built from https://develop.svn.wordpress.org/trunk@48281


git-svn-id: http://core.svn.wordpress.org/trunk@48050 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-03 08:51:05 +00:00
youknowriad
bbe8f41de2 Color schemes: Add new modern color scheme option.
This PR adds a new color scheme option, which uses a high luminosity blue spot color, almost-black menu, and pure white for menu items. 
This helps increase contrast, and bring more consistency with some of the higher contrast colors used in the block editor.

Props joen, ibdz, shaunandrews.
Fixes #50504.

Built from https://develop.svn.wordpress.org/trunk@48277


git-svn-id: http://core.svn.wordpress.org/trunk@48046 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-02 14:55:05 +00:00