Also update `WP_Customize_Widgets::$core_widget_id_bases` with the new list of core widgets.
Props obenland, westonruter.
See #40907, #40951.
git-svn-id: https://develop.svn.wordpress.org/trunk@41000 602fd350-edb4-49c9-b593-d223f7449a82
Previously, checks like `current_user_can( 'edit_term_meta', $term_id )`
returned the proper value, but generated a PHP notice due to the fact
that `get_term( $term_id )` could, in certain instances, return
`WP_Error` objects.
Props caercam.
Fixes#40891.
git-svn-id: https://develop.svn.wordpress.org/trunk@40999 602fd350-edb4-49c9-b593-d223f7449a82
Also adds an inline reference to the `session_token_manager` hook in the description.
Props Shelob9 for the initial patch.
Fixes#40102.
git-svn-id: https://develop.svn.wordpress.org/trunk@40998 602fd350-edb4-49c9-b593-d223f7449a82
This filter allows developers to modify the arguments passed to
`wp_get_object_terms()` before the query is run.
Props enrico.sorcinelli.
Fixes#35925.
git-svn-id: https://develop.svn.wordpress.org/trunk@40994 602fd350-edb4-49c9-b593-d223f7449a82
Meta capabilities use the capability `do_not_allow` to indicate a user should be blocked from performing a particular action. This ensures users can not have the capability as it would cause unexpected behaviour.
Props johnbillion.
Fixes#41059.
git-svn-id: https://develop.svn.wordpress.org/trunk@40993 602fd350-edb4-49c9-b593-d223f7449a82
Per the inline documentation standards for PHP, there should only be one `@package` and/or `@subpackage` notation per file, and only in the file header.
See #41017.
git-svn-id: https://develop.svn.wordpress.org/trunk@40988 602fd350-edb4-49c9-b593-d223f7449a82
Passing an array of `comment_meta` into `wp_update_comment()` will
now update corresponding metadata. Similar functionality already
exists in `wp_insert_comment()`.
Props dshanske, kraftbj.
Fixes#36784.
git-svn-id: https://develop.svn.wordpress.org/trunk@40981 602fd350-edb4-49c9-b593-d223f7449a82
When a cache entry is found that matches the requested `$term_id`, but
doesn't match an explicitly provided `$taxonomy`, that cache entry
should be ignored.
Props GunGeekATX.
Fixes#40671.
git-svn-id: https://develop.svn.wordpress.org/trunk@40979 602fd350-edb4-49c9-b593-d223f7449a82
This parameter allows querying for posts with a specific value of
`comment_count`. It is also possible to query for posts that match
a `comment_count` comparison by passing an array with 'value' and
'compare' operators (eg `array( 'compare' => '>', 'value' => 5 )`).
Props ramon fincken.
Fixes#28399.
git-svn-id: https://develop.svn.wordpress.org/trunk@40978 602fd350-edb4-49c9-b593-d223f7449a82
Separately, use `$post` for checking the post status and retrieving the page_uri in `get_post_permalink()` instead of referencing back to the original `$id` parameter.
Props GunGeekATX for the initial patch.
Fixes#40780.
git-svn-id: https://develop.svn.wordpress.org/trunk@40975 602fd350-edb4-49c9-b593-d223f7449a82
A similar `manage_posts_extra_tablenav` hook fires in the same location and context in the Posts list table tablenav.
Props GunGeekATX, adamsilverstein.
Fixes#36990.
git-svn-id: https://develop.svn.wordpress.org/trunk@40974 602fd350-edb4-49c9-b593-d223f7449a82
At the heart of the matter, the `$menu_slug` parameter in `add_menu_page()` and `add_submenu_page()` is not sanitized with `sanitize_key()`. When the screen object is later built for the admin page, the screen ID is derived from that `$menu_slug` value, though passed through `sanitize_key()`, which can produce unexpected results in comparison check.
Changing the sanitization code to provide actual parity is out of the question at this juncture, so updating the docs to describe how to avoid this edge case is the next best option.
Props GregRoss.
Fixes#35305.
git-svn-id: https://develop.svn.wordpress.org/trunk@40967 602fd350-edb4-49c9-b593-d223f7449a82
This complements `wp_clear_scheduled_hook()`, which only clears events attached with specific arguments.
Props arena, mordauk, jrf.
Fixes#18997.
git-svn-id: https://develop.svn.wordpress.org/trunk@40965 602fd350-edb4-49c9-b593-d223f7449a82
* `get_index_template()`
* `get_404_template()`
* `get_author_template()`
* `get_category_template()`
* `get_tag_template()`
* `get_taxonomy_template()`
* `get_date_template()`
* `get_home_template()`
* `get_front_page_template()`
* `get_page_template()`
* `get_search_template()`
* `get_single_template()`
* `get_embed_template()`
* `get_singular_template()`
* `get_attachment_template()`
As mentioned when these dynamic hook references were originally fixed in [33274], we can't link to non-existent hooks inline because the Code Reference auto-linker won't pick up on the dynamic-ness of the hook, it'll just try to link to a hook reference that doesn't exist. In these cases, we need to be generic and provide context for the value of `$type`.
See [38418] for where the original fix was reversed. See this changeset for reversing the reversal.
Props donutz, milana_cap.
Fixes#41198.
git-svn-id: https://develop.svn.wordpress.org/trunk@40964 602fd350-edb4-49c9-b593-d223f7449a82
Also removes extra curly braces from the dynamic hook references added in [40962] to aid future re-parsing.
See #41198.
git-svn-id: https://develop.svn.wordpress.org/trunk@40963 602fd350-edb4-49c9-b593-d223f7449a82
These sentences suggested that the hooks allow a specific template file to be used in place of the default file, which is not the case.
Props desrosj.
Fixes#40892.
git-svn-id: https://develop.svn.wordpress.org/trunk@40955 602fd350-edb4-49c9-b593-d223f7449a82
This change brings consistency with the regular site administration panel settings pages: Radio and checkbox labels do not use full stops there, so those in the network administration panel should not either.
Props Ankit K Gupta.
Fixes#39319.
git-svn-id: https://develop.svn.wordpress.org/trunk@40953 602fd350-edb4-49c9-b593-d223f7449a82