Also similarly adjusts the `$crop` parameter description in the corresponding `image_resize_dimensions` hook doc.
Props jaspermdegroot.
See #34257.
git-svn-id: https://develop.svn.wordpress.org/trunk@35053 602fd350-edb4-49c9-b593-d223f7449a82
Also adds the `array` type to the parameter documentation (already supported).
Props jaspermdegroot.
See #34257.
git-svn-id: https://develop.svn.wordpress.org/trunk@35050 602fd350-edb4-49c9-b593-d223f7449a82
The data stored in the cache should be raw database query results, not
`WP_Term` objects (which may be modified by plugins, and may contain additional
properties that shouldn't be cached).
If term relationships caches were handled in `wp_get_object_terms()` - where
a database query takes place - it would be straightforward to cache raw data.
See #34239. Since, in fact, `get_the_terms()` caches the value it gets from
`wp_get_object_terms()`, we need a technique that allows us to get raw data
from a `WP_Term` object. Mirroring `WP_User`, we introduce a `data` property
on term objects, which `get_the_terms()` uses to fetch cacheable term info.
Fixes#34262.
git-svn-id: https://develop.svn.wordpress.org/trunk@35032 602fd350-edb4-49c9-b593-d223f7449a82
The test, introduced in [33724], was intended to demonstrate the behavior of
`example.com?tag=foo` routing. But an error in the test setup meant that a
URL-encoded tag object was being set as the value of 'tag'. Due to a quirk in
the way that `parse_request()` parses query vars, an object value for 'tag'
would inadvertently produce correct results in certain cases. But it's not a
usage we actively support, and it's not what was meant to be tested.
See #33532, #34262.
git-svn-id: https://develop.svn.wordpress.org/trunk@35030 602fd350-edb4-49c9-b593-d223f7449a82
After [34997], the `$taxonomy` parameter of `get_term()` is optional. This
changeset brings `get_term_field()` in line with the new usage.
Adds unit tests for `get_term_field()`.
Props DrewAPicture.
See #34245.
git-svn-id: https://develop.svn.wordpress.org/trunk@35028 602fd350-edb4-49c9-b593-d223f7449a82
Inline `@see` tags in the context of hooks are parsed as links to hook pages in the Code Reference.
See #32246.
git-svn-id: https://develop.svn.wordpress.org/trunk@35027 602fd350-edb4-49c9-b593-d223f7449a82
If the network option for `upload_space_check_disabled` is missing or an empty string, we should reflect how it will be treated elsewhere in the UI.
Props stephenharris.
Fixes#33986.
git-svn-id: https://develop.svn.wordpress.org/trunk@35026 602fd350-edb4-49c9-b593-d223f7449a82
A valid `$network_id` or `null`/`false` is expected as the first parameter for `_network_option()`. If something other than that is passed, we immediately return `false` rather than attempting to guess what network was intended.
See #28290.
git-svn-id: https://develop.svn.wordpress.org/trunk@35025 602fd350-edb4-49c9-b593-d223f7449a82
This better aligns with expectations and matches the structure used by `_blog_option()`. The `_site_option()` functions remain as an appropriate method for working with the current network.
See #28290.
git-svn-id: https://develop.svn.wordpress.org/trunk@35024 602fd350-edb4-49c9-b593-d223f7449a82
This filter has no effect on the image size used to display post thumbnails on the front-end.
Props dboulet, DrewAPicture.
Fixes#28512.
git-svn-id: https://develop.svn.wordpress.org/trunk@35022 602fd350-edb4-49c9-b593-d223f7449a82
Hide the editor uploader overlay on all drop events in the window, not only when dropping on the editor uploader element.
Fixes#34251, #22403.
git-svn-id: https://develop.svn.wordpress.org/trunk@35019 602fd350-edb4-49c9-b593-d223f7449a82
Upload space of 0 is now more possible via r35016 and should be respected rather than modified to a default of 10MB.
Fixes#34037.
git-svn-id: https://develop.svn.wordpress.org/trunk@35017 602fd350-edb4-49c9-b593-d223f7449a82
Previously, an value matching `empty()` would have been bypassed in favor of the default setting for 100MB.
Related #19538, r19639, r19652, where we saw the bug, fixed the bug, and then unfixed the bug so that it was not a surprise in a point release.
See #34037.
git-svn-id: https://develop.svn.wordpress.org/trunk@35016 602fd350-edb4-49c9-b593-d223f7449a82
"Please enter the same password in both password fields" should cover all the scenarios.
Props MikeHansenMe, jmayhak, desrosj, gounder.
Fixes#33101.
git-svn-id: https://develop.svn.wordpress.org/trunk@35008 602fd350-edb4-49c9-b593-d223f7449a82
As the number of multidimensional settings (serialized options and theme mods) increase for a given ID base (e.g. a widget of a certain type), the number of calls to the `multidimensional` methods on `WP_Customize_Setting` increase exponentially, and the time for the preview to refresh grows in time exponentially as well.
To improve performance, this change reduces the number of filters needed to preview the settings off of a multidimensional root from N to 1. This improves performance from `O(n^2)` to `O(n)`, but the linear increase is so low that the performance is essentially `O(1)` in comparison. This is achieved by introducing the concept of an "aggregated multidimensional" setting, where the root value of the multidimensional serialized setting value gets cached in a static array variable shared across all settings.
Also improves performance by only adding preview filters if there is actually a need to do so: there is no need to add a filter if there is an initial value and if there is no posted value for a given setting (if it is not dirty).
Fixes#32103.
git-svn-id: https://develop.svn.wordpress.org/trunk@35007 602fd350-edb4-49c9-b593-d223f7449a82
* It works correctly for RTL
* Requires less CSS styling
* Is visually consistent with plugin ratings
* Is more accessible
Fixes#34080.
git-svn-id: https://develop.svn.wordpress.org/trunk@35006 602fd350-edb4-49c9-b593-d223f7449a82