Commit Graph

24445 Commits

Author SHA1 Message Date
Sergey Biryukov
7244fe456e Editor: Add title and description to post format archive block templates.
Follow-up to [52062], [52331], [55500].

Props poena, rinkalpagdar, im3dabasia1, parthvataliya, ruchirj, praful2111.
Fixes #62326.
Built from https://develop.svn.wordpress.org/trunk@59819


git-svn-id: http://core.svn.wordpress.org/trunk@59161 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-13 20:31:28 +00:00
Felix Arntz
19f101215e Pings/Trackbacks: Add return value to pingback().
This facilitates debugging and better response / error handling, among other things.

Props audrasjb, coquardcyr, dshanske, ironprogrammer, NathanAtmoz, pbearne, shulard, soulseekah.
Fixes #38197.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59160 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-12 23:45:25 +00:00
spacedmonkey
ec604f4ae0 Users: Add caching to count_user_posts function
Introduced caching for the `count_user_posts` function to reduce redundant database queries. This ensures better performance by storing and reusing query results when possible. Additionally, sanitized and sorted the `$post_type` array to avoid invalid queries.

Props spacedmonkey, peterwilsoncc, mamaduka, flixos90, johnjamesjacoby, swissspidy, dilip2615, johnregan3, wpgurudev, desrosj, milindmore22, Krstarica, dilipom13.
Fixes #39242.
Built from https://develop.svn.wordpress.org/trunk@59817


git-svn-id: http://core.svn.wordpress.org/trunk@59159 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-12 21:50:28 +00:00
Sergey Biryukov
9724765081 Coding Standards: Correct default values in WP_Post to match the documented type.
Follow-up to [22264], [25086].

See #62279.
Built from https://develop.svn.wordpress.org/trunk@59816


git-svn-id: http://core.svn.wordpress.org/trunk@59158 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-12 18:11:25 +00:00
John Blackbourn
936cc23ca5 Build/Test Tools: Add a workflow that tests the process of upgrading WordPress to a build of the current branch.
This complements the existing workflow which tests upgrading to an already released version.

Props johnbillion, peterwilsoncc, mukesh27, desrosj, audrasjb, joemcgill.

See #62221
Built from https://develop.svn.wordpress.org/trunk@59815


git-svn-id: http://core.svn.wordpress.org/trunk@59157 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-12 15:01:24 +00:00
Peter Wilson
2766df98d2 Editor: Fix complex variation selectors when using selectors API.
Fixes a bug in the manipulation of selectors for block style variations that would result in an incorrect selector and fail to match the appropriate elements on the frontend.

Props aaronrobertshaw, ramonopoly, joemcgill.
Fixes #62471.


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


git-svn-id: http://core.svn.wordpress.org/trunk@59156 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-12 03:40:23 +00:00
audrasjb
737185823f Themes: Avoid double hashed value for background-color in custom backgrounds.
This changeset replaces the hardcoded hash symbol with running `maybe_hash_hex_color()` on the full `background-color` value provided via the custom background feature, so the hash is only added if it is needed. By doing so, if a theme developer sets a background color value that uses a hash (#), WordPress won't add an additional hash anymore when outputting the relevant CSS. Duplicate hash symbols (##) can break CSS background color declarations.

Props hovhanneshovakimyan, joyously, poena, 
Fixes #40057.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59155 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-11 21:06:25 +00:00
Weston Ruter
08c4498647 HTML API: Stop counting no-op seek operations against the max seek count.
This allows `seek()` to be freely called when the current cursor at the provided bookmark.

Props dmsnell, jonsurrell, westonruter.
Fixes #62085.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59154 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-11 20:04:23 +00:00
desrosj
5f79466650 Bundled Themes: Bump version of Twenty Twenty-Five to 1.1.
Fixes #62943.
Built from https://develop.svn.wordpress.org/trunk@59809


git-svn-id: http://core.svn.wordpress.org/trunk@59151 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-11 16:56:24 +00:00
davidbaumwald
40d50ca185 General: Remove duplicate type="button" attribute from the "Change|Choose Site Icon" button.
Introduced in [57602].

Props kkmuffme, audrasjb.
Fixes #62942.
Built from https://develop.svn.wordpress.org/trunk@59806


git-svn-id: http://core.svn.wordpress.org/trunk@59148 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-11 15:57:21 +00:00
Sergey Biryukov
0909a94115 Coding Standards: Correct default values in WP_Comment to match the documented type.
Follow-up to [33891], [48941].

See #62279.
Built from https://develop.svn.wordpress.org/trunk@59805


git-svn-id: http://core.svn.wordpress.org/trunk@59147 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-11 13:40:30 +00:00
John Blackbourn
47fe3123b4 Security: Delete a test file that was missed in [59803].
Props swissspidy.

See #60638, #62815, #56017
Built from https://develop.svn.wordpress.org/trunk@59804


git-svn-id: http://core.svn.wordpress.org/trunk@59146 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-11 12:18:23 +00:00
John Blackbourn
bb832dcfef Security: Explicitly require the hash PHP extension and add requirement checks during installation and upgrade.
This extension provides the `hash()` function and support for the SHA-256 algorithm, both of which are required for upcoming security related changes. This extension is almost universally enabled, however it is technically possible to disable it on PHP 7.2 and 7.3, hence the introduction of this requirement and the corresponding requirement checks prior to installing or upgrading WordPress.

Props peterwilsoncc, ayeshrajans, dd32, SergeyBiryukov, johnbillion.

Fixes #60638, #62815, #56017

See #21022
Built from https://develop.svn.wordpress.org/trunk@59803


git-svn-id: http://core.svn.wordpress.org/trunk@59145 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-11 11:14:21 +00:00
Peter Wilson
9f83001243 Global Styles: Improve sanitization of block variation styles.
Fixes an issue where block style variations containing inner block type and element styles would have those inner styles stripped when the user attempting to save Global Styles does not have the `unfiltered_html` capability.

Props aaronrobertshaw, mukesh27, andrewserong.
Fixes #62372.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59144 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-10 22:29:22 +00:00
Peter Wilson
d4822bd3c5 REST API: Add support for the ignore_sticky_posts argument.
Introduce `ignore_sticky` as a boolean argument for the posts endpoint for requests without the sticky posts being stuck. The new argument defaults to `false` with the value of the argument passed to `WP_Query`'s `ignore_sticky_posts` parameter.

Props audrasjb, danielbachhuber, joemcgill, johnbillion, jorbin, mamaduka, rmccue.
Fixes #35907.


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


git-svn-id: http://core.svn.wordpress.org/trunk@59143 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-10 22:23:23 +00:00
John Blackbourn
0ac2a96887 Administration: Correct the capitalisation of "site administrator" for consistency with other instances within WordPress.
Follow-up to [59799].

Props ocean90

Fixes #48879
Built from https://develop.svn.wordpress.org/trunk@59800


git-svn-id: http://core.svn.wordpress.org/trunk@59142 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-10 17:06:23 +00:00
John Blackbourn
e1c2d3f420 Administration: Remove a potentially incorrect addressee and improve the phrasing used in the confirmation email when a user attempts to change the administration email address.
Props MadtownLems, ilovecats7, rehanali, iflairwebtechnologies, thehercules

Fixes #48879
Built from https://develop.svn.wordpress.org/trunk@59799


git-svn-id: http://core.svn.wordpress.org/trunk@59141 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-10 15:31:22 +00:00
John Blackbourn
cf4686e4b6 Cron API: Clear the recovery_mode_clean_expired_keys cron event when converting a single site installation to Multisite.
This cron event is not used when Multisite is in use.

Props debarghyabanerjee, johnbillion, narenin

Fixes #61450
Built from https://develop.svn.wordpress.org/trunk@59798


git-svn-id: http://core.svn.wordpress.org/trunk@59140 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-10 15:01:23 +00:00
desrosj
caaf76b11e Build/Test Tools: Remove matchdep as a dependency.
`matchdep` was introduced in [25243] to more easily manage `grunt-*` dependencies. The package has effectively been abandoned upstream, and the functionality can be replaced with a simple loop.

Props desrosj, spacedmonkey, swissspidy.
See #62221.
Built from https://develop.svn.wordpress.org/trunk@59797


git-svn-id: http://core.svn.wordpress.org/trunk@59139 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-10 14:30:26 +00:00
Sergey Biryukov
b87e7301ad Coding Standards: Use strict comparison in WP_Query::the_comment() and ::have_comments().
Follow-up to [4934].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59796


git-svn-id: http://core.svn.wordpress.org/trunk@59138 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-10 10:51:25 +00:00
Peter Wilson
096c95390c Editor: Preload Global Styles REST requests based on user permissions.
For the Post Editor, preload '/wp/v2/global-styles/' . $global_styles_id with a context corresponding to user caps, that is, 'edit' for users that can edit global styles, and 'view' for everyone else.

Preloading the global styles endpoint according to role context means that admins and non admins, e.g., editors, avoid unnecessary client side requests.

Props ramonopoly.
Fixes #62322.


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


git-svn-id: http://core.svn.wordpress.org/trunk@59137 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-10 03:56:23 +00:00
Peter Wilson
e92abc0735 Site Editor: Redirect deprecated URLs to path based routing.
The site editor now uses path based routing rather than query string arguments. This redirects the legacy query string URLs to the new routing.

Props youknowriad, peterwilsoncc, joemcgill, mukesh27, poena.
Fixes #62585.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59136 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-10 02:40:23 +00:00
Peter Wilson
c101e1b5b2 Editor: Update enqueued styles in the editor.
Updates the enqueued styles in various editors to remove target styles more precisely to where they are needed.

Removes the following stylesheets as dependencies of `wp-edit-blocks`:

* `wp-editor`
* `wp-reusable-blocks`
* `wp-patterns`

The `wp-editor` stylesheet is targeted to the items requiring the CSS:

* `edit-widgets`
* `customize-widgets`
* `edit-site`

Props ellatrix, youknowriad.
Fixes #62266, #62274.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59135 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-09 22:34:23 +00:00
Sergey Biryukov
770eb818a4 Coding Standards: Use strict comparison in WP_Query::the_post() and ::have_posts().
Follow-up to [2716], [2741], [11464].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59792


git-svn-id: http://core.svn.wordpress.org/trunk@59134 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-09 18:51:21 +00:00
audrasjb
fdb545356c Administration: Replace missed references of "Add New" in WP_Post_Type class.
Follow-up to [59784], [59786].

Fixes #61219.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59133 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-09 11:09:21 +00:00
audrasjb
6309ca8f17 General: Error messages improvements in /wp-includes files.
This changeset improves a bunch of error messages, notably replacing the good old cryptic "Something went wrong" message with more helpful information.

Props peterwilsoncc, netweb, karmatosed, JoshuaWold, mrtortai, audrasjb, sukhendu2002, joedolson.
Fixes #43622.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59132 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-08 16:00:19 +00:00
audrasjb
c5293a0be9 Administration: Error messages improvements in WP Admin.
This changeset improves a bunch of WP-Admin error messages, notably replacing the good old cryptic "Something went wrong" message with more helpful information.

Props peterwilsoncc, netweb, karmatosed, JoshuaWold, mrtortai, audrasjb, sukhendu2002, joedolson.
See #43622.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59131 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-08 15:53:17 +00:00
Sergey Biryukov
d76c427a42 Coding Standards: Use strict comparison in WP_Query::is_page() and ::is_single().
Follow-up to [29039].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59788


git-svn-id: http://core.svn.wordpress.org/trunk@59130 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-08 15:32:24 +00:00
audrasjb
342c3037df Docs: Fix Docblock parameters indentation for wp_determine_option_autoload_value(), as per WP Docs standards.
See #62281.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59129 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-08 15:11:20 +00:00
audrasjb
22549e4550 Bundled Themes: Replace references to "Add New" theme screen in bundled themes readme files.
Follow-up to [59784].

Props jameskoster, audrasjb, ntsekouras, afercia, peterwilsoncc, youknowriad, joedolson, sukhendu2002, jdy68, beryldlg, fxbenard.
Fixes #61219.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59128 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-08 12:14:19 +00:00
audrasjb
ad6af7aaa9 Docs: Various Docblock fixes in wp-includes/class-wp-customize-control.php, as per WP Docs standards;
See #62281.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59127 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-08 12:00:19 +00:00
audrasjb
1498d000ba Administration: Replace "Add New {Item}" wording with "Add {Item}" across the administration.
This changeset replaces each occurrence of "Add New {Item}" label with "Add {Item}" in WordPress administration, to make the interface more consistent and simplify the translation effort.

Props jameskoster, audrasjb, ntsekouras, afercia, peterwilsoncc, youknowriad, joedolson, sukhendu2002, jdy68, beryldlg, fxbenard.
See #61219.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59126 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-08 11:44:24 +00:00
desrosj
065a43f68d General: Introduce polyfills for new array related functions in PHP 8.4.
PHP 8.4 introduced four new functions to provide a common way to more easily perform common operations on arrays.

- `array_find()`: https://www.php.net/manual/en/function.array-find.php
- `array_find_key()`: https://www.php.net/manual/en/function.array-find-key.php
- `array_all()`: https://www.php.net/manual/en/function.array-all.php
- `array_any()`: https://www.php.net/manual/en/function.array-any.php

These functions are now polyfilled making them available on all supported versions of PHP (currently 7.2+).

Props Soean, swissspidy, TobiasBg, ayeshrajans, mukesh27, joemcgill.
Fixes #62558.
Built from https://develop.svn.wordpress.org/trunk@59783


git-svn-id: http://core.svn.wordpress.org/trunk@59125 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-07 18:54:22 +00:00
Joe McGill
da8fd1d079 Editor: Add remaining query block file.
This is a follow-up to [59776] and [59775] to add yet another file that was missed in the original commit.

See #62887.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59119 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-07 16:06:20 +00:00
Joe McGill
da78d523ec Editor: Add query-total block files.
This is a follow-up to [59775] to add new files that were missed in the original commit.

See #62887.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59118 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-07 15:58:19 +00:00
Joe McGill
abb9c19aae Editor: Update packages for 6.8 pre-Betas.
Syncs @wordpress/* packages to the 'latest' npm tag.

Props mamaduka, joemcgill, youknowriad, swissspidy, sergiomdgomes, gziolo.
See #62887.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59117 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-07 15:46:48 +00:00
Sergey Biryukov
aa804df692 Coding Standards: Use strict comparison in wp_get_archives().
Follow-up to [24], [114].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59774


git-svn-id: http://core.svn.wordpress.org/trunk@59116 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-07 15:08:23 +00:00
Joe McGill
c7db6678d7 Post Thumbnails: Fix squashed featured image in wp-admin.
This updates the CSS for featured images in the classic editor that caused images to look skewed when auto-sizes are enabled.

Props maciejmackowiak, sainathpoojary, mukesh27, joemcgill.
Fixes #62597.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59115 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-07 14:36:23 +00:00
joedolson
dd3d84dfbc General: Add styles for extender usage of do_accordion_section().
Follow up to [59224]. Add CSS to cover usage of the `do_accordion_section()` function when used in extender contexts outside of the existing WordPress core usage.

Props mboynes, jorbin, joemcgill, joedolson. 
Fixes #62907.
Built from https://develop.svn.wordpress.org/trunk@59772


git-svn-id: http://core.svn.wordpress.org/trunk@59114 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-06 22:26:24 +00:00
Peter Wilson
55f06e4f34 Query: Add since annotation to WP_Query::$query_cache_key.
Follow up to [59766].

Props mukesh27.
See #59516.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59113 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-06 20:58:23 +00:00
desrosj
16bc9210d6 External Libraries: Remove stray Unicode character in moxie.js
This fixes a `ReferenceError` caused by a stray Unicode character in the unminified version of moxie.js. This has long been fixed upstream but the library cannot be wholesale updated in WordPress because of an incompatible license change.

Because of this, a new version is being tagged, `1.3.5.1`, and the file header has been updated to make it more clear that the file is a maintained fork with a high level list of changes made.

Props kinggmobb, jorbin, q0rban, azaozz, desrosj, sukhendu2002.
Fixes #59329.
Built from https://develop.svn.wordpress.org/trunk@59770


git-svn-id: http://core.svn.wordpress.org/trunk@59112 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-06 18:29:22 +00:00
desrosj
da65b76f52 Import: Remove Importer plugin related unit tests.
The WordPress Importer plugin has been maintained separately in a repository on GitHub since 2016. However, the unit tests were left in wordpress-develop due to the lack of a CI setup on GitHub.

With GitHub Actions set up for the plugin repository, these tests are now running in two locations. Because they are more relevant to the plugin itself, the tests have been synced, will run weekly through a `schedule` event, and are now being removed from wordpress-develop.

The only remaining test method in the `import` group covers `get_importers()`, which is a function maintained in WordPress Core itself.

Props frank-klein, netweb, dd32, peterwilsoncc, azaozz, desrosj, swissspidy.
Fixes #42668.
Built from https://develop.svn.wordpress.org/trunk@59769


git-svn-id: http://core.svn.wordpress.org/trunk@59111 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-06 17:53:20 +00:00
desrosj
1da5ba567f Build/Test Tools: Configure UglifyJS to preserve previous behavior.
As of UglifyJS >= 3.18.0, the default behavior is to process input as an ES module. This updates the relevant configurations to ensure the build process continues to use the previous behavior to avoid JavaScript errors in the minified versions of files.

Follow up to [58563], [58586], and [59509].

Props siliconforks, nataliat2004, poena, mai21, SergeyBiryukov.
Fixes #62767. See #61519, #62220.
Built from https://develop.svn.wordpress.org/trunk@59768


git-svn-id: http://core.svn.wordpress.org/trunk@59110 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-06 17:27:26 +00:00
Sergey Biryukov
f548f56548 Coding Standards: Use strict comparison in media_upload_library_form().
Includes bringing some consistency with a similar fragment in `WP_List_Table::months_dropdown()`.

Follow-up to [3724], [7062], [15491], [59755].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59767


git-svn-id: http://core.svn.wordpress.org/trunk@59109 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-06 12:24:24 +00:00
Peter Wilson
38025026ac Query: Increase WP_Query cache hits for equivalent arguments.
Introduces normalization a number of arguments passed to `WP_Query` to increase cache hits for equivalent requests. For example `author__in => [ 1, 2 ]` and `author__in => [ 2, 1 ]` will now hit the same cache.

Prior to generating the SQL request and cache key, the following are sorted, made unique and type cast as appropriate.

* `post_type` when passed as an array
* `post_status` when passed as an array
* `term_query`s containing `terms`
* `cat`
* `category__in`
* `category__not_in`
* `category__and`
* `tag_slug__in`
* `tag__in`
* `tag__not_in`
* `tag__and`
* `tag_slug__in`
* `tag_slug__and`
* `post_parent__not_in`
* `author`
* `author__not_in`
* `author__in`

The following are sorted for the purposes of generating the cache key and SQL `WHERE` clause but unmodified for use in the `ORDER BY` SQL clause:

* `post_name__in`
* `post__in`
* `post_parent__in`

This commit includes changes to unrelated tests, assertions in  `Tests_Query_ParseQuery::test_parse_query_cat_array_mixed()` and `WP_Test_REST_Posts_Controller::test_get_items_not_sticky_with_exclude()` have been modified to account for the sorting of the items above.

Props thekt12, peterwilsoncc, spacedmonkey, joemcgill, flixos90, mukesh27, pbearne, swissspidy.
Fixes #59516.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59108 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-06 05:04:24 +00:00
Sergey Biryukov
99ef157227 Docs: Update comments in wp-includes/formatting.php per the documentation standards.
Follow-up to [1345], [8662], [8786], [33624], [34761].

Props kapasias, ankitkumarshah, swissspidy, peterwilsoncc.
Fixes #62885.
Built from https://develop.svn.wordpress.org/trunk@59765


git-svn-id: http://core.svn.wordpress.org/trunk@59107 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-05 23:53:25 +00:00
Mamaduka
5b8a20d134 Editor: Fix parents argument validation for Query block.
Allow passing zero (`0`) via the `parents` argument. It is a valid value for hierarchical post types, often used to display top-level items.

Props mamaduka, audrasjb, peterwilsoncc.
Fixes #62901.
Built from https://develop.svn.wordpress.org/trunk@59761


git-svn-id: http://core.svn.wordpress.org/trunk@59103 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-04 09:01:17 +00:00
audrasjb
e1877c1c42 Editor: Add a fallback to WP_Block_Styles_Registry if the label is missing.
Both `name` and `label` properties are required when registering a block style. If the label is missing, assign `name` as the value for the `label`, to ensure the property is defined. This avoids a PHP warning in such case.

Props poena, Rahmohn, aaronrobertshaw, audrasjb, rinkalpagdar.
Fixes #52592.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59102 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-04 08:42:25 +00:00
Sergey Biryukov
7975d2c6c3 Docs: Correct DocBlock formatting for the_password_form filter.
Follow-up to [59736], [59737].

See #62281.
Built from https://develop.svn.wordpress.org/trunk@59756


git-svn-id: http://core.svn.wordpress.org/trunk@59098 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-04 00:32:23 +00:00
Sergey Biryukov
6e0285406d Coding Standards: Use a more meaningful variable name in WP_List_Table::months_dropdown().
As per the [https://developer.wordpress.org/coding-standards/wordpress-coding-standards/php/#naming-conventions Naming Conventions]:
> Don't abbreviate variable names unnecessarily; let the code be unambiguous and self-documenting.

Follow-up to [8646], [15491].

See #62279.
Built from https://develop.svn.wordpress.org/trunk@59755


git-svn-id: http://core.svn.wordpress.org/trunk@59097 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-03 23:43:21 +00:00
John Blackbourn
b765f8b44c Security: Add the SensitiveParameter attribute to sensitive parameters.
Values passed to parameters with this attribute will be redacted if present in a stack trace when using PHP 8.2 or later. This reduces the chance that passwords and security keys get accidentally exposed in debug logs and bug reports.

Props petitphp, TobiasBg, jrf, johnbillion.

Fixes #57304
Built from https://develop.svn.wordpress.org/trunk@59754


git-svn-id: http://core.svn.wordpress.org/trunk@59096 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-03 19:52:24 +00:00
John Blackbourn
ec037b17fa Posts, Post Types: Explicitly pass a redirect URL for the post permalink when submitting the post password form.
This allows the subsequent redirect to behave as expected if a site is using a strict referrer policy on the front end which prevents the full referrer from being sent.

Props zodiac1978, yogeshbhutkar, hbhalodia, mukesh27.

Fixes #62881
Built from https://develop.svn.wordpress.org/trunk@59753


git-svn-id: http://core.svn.wordpress.org/trunk@59095 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-03 16:55:23 +00:00
John Blackbourn
b39c7d7b4b Build/Test Tools: Fix the source code path handling when installing the local development environment.
This ensures the correct code is used to run the installation depending on whether it should be running from the `src` or `build` directory.

Props swissspidy, johnbillion

See #62221
Built from https://develop.svn.wordpress.org/trunk@59752


git-svn-id: http://core.svn.wordpress.org/trunk@59094 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-03 13:37:25 +00:00
Sergey Biryukov
d78ac132af Coding Standards: Use strict comparison in get_media_item().
Follow-up to [12081], [12351].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59751


git-svn-id: http://core.svn.wordpress.org/trunk@59093 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-02 11:17:24 +00:00
Sergey Biryukov
6e26ca2648 Coding Standards: Use strict comparison in some legacy media functions.
Follow-up to [7062], [8653], [12188].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59750


git-svn-id: http://core.svn.wordpress.org/trunk@59092 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-01 20:52:19 +00:00
John Blackbourn
fc294e0fed Build/Test Tools: Parallelise the performance tests.
This change introduces a job matrix for the "current", "before", and "base" performance tests to replace the current behaviour of running them sequentially in a single job. This speeds up the overall performance testing workflow and also reduces the chance of any given test interfering with another, for example by making a change to data in the database that affects a subsequent test.

Props johnbillion, swissspidy, dmsnell, joemcgill.

See #62221
Built from https://develop.svn.wordpress.org/trunk@59749


git-svn-id: http://core.svn.wordpress.org/trunk@59091 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-02-01 20:17:22 +00:00
Sergey Biryukov
dc2513850f Coding Standards: Replace loose comparison in wp_xmlrpc_server::wp_setOptions().
Follow-up to [8114].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59748


git-svn-id: http://core.svn.wordpress.org/trunk@59090 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-31 21:54:23 +00:00
Aaron Jorbin
4be161e473 Documentation: Update @since to reflect version this might ship in.
When originally committed, this code was targeting 6.7.1. However, it was not backported and included in 6.7.1. Will this be followed up by another version change? You'll need to stay tuned to next week's episode of "As the WordPress Turns" to find out!

Follow-up to [59285] and [59364].

See #62270.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59089 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-31 02:22:23 +00:00
joedolson
2b1dffc900 Administration: Fix undefined element JS error in pagination handler.
Follow up to [59727]. Handle cases where the `#current-page-selector` is not present on the page to prevent a JS warning.

Props tobiasbg, mamaduka, jorbin, joedolson. 
See #62534.
Built from https://develop.svn.wordpress.org/trunk@59746


git-svn-id: http://core.svn.wordpress.org/trunk@59088 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-30 23:38:23 +00:00
Felix Arntz
e8064c7478 Editor: Fix block template registration failing for custom post types containing underscore characters.
Custom post types may contain underscores, however block template registration has been using a regular expression that disallows underscores. Since the block template name for certain templates is directly associated with which post type it applies to, this regular expression was causing unexpected failures. This changeset adjusts the regular expression to allow block template names with underscore characters, effectively allowing block templates to be registered for any custom post type.

Props alexandrebuffet, ankitkumarshah, gaambo, jorbin, karthickmurugan, oglekler, poena, sukhendu2002.
Fixes #62523.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59084 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-30 21:19:25 +00:00
desrosj
6db739937a Security: Introduce Grunt task for updating Root Certificates.
The Root Certificate bundle maintained by Mozilla ships in WordPress to allow SSL certificates to be verified on hosts with incomplete, outdated, or invalid local SSL configurations. To date, updates have only been merged into Core when problems arise using a highly manual process.

This introduces the `certificates:upgrade` Grunt task to automate the process of updating the included bundle with upstream changes using Composer to manage versioning.

The legacy 1024bit certificates included for backwards compatibility are now maintained in a separate file that is prepended to the built version of the bundle during the relevant Grunt tasks. Some expired certificates from this list have been removed:

- Cybertrust Global Root (expired 2021-12-15)
- Thawte Server CA (expired 2020-12-31)
- Thawte Premium Server CA (expired 2020-12-31)

The Dependabot configuration has also been updated to open pull requests when new releases occur upstream. Going forward, the recommendation is to create a task ticket for updating these certificates with each release when an update is published. See #62811 for an example of this.

Props johnbillion, desrosj, whyisjake, ayeshrajans, SergeyBiryukov, swissspidy, skithund, barry.
Fixes #62812. See #62811, 50828.
Built from https://develop.svn.wordpress.org/trunk@59740


git-svn-id: http://core.svn.wordpress.org/trunk@59082 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-30 18:53:27 +00:00
Aaron Jorbin
a7824e772c Build/Test: Update assertions in AtomParser_Parse_Test::test_parse_sets_handlers
On some instances of Windows, the assertions seem to find additional nodes. As this test is just about verifying that the handlers get called, not about testing the functionality of the handlers, we can adjust the assertion to look for a minimum number of nodes rather than exact number.

Follow-up to [59062].

Props yogeshbhutkar, hellofromTonya, SergeyBiryukov, coquardcyr, jrf, benniledl, desrosj, jorbin.
Fixes #62110. See #62061.


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


git-svn-id: http://core.svn.wordpress.org/trunk@59081 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-30 17:54:24 +00:00
Sergey Biryukov
96f36e1c34 Coding Standards: Use strict comparison in wp_xmlrpc_server::wp_getUsersBlogs().
Includes a micro-optimization to avoid calling `get_current_network_id()` in a loop.

Follow-up to [8075], [9798], [26120], [38814].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59738


git-svn-id: http://core.svn.wordpress.org/trunk@59080 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-30 11:22:22 +00:00
joedolson
bd502b5d96 Docs: Add missing $text filter argument.
Fix omitted filter argument variable name for `the_password_form_incorrect_password`. Follow up to [59736].

Props mukesh27, joedolson. 
See #37332.
Built from https://develop.svn.wordpress.org/trunk@59737


git-svn-id: http://core.svn.wordpress.org/trunk@59079 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-30 04:08:22 +00:00
joedolson
6def2dc42c Accessibility: Add invalid password message for post passwords.
Display a message notifying the user of an incorrect password when submitting the post password form. Improve the accessibility of the form by adding a required attribute for consistent identification.

Props henry.wright, jonnyauk, kreppar, tommusrhodus, joedolson, audrasjb, jdahir0789, parthvataliya, dhruvang21. 
Fixes #37332.
Built from https://develop.svn.wordpress.org/trunk@59736


git-svn-id: http://core.svn.wordpress.org/trunk@59078 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-30 03:56:26 +00:00
Peter Wilson
3bc4da6267 Options/Meta APIs: Rename setted_(site_)_transient to set_....
Deprecate the actions `setted_transient` and `setted_site_transient` in favour of `set_transient` and `set_site_transient` respectively.

This serves two purposes, the name is consistent with the transient specific actions `set_(site_)_transient_{$transient}`, and to make the names grammatically correct.

Props sukhendu2002, swissspidy, johnbillion, peterwilsoncc.
Fixes #62849.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59077 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-30 00:02:18 +00:00
audrasjb
ac5aaad84e Docs: Improve docblock for rest_menu_read_access filter.
Follow-up to [59718].

See #62281, #54304.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59076 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-29 23:15:23 +00:00
audrasjb
34458b5bca Coding standards: Remove unused variables from privacy_policy_guide() function.
See #62279.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59075 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-29 21:54:23 +00:00
audrasjb
6376a8f6f7 Privacy: Replace Policy Name with an auto increment to avoid internationalized plugin name issues.
This changeset replaces plugin sanitized names with an auto increment integer to fix an issue with accordions displaying privacy policies for plugins with special characters in their names.

Follow-up to [50161].

Props ecgan, sabernhardt, audrasjb.
Fixes #62713.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59074 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-29 21:35:19 +00:00
Felix Arntz
49e835dd8a Editor: Relax restrictions around registration of block metadata collections.
This changeset allows for block metadata collections to be registered for almost any source, such as MU plugins, themes, or custom directories with e.g. symlinked plugins or symlinked themes. Prior to the change, block metadata collections could only be registered for plugins and WordPress Core.

There are still safeguards in place to prevent registration of collections in locations that would cause conflicts. For example, it is not possible to register a collection for the entire `wp-content/plugins` directory or the entire `wp-content/themes` directory, since such a collection would conflict with any specific plugin's or theme's collection. In case developers would like to enable this safeguard for their own custom directories, they can use the new `wp_allowed_block_metadata_collection_roots` filter.

Props assassinateur, bowedk, desrosj, dougwollison, flixos90, glynnquelch, gziolo, jorbin, mreishus, swissspidy.
Fixes #62140.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59072 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-29 19:41:23 +00:00
John Blackbourn
6b9fffb369 Build/Test Tools: Add a retry mechanism for tests that perform external HTTP requests.
While the `skipTestOnTimeout()` method will catch a timeout and prevent it from causing a test to fail, other errors such as a failed DNS lookup or HTTPS handshake can still cause a test to unnecessarily fail. This introduces a simple retry mechanism that will hopefully further reduce the flakiness of tests that perform HTTP API requests.

Fixes #62830
Built from https://develop.svn.wordpress.org/trunk@59729


git-svn-id: http://core.svn.wordpress.org/trunk@59071 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-29 18:19:21 +00:00
John Blackbourn
87d88ab387 Posts, Post Types: Add no-cache headers to password protected posts.
This instructs an intermediate cache, for example a proxy server, to not cache a password protected post both before and after a visitor has entered a password.

Props brevilo, haozi, ironprogrammer, narenin

Fixes #61711
Built from https://develop.svn.wordpress.org/trunk@59728


git-svn-id: http://core.svn.wordpress.org/trunk@59070 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-29 18:12:25 +00:00
joedolson
7b5f5f727a Administration: Fix pagination in categories, tags, and plugins tables.
Fix an issue introduced in [59134] that prevented manual entry of a page number in the pagination input field from navigating pages. Requiring validation of the bulk actions input also impacted other inputs nested in the same form.

Also fixes a pre-existing bug where it was not possible to navigate to page 1 using the input field.

Props ffffelix, im3dabasia1, apermo, rishavdutta, joedolson, swissspidy, jorbin, joedolson.
Fixes #62534.
Built from https://develop.svn.wordpress.org/trunk@59727


git-svn-id: http://core.svn.wordpress.org/trunk@59069 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-29 17:40:21 +00:00
Sergey Biryukov
16a13a7f40 Coding Standards: Use strict comparison in wp_xmlrpc_server::set_custom_fields().
Follow-up to [40692].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59726


git-svn-id: http://core.svn.wordpress.org/trunk@59068 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-29 14:46:23 +00:00
John Blackbourn
ea9c114c98 Build/Test Tools: Add some more paths restrictions to GitHub Actions workflow files to minimise unnecessary workflow runs.
Props mukesh27, johnbillion

See #62280
Built from https://develop.svn.wordpress.org/trunk@59725


git-svn-id: http://core.svn.wordpress.org/trunk@59067 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-28 23:49:30 +00:00
John Blackbourn
31c811c962 Security: Always include the no-store and private directives in the Cache-Control header when setting headers that prevent caching.
The intention of these headers is to prevent any form of caching, whether that's in the browser or in an intermediate cache such as a proxy server. These directives instruct an intermediate cache to not store the response in their cache for any user – not just for logged-in users.

This does not affect the caching behaviour of assets within a page such as images, CSS, and JavaScript files.

Props kkmuffme, devansh2002, johnbillion.

Fixes #61942
Built from https://develop.svn.wordpress.org/trunk@59724


git-svn-id: http://core.svn.wordpress.org/trunk@59066 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-28 23:22:22 +00:00
Sergey Biryukov
5d4148c10d Coding Standards: Use strict comparison in wp_xmlrpc_server::mw_editPost().
Follow-up to [5281], [19914], [31983].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59723


git-svn-id: http://core.svn.wordpress.org/trunk@59065 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-28 22:45:21 +00:00
desrosj
c8f766843f Build/Test Tools: Adjust the check for runner type when creating a ZIP file.
Because the build process test workflow accepts an input for runner image, older workflows still use `ubuntu-latest`. This adjusts a conditional check to be more broad, allowing any `ubuntu-` image to match.

Follow up to [59720].

See #62221.
Built from https://develop.svn.wordpress.org/trunk@59722


git-svn-id: http://core.svn.wordpress.org/trunk@59064 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-28 16:20:23 +00:00
desrosj
484c43a0b8 Build/Test Tools: Avoid using *-latest tags for runner images.
While using the `ubuntu-latest`, `macos-latest`, and `windows-latest` runner image tags is convenient, it has proven to be problematic in a number of instances as the runners are slowly updated (see #62808 and #62843).

This switches all workflows to using specific version tags representing the latest non-preview versions, which currently are as follows:
- `ubuntu-24.04`
- `windows-2022`
- `macos-14`

Props swissspidy, johnbillion.
See #62221.
Built from https://develop.svn.wordpress.org/trunk@59720


git-svn-id: http://core.svn.wordpress.org/trunk@59062 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-28 14:02:27 +00:00
audrasjb
5e389c179e Coding Standards: Add missing global variable in determine_locale() docblock.
Props upadalavipul, mukesh27, dhruvang21.
Fixes #62875.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59061 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-28 09:46:29 +00:00
spacedmonkey
12a2275de7 REST API: Introduce filter for controlling menu read access.
The menu, menu item, and menu location endpoints were added to the REST API in [52079]. In that commit, menu data was treated as private and restricted to logged-in users with the edit_theme_options capability. However, in many cases, this data can be considered public. Previously, there was no simple way for developers to allow this data to be exposed via the REST API.

This commit introduces the rest_menu_read_access filter, enabling developers to control read access to menus, menu items, and menu locations in the REST API. The same filter is applied across all three REST API classes, simplifying the process of opting into exposing this data.

Each instance of the filter provides the current request and the relevant class instance as context, allowing developers to selectively or globally enable access to the data.

Props spacedmonkey, antonvlasenko, kadamwhite, julianmar, masteradhoc.
Fixes #54304.
Built from https://develop.svn.wordpress.org/trunk@59718


git-svn-id: http://core.svn.wordpress.org/trunk@59060 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-28 04:09:22 +00:00
desrosj
1b151183d5 Build/Test Tools: Correct input name for Code Coverage reports.
The input for providing files to the `codecov/codecov-action` was changed from `file` to `files` in version `5.0.0`.

See #62221.
Built from https://develop.svn.wordpress.org/trunk@59717


git-svn-id: http://core.svn.wordpress.org/trunk@59059 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-28 03:50:23 +00:00
desrosj
316d28f0a5 Build/Test Tools: Update 3rd-party GitHub Actions.
This updates the following GitHub Actions to their latest versions:
- `actions/cache`
- `actions/checkout`
- `actions/setup-node`
- `actions/upload-artifact`
- `codecov/codecov-action`
- `shivammathur/setup-php`

See #62221.
Built from https://develop.svn.wordpress.org/trunk@59716


git-svn-id: http://core.svn.wordpress.org/trunk@59058 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-28 00:45:24 +00:00
spacedmonkey
c32b20fa60 Revisions: Use WP_Query in wp_get_post_autosave.
Replaced the raw SQL query in the `wp_get_post_autosave` function with a `WP_Query` call. This change improves code maintainability and replaces the raw SQL query with a cacheable query via `WP_Query`.

Props narenin, swissspidy, mukesh27, spacedmonkey, im3dabasia1.
Fixes #62658.
Built from https://develop.svn.wordpress.org/trunk@59715


git-svn-id: http://core.svn.wordpress.org/trunk@59057 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-27 23:07:23 +00:00
joedolson
2011617834 Administration: Fix typo in code documentation in wp/sanitize.js.
Change "Text to have the HTML tags striped out of." to "Text to strip the HTML tags from."

Replaces an unclear statement with a typo with a more clear statement.

Props joedolson, mukesh27, dhruvang21.
Fixes #62851.
Built from https://develop.svn.wordpress.org/trunk@59714


git-svn-id: http://core.svn.wordpress.org/trunk@59056 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-27 19:25:25 +00:00
Sergey Biryukov
16ee06cba1 Coding Standards: Use strict comparison in wp_xmlrpc_server::mw_newPost().
Follow-up to [5281].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59713


git-svn-id: http://core.svn.wordpress.org/trunk@59055 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-27 15:45:23 +00:00
John Blackbourn
b7a73d6a45 Security: Enable the referrer policy header on the login screen.
This sets the same referrer policy of `strict-origin-when-cross-origin` that's used in the admin area to prevent a referrer being sent to other origins. This helps prevent unwanted exposure of potentially sensitive information that may be contained within the URL.

The header can be disabled if necessary by removing the `wp_admin_headers` action from the `login_init` hook.

Props kkmuffme, sagarlakhani, albatross10

Fixes #62273
See #42036
Built from https://develop.svn.wordpress.org/trunk@59712


git-svn-id: http://core.svn.wordpress.org/trunk@59054 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-27 14:41:22 +00:00
audrasjb
48ed5b3159 General: Get rid of title attributes used by get_calendar().
This changeset replaces `title` attributes with `aria-label` for weekdays in `get_calendar()` table cells.

Props sabernhardt, audrasjb, mukesh27, shailu25.
Fixes #62860.
See #24766.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59053 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-26 22:22:24 +00:00
Sergey Biryukov
906810c2db Coding Standards: Use strict comparison in wp_xmlrpc_server::_prepare_comment().
Follow-up to [20856].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59710


git-svn-id: http://core.svn.wordpress.org/trunk@59052 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-26 18:53:23 +00:00
audrasjb
cf2aebff7f Administration: Use a lighter font-weight value for settings labels.
This changeset lowers the font-weight value from `600` to `400` for labels located in the Settings screens.
This is an initial implementation of the WordPress design system, aligning with the broader goal of achieving a more consistent and unified design across the administration.

Props karmatosed, audrasjb.
Fixes #62865.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59051 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-25 23:51:24 +00:00
audrasjb
ffa50f3c7b Themes: Improve theme count behavior in the Add Themes screen.
This changeset fixes an UI issue where the theme count in the "Add Themes" screen touches the top border on small screens.

Props sukhendu2002, diliphingarajiya, dilipbheda, ankitkumarshah, dhruvang21, im3dabasia1.
Fixes #62499.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59050 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-25 17:11:23 +00:00
Sergey Biryukov
b74968d542 Coding Standards: Use strict comparison in wp_xmlrpc_server::_insert_post().
Follow-up to [19848].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59707


git-svn-id: http://core.svn.wordpress.org/trunk@59049 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-25 14:34:20 +00:00
audrasjb
130a7a8567 Plugins: Improve search box margin behavior in the Add Plugins screen.
This changeset fixes a margin issue in the search input box on the Add New Plugins screen, which was previously breaking below 1138px. Specifically, the top margin was set to 0px, and the overall appearance of the search box was inconsistent between 1000px and 1138px. Now, the margin is consistent across all breakpoints.

Props jomonthomaslobo1, narenin, iflairwebtechnologies, peterwilsoncc, audrasjb, shailu25.
Fixes #61785.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59048 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-25 14:12:19 +00:00
audrasjb
471cffffcc Administration: Introduce a lighter background for WP Admin.
This changeset replaces the light grey background color with the white color defined in the Editor Storybook. This change also impacts admin color schemes that previously utilized the default admin background color.
This is an initial implementation of the WordPress design system, aligning with the broader goal of achieving a more consistent and unified design across the administration.

Props karmatosed, audrasjb.
Fixes #62831.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59047 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-25 14:07:23 +00:00
audrasjb
e4229833fe Docs: Improve @return docblock section for get_category().
This changeset adds more details on the `WP_Term` returned by `get_category()` as it contains additional backwards compatible aliases for the era before WP 4.4 and 2.3.

Props apermo, audrasjb.
Fixes #62842.
See #62281.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59046 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-24 23:28:23 +00:00
audrasjb
b7a285e101 Posts, Post Types: Remove title attribute from the_shortlink().
Since [13683], `the_shortlink()` has included a `title` attribute. By default, that gives the sanitized post title, and it does not sanitize custom text. Given the low value of this attribute, this changeset removes it.

Props sabernhardt, audrasjb, joedolson.
Fixes #62838.
See #24766.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59045 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-24 23:00:22 +00:00
audrasjb
5a26f1452c Docs: Various Docblock fixes in wp-includes/widgets.php, as per WP Docs standards;
Props ankitpatel1578, sabernhardt.
Fixes #62859.
See #62281.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59044 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-24 21:20:23 +00:00
audrasjb
492dd1ba34 Import: Add the import_filters action hook to the Import screen.
This changeset introduces the new `import_filters` action hook at the end of the Import screen, consistently with other admin screens like `export.php`.

Props audrasjb, lenasterg.
Fixes #54419.
See #19863.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59043 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-24 14:02:21 +00:00
Pascal Birchler
6a84867ba3 Posts, Post Types: Embeds: Add new embeddable argument to post types.
This new argument, which defaults to the value of `public`, can be used to determine whether a post can be embedded using oEmbed. A new `is_post_embeddable()` function is added to easily check this.

Props pampfelimetten, swissspidy, bradleyt, DrewAPicture, gadelhas, mukesh27.
Fixes #35567.
Built from https://develop.svn.wordpress.org/trunk@59700


git-svn-id: http://core.svn.wordpress.org/trunk@59042 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-24 13:32:21 +00:00
Sergey Biryukov
e28810b49b XML-RPC: Correctly pass the ID value to wp_update_post() in ::mw_editPost().
Follow-up to [59697].

Props johnbillion.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59699


git-svn-id: http://core.svn.wordpress.org/trunk@59041 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-24 12:30:24 +00:00
audrasjb
4de28b054d Themes: Add wp-theme-<name> and wp-child-theme-<name> classes to body_class.
This changeset introduces new classes to the body tag. The classes `wp-theme-<name>` and `wp-child-theme-<name>` (when the current theme is a child theme) are added, where `<name>` represents the sanitized name of the active theme.

Props cais, GaryJ, nacin, SergeyBiryukov, johnjamesjacoby, nirajgirixd, poena, audrasjb, rinkalpagdar.
Fixes #19736.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59040 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-24 10:58:24 +00:00
Sergey Biryukov
9b1fa5c2d6 Coding Standards: Rename the $ID variable in wp_xmlrpc_server methods.
This resolves a WPCS warning:
{{{
Variable "$ID" is not in valid snake_case format, try "$i_d"
}}}

Follow-up to [28448].

See #62279.
Built from https://develop.svn.wordpress.org/trunk@59697


git-svn-id: http://core.svn.wordpress.org/trunk@59039 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-24 00:04:22 +00:00
joedolson
a429f0e6c2 Editor: Change the Text editor label to Code.
Rename the 'Text' tab of the classic editor to 'Code', mimicking the labels used in the block editor: "Visual editor" and "Code editor".
 
Update code comment and Help documentation to reference the editor using the new label.

Props lukecavanagh, ctienshi, travel_girl, audrasjb, sabernhardt, joedolson, rseigel, mark-k, sergeybiryukov, presskopp, giuriani, afercia, knutsp, audrasjb, sukhendu2002.
Fixes #38061.
Built from https://develop.svn.wordpress.org/trunk@59696


git-svn-id: http://core.svn.wordpress.org/trunk@59038 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-23 23:54:23 +00:00
joedolson
e3ae09cc69 Editor: Remove option to disable the visual editor.
Remove the option "Disable the visual editor when writing" from the user profile if it is currently false. If enabled, the option will stay available until disabled.

This was blocked due to issues with tab order and focusability in the classic editor environment until [59188].

Props mark-k, SergeyBiryukov, joedolson, pento, iseulde, chriscct7, afercia, prasadkarmalkar, rcreators, jamieblomerus.
Fixes #34681.
Built from https://develop.svn.wordpress.org/trunk@59695


git-svn-id: http://core.svn.wordpress.org/trunk@59037 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-23 22:49:23 +00:00
John Blackbourn
de74a2bbad Build/Test Tools: Correct the usage of the conclusion of the previous run within the Slack notifications workflow.
Prior to r59679 this value was echoed to GitHub output which meant that its surrounding double quotes lost their significance. Now this value is used directly in the job output it needs to be treated as a plain string.

This concludes the conclusion confusion.

See #82221

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


git-svn-id: http://core.svn.wordpress.org/trunk@59035 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-23 17:14:22 +00:00
Sergey Biryukov
0fc515b005 Docs: Correct description for the_time(), get_the_time(), and get_post_time().
This aims to avoid confusion with `the_date()` and `get_the_date()`.

Includes synchronizing the description for `the_weekday()` and `the_weekday_date()`, which have very similar functionality, except that the latter will only output the weekday if the current post's weekday is different from the previous one output.

Follow-up to [59691].

See #51289.
Built from https://develop.svn.wordpress.org/trunk@59692


git-svn-id: http://core.svn.wordpress.org/trunk@59034 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-23 00:47:22 +00:00
audrasjb
98657c10d5 Docs: Clarify the purpose of post date/time functions.
This changeset clarifies the purpose of these functions and make the documentation more accurate and flexible. Instead of referring to the "date the post was written," the functions and filter descriptions now refer to the "date of the post." This change accommodates scenarios where the displayed date might not strictly correspond to the writing date (e.g. scheduled posts, backdated posts, or content where the "date" represents something other than creation).

Props casiepa, audrasjb, SergeyBiryukov, Rarst, helen, azouamauriac, pbearne.
Fixes #51289.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59033 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-22 23:31:24 +00:00
audrasjb
b863373e3c Administration: Remove useless arrow icon from WordPress admin menu.
This changeset deletes the arrow that is typically added next to WordPress admin menu items that have submenus. The `.wp-menu-arrow` element is no longer visible since the WP 3.8 redesign, but the HTML and CSS remained. With this changeset, the HTML generating the arrow is removed, and the corresponding CSS styling is deleted.

Props helen, azaozz, jbkkd, pbearne, flixos90.
Fixes #26960.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59032 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-22 22:33:22 +00:00
audrasjb
c72b77f1ee Themes: Add wp-singular to the list of body classes when viewing a single post object.
The `wp-singular` class includes a `wp` prefix to avoid conflicts with existing classes. This changeset also updates the `Tests_Post_GetBodyClass` PHPUnit test to include the new CSS class.

Props danielpataki, peterwilsoncc, swissspidy, johnbillion, eceleste, poena, audrasjb, raj198, shailu25.
Fixes #35164.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59031 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-22 21:18:23 +00:00
audrasjb
692f6d4b9e General: Stop direct loading of files in /wp-includes that should only be included.
This changeset restricts direct access call in `/wp-includes` and its sub directories.

Follow-up to [11768], [59678].

Props deepakrohilla.
Fixes #61314.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59030 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-22 19:48:25 +00:00
John Blackbourn
67b029cbc1 Build/Test Tools: Coerce the run_id input to a string before passing it to the "Failed Workflow" workflow.
Follow-up to [59679].

See #62221

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


git-svn-id: http://core.svn.wordpress.org/trunk@59029 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-22 19:26:26 +00:00
desrosj
3012d6ea80 Build/Test Tools: Update @playwright/test.
This updates `@playwright/test` to the latest version, currently `1.49.1`.

In older branches using Playwright, the E2E and Performance workflows have recently started failing. This is due to changes in the GitHub Actions runner images. Updating Playwright ensures more modern dependency trees are used when installing browsers for testing and fixes the issue.

Props swissspidy.
See #62843.
Built from https://develop.svn.wordpress.org/trunk@59682


git-svn-id: http://core.svn.wordpress.org/trunk@59025 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-22 17:51:31 +00:00
desrosj
efaefdc79d Build/Test Tools: Fix Slack message payload generation.
The JSON string set as an output for the Slack message payload needs to be one line to prevent causing errors. This ensures `jq` returns a compact JSON string.

Follow up to [59679].

Props johnbillion.
See #62221.
Built from https://develop.svn.wordpress.org/trunk@59681


git-svn-id: http://core.svn.wordpress.org/trunk@59024 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-22 17:05:25 +00:00
Sergey Biryukov
60f95c14fd Coding Standards: Rename $thisEnclosure variable in wp_xmlrpc_server methods.
This resolves a WPCS warning:
{{{
Variable "$thisEnclosure" is not in valid snake_case format, try "$this_enclosure"
}}}

Follow-up to [16824], [19848].

See #62279.
Built from https://develop.svn.wordpress.org/trunk@59680


git-svn-id: http://core.svn.wordpress.org/trunk@59023 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-22 15:40:20 +00:00
John Blackbourn
140cfa6d5d Build/Test Tools: Improve the security and correctness of the GitHub Actions workflows files.
This includes removing use of dangerous inline GitHub Actions expressions, preventing word splitting, further tightening permissions, and generally improving many aspects of the workflows.

This also introduces a new workflow that runs Actionlint to detect incorrect and insecure code and configuration in workflow files.

Props johnbillion, swissspidy, flixos90, desrosj.

See #62221

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


git-svn-id: http://core.svn.wordpress.org/trunk@59022 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-22 15:15:21 +00:00
audrasjb
0619c6d95a General: Stop direct loading of files in /wp-admin that should only be included.
This changeset restricts direct access call in `/wp-admin` and its sub directories.

Follow-up to [11768].

Props deepakrohilla.
See #61314.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59021 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-22 14:06:22 +00:00
audrasjb
a79b4ef4c9 Formatting: Preserve target="_blank" in Biographical Info and Category Description.
This changeset ensures the `target="_blank"` attribute is preserved when adding links in the Biographical Info and Category Description fields. Previously, this attribute was being stripped by the KSES sanitization process.

Additionally, new unit tests have been added to verify the preservation of the `target="_blank"` attribute in these specific contexts.

Props lovewpmu, miqrogroove, bsutcliffe, sjefen6, nofearinc, nacin, harmr, blogitsolutions, stefahn, nirajgirixd, martinkrcho, spacedmonkey, sukhendu2002, audrasjb, gaellebesson, nuryko, guillaumeturpin, maximemeganck, ranafge, azaozz, joedolson, rinkalpagdar, mikinc860.
Fixes #12056.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59020 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-21 22:59:18 +00:00
audrasjb
c84a324ab2 Customize: Show sidebar's description below its name in Customizer Widgets sidebar list.
This is part of an effort to reduce `title` attribute usage in WordPress Admin. This changeset updates the Customizer Widgets sidebar list to show sidebar name and description (as these informations may benefit to everyone), and remove the `title` attribute.

Follow-up to [22439], [27548], [31513], [32991], [50804], [53414], [59675].

Props karlgroves, sabernhardt, mukesh27, joedolson.
Fixes #62836.
See #24766.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59019 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-21 22:38:23 +00:00
audrasjb
37e2744105 Themes: Remove title attributes from theme list tables.
This changeset updates the old list tables for themes and theme installation to remove `title` attributes or replace them with a more acessible implementation:
- Removes `title` attributes from `span` elements
- Replaces `title` with `aria-label` for links whose visible text starts with the same word, consistently with links on the "Add Plugins" screen
- Reuses the `$preview_title` variable to keep ARIA labels consistent for both Preview links

Follow-up to [22439], [27548], [31513], [32991], [50804], [53414].

Props karlgroves, sabernhardt, audrasjb, alh0319.
Fixes #62834.
See #24766.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59018 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-21 21:49:22 +00:00
Weston Ruter
091d5e460e Menus: Improve performance by calling get_privacy_policy_url() once per Walker_Nav_Menu instance rather than for every nav menu item.
The `start_el()` method in `Walker_Nav_Menu` was calling `get_privacy_policy_url()` for every menu item when building menus. This resulted in redundant queries, particularly for menus with many items. This obtains the `get_privacy_policy_url()` value in the constructor for reuse in the `start_el()` method to improve performance.

Redundant code to construct the privacy policy page is also refactored into the `set_up()` method during tests.

Props arzola, swissspidy, westonruter, mukesh27.
Fixes #62818.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59017 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-21 21:26:23 +00:00
John Blackbourn
1cd758d2ee Build/Test Tools: Switch to using local references for reusable workflows.
The benefit of this is that when PRs are made to make changes to a reusable workflow, the references doesn't need to be updated to point to the fork in order for the changed workflow to run.

A `npm run grunt replace:workflow-references-local-to-remote` command has also been introduced in order to convert these local references back to remote ones. This command can be used to switch release branches over to using remote workflows, as they are currently, so they continue to benefit from workflow changes in trunk without the need for continual backporting to all the branches.

Props desrosj, johnbillion

Fixes #62416

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


git-svn-id: http://core.svn.wordpress.org/trunk@59016 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-21 15:42:21 +00:00
Sergey Biryukov
0f51cfd3b4 Coding Standards: Rename the $errorString variable in wp_xmlrpc_server methods.
This resolves a WPCS warning:
{{{
Variable "$errorString" is not in valid snake_case format, try "$error_string"
}}}

Follow-up to [5054].

See #62279.
Built from https://develop.svn.wordpress.org/trunk@59672


git-svn-id: http://core.svn.wordpress.org/trunk@59015 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-21 15:34:20 +00:00
John Blackbourn
783c6905dd Security: Set the HttpOnly flag for the test cookie and the wp_lang cookie on the login screen.
These cookies are only accessed server-side and don't need to be exposed to JavaScript in the browser.

Props earthman100, kevinlearynet

Fixes #61322

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


git-svn-id: http://core.svn.wordpress.org/trunk@59014 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-21 13:19:21 +00:00
Pascal Birchler
78c401da14 I18N: Set textdomain registry information before loading plugins/theme.
This way, warnings for early translation calls can be emitted that aren't attached to any hook.

Follow-up to [59461].

Props swissspidy.
Fixes #62244.See #44937.
Built from https://develop.svn.wordpress.org/trunk@59670


git-svn-id: http://core.svn.wordpress.org/trunk@59013 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-21 11:44:21 +00:00
Pascal Birchler
f036ffa43a Build/Test Tools: Do not download extra browsers in performance tests.
Props euthelup, johnbillion, mukesh27.
Fixes #62822.
Built from https://develop.svn.wordpress.org/trunk@59669


git-svn-id: http://core.svn.wordpress.org/trunk@59012 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-21 08:34:21 +00:00
John Blackbourn
6fb84ace49 Build/Test Tools: Pass the working directory path from the host to the dev environment containers.
This allows development tools to read the host path information from the `HOST_PATH` environment variable in order to, for example, map a path in a stack trace from the path in the container to the path on the host machine.

Fixes #62833

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


git-svn-id: http://core.svn.wordpress.org/trunk@59011 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-20 22:08:19 +00:00
John Blackbourn
d93f38e360 Administration: Clarify some references to "we" and "our" in the administration area.
This changes some text to better match the guidelines and recommendations set forth in the make/core handbook, specifically:

> the word “we” should be avoided (...) unless its made very clear which group is speaking

Fixes #62295

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


git-svn-id: http://core.svn.wordpress.org/trunk@59010 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-20 22:04:28 +00:00
John Blackbourn
33729cf0db Build/Test Tools: Instruct git and svn to ignore SQLite files
This prevents users of the SQLite Database Integration plugin from seeing untracked files in the `src/wp-content/database` directory.

Props sukhendu2002, johnbillion

Fixes #62813

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


git-svn-id: http://core.svn.wordpress.org/trunk@59009 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-20 21:51:25 +00:00
Sergey Biryukov
5c35a5f4c5 Coding Standards: Rename the $isPrimary variable in wp_xmlrpc_server methods.
This resolves a few WPCS warnings:
{{{
Variable "$isPrimary" is not in valid snake_case format, try "$is_primary"
}}}

Additionally, this commit renames `$catids` to `$cat_ids` for consistency.

Follow-up to [1671].

See #62279.
Built from https://develop.svn.wordpress.org/trunk@59665


git-svn-id: http://core.svn.wordpress.org/trunk@59008 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-20 14:32:26 +00:00
Sergey Biryukov
3a140bb318 Coding Standards: Rename the $dateCreated variable in wp_xmlrpc_server methods.
This resolves a few WPCS warnings:
{{{
Variable "$dateCreated" is not in valid snake_case format, try "$date_created"
}}}

Follow-up to [1563], [1659], [5888], [6691], [8543], [19848].

See #62279.
Built from https://develop.svn.wordpress.org/trunk@59664


git-svn-id: http://core.svn.wordpress.org/trunk@59007 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-19 16:57:22 +00:00
Sergey Biryukov
a8196960bc Coding Standards: Use strict comparison in wp_xmlrpc_server::pingback_ping().
Follow-up to [2983], [55365].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59663


git-svn-id: http://core.svn.wordpress.org/trunk@59006 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-18 23:43:25 +00:00
Joe McGill
89adfd4acc Editor: Improve consistency of render_block_context filter.
This ensures that when block context is filtered via `render_block_context`, the filtered value is provided as available context to inner blocks.

For backwards compatibility reasons, filtered context is added to inner block context regardless of whether that block has declared support via the `uses_context` property.

Props mukesh27, flixos90, gziolo, dlh, joemcgill, santosguillamot.
Fixes #62046.

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


git-svn-id: http://core.svn.wordpress.org/trunk@59005 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-17 21:37:21 +00:00
desrosj
570c050e53 Build/Test Tools: Auto-close linked PRs on GitHub.
There are currently ~2,000 open pull requests on GitHub for `wordpress-develop`. Many of these were for testing changes that have already been merged.

To help prevent orphaned pull requests, this new workflow will search for any pull requests referencing the `Fixed` Trac tickets as noted in the commit message and close them out. For now, this only happens for `push` events.

Props peterwilsoncc, swissspidy, johnbillion, davidbaumwald.
Fixes #62817.
Built from https://develop.svn.wordpress.org/trunk@59661


git-svn-id: http://core.svn.wordpress.org/trunk@59004 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-17 14:03:22 +00:00
Sergey Biryukov
52a592e1b8 Coding Standards: Use strict comparison in wp_xmlrpc_server::wp_deleteCategory().
Follow-up to [20157], [32733].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59660


git-svn-id: http://core.svn.wordpress.org/trunk@59003 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-17 10:39:18 +00:00
John Blackbourn
6629610493 Build/Test Tools: Hide the Node.js error message when a Docker command produces a non-zero exit code.
When running a command that goes via docker.js and produces a non-zero exit code, the error message and stack trace from node an safely be hidden because the stack trace only points to the `execSync()` call and is of no use.

Fixes #62814

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


git-svn-id: http://core.svn.wordpress.org/trunk@59002 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-17 10:37:19 +00:00
John Blackbourn
958e52f4cb Build/Test Tools: Use quiet pulls during local environment installation and WP-CLI commands.
This reduces the noise of the output -- both locally and on CI -- when first pulling containers during local environment installation and the first time the cli container is pulled for WP-CLI commands.

See #62280

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


git-svn-id: http://core.svn.wordpress.org/trunk@59001 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-17 10:34:26 +00:00
Peter Wilson
cf9594c4ae Options/Meta APIs: Document type juggling of meta data.
Document that unserialised data types are stored as strings in the database and returned as such by the meta data functions. For example, setting meta data to the integer value `1` will be returned as `"1"` when subsequently queried via `get_metadata()` and the related functions.

Props sukhendu2002, azaozz, jrf, rodrigosprimo.
Fixes ticket:61950.



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


git-svn-id: http://core.svn.wordpress.org/trunk@59000 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-17 00:12:26 +00:00
desrosj
2e64ee9f0d Administration: Modernize admin color scheme SASS files.
This updates the admin color scheme `.sass` files to address some deprecated notices caused by upstream changes.

- `string` and `colors` are no longer globally available functions.
- `@import` is deprecated in favor of `@use`.

There are still a few notices that are output, however this will require an update to the `grunt-sass` package to resolve.

Props MattyRob.
Fixes #62323.
Built from https://develop.svn.wordpress.org/trunk@59656


git-svn-id: http://core.svn.wordpress.org/trunk@58999 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-16 21:05:33 +00:00
desrosj
3ed22fda3a Build/Test Tools: Add input for disabling AppArmor.
Old branches requiring outdated versions of Chromium to run JavaScript tests have recently started failing as a result of the `ubuntu-latest` container being updated to point to `ubuntu-24`.

This introduces a new input to the reusable JavaScript testing workflow to allow a fix to be used without having to update Chromium or tests in these branches.

Props swissspidy.
See #62808.
Built from https://develop.svn.wordpress.org/trunk@59635


git-svn-id: http://core.svn.wordpress.org/trunk@58998 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-16 20:21:23 +00:00
Sergey Biryukov
201d79b06e Upload: Remove redundant check for ABSPATH in wp-admin/async-upload.php.
This aims to bring consistency with a similar fragment in other files, since relocating `wp-admin` or `wp-load.php` is not supported at this time.

Follow-up to [6659], [7971], [8315].

Props hussain896, swissspidy, knutsp, SergeyBiryukov.
Fixes #62809.
Built from https://develop.svn.wordpress.org/trunk@59634


git-svn-id: http://core.svn.wordpress.org/trunk@58997 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-16 16:18:24 +00:00
John Blackbourn
3579e69fe2 Users: Retain the current session when a user changes their password.
Prior to this change a new session was unnecessarily created when a user changed their own password.

Existing authentication cookies for the user will still be invalidated regardless of whether they share the same session token because session cookie keys contain a substring of the password hash.

Props snicco, narenin, johnbillion

Fixes #61366

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


git-svn-id: http://core.svn.wordpress.org/trunk@58996 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-16 15:35:27 +00:00
Sergey Biryukov
5765a2eb1b Coding Standards: Use strict comparison in wp_xmlrpc_server::_multisite_getUsersBlogs().
Follow-up to [https://mu.trac.wordpress.org/changeset/1218 mu:1218], [12852].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59632


git-svn-id: http://core.svn.wordpress.org/trunk@58995 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-16 12:04:23 +00:00
Peter Wilson
5351aabea8 Options/Meta APIs: Optimize cache hits for non-existent options.
Optimize the order of checking the various options caches in `get_option()` to prevent hitting external caches each time it is called for a known non-existent option.

The caches are checked in the following order when getting an option:

1. Check the `alloptions` cache first to prioritize existing loaded options.
2. Check the `notoptions` cache before a cache lookup or DB hit.
3. Check the `options` cache prior to a DB hit.

Follow up to [56595].

Props adamsilverstein, flixos90, ivankristianto, joemcgill, rmccue, siliconforks, spacedmonkey.
Fixes #62692.
See #58277.

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


git-svn-id: http://core.svn.wordpress.org/trunk@58994 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-15 22:13:24 +00:00
Felix Arntz
b742570d1b REST API: Fix PHP warning about undefined paged argument in various REST API endpoints.
This bug could occur in `WP_REST_Posts_Controller`, `WP_REST_Global_Styles_Revisions_Controller`, `WP_REST_Revisions_Controller`, and any of their child classes. This changeset fixes it throughout.

Props apermo, pbearne, hemant-ahir, flixos90.
Fixes #62292.

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


git-svn-id: http://core.svn.wordpress.org/trunk@58993 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-15 18:36:24 +00:00
Pascal Birchler
8e649f1a2e Undo accidental svn:mergeinfo property change in [59605].
See #61970.

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


git-svn-id: http://core.svn.wordpress.org/trunk@58992 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-15 12:55:16 +00:00
Sergey Biryukov
b01086811d Coding Standards: Use strict comparison in paginate_links().
Follow-up to [4275], [28785].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59606


git-svn-id: http://core.svn.wordpress.org/trunk@58991 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-15 12:52:17 +00:00
Pascal Birchler
7dcc7f8d32 REST API: Improve autosave and revision endpoints for templates and template parts.
Fixes those endpoints for file-based templates and template parts, as templates based on theme files can't be revisioned or autosaved.

Props antonvlasenko, swissspidy, spacedmonkey, kadamwhite.
Fixes #61970.
Built from https://develop.svn.wordpress.org/trunk@59605


git-svn-id: http://core.svn.wordpress.org/trunk@58990 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-15 12:46:25 +00:00
Sergey Biryukov
5372b3ffa2 Tests: Restore the environment before performing assertions in download_url() tests.
This aims to avoid affecting other tests in case of failure.

Follow-up to [42773], [51939].

See #62280.
Built from https://develop.svn.wordpress.org/trunk@59604


git-svn-id: http://core.svn.wordpress.org/trunk@58989 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-14 15:37:31 +00:00
John Blackbourn
7c245831e8 Docs: Correct a translator comment that was added in [59578].
See #62005

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


git-svn-id: http://core.svn.wordpress.org/trunk@58988 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-14 11:38:24 +00:00
Sergey Biryukov
08ffc54083 Docs: Correct @return value for update_attached_file().
Follow-up to [4612], [21967], [24490], [47611], [48214].

Props arnoutblueshell, karthickmurugan, SergeyBiryukov.
Fixes #62803.
Built from https://develop.svn.wordpress.org/trunk@59602


git-svn-id: http://core.svn.wordpress.org/trunk@58987 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-01-13 22:22:25 +00:00