Prior to this change, both taxonomies and post types added meta boxes to the Menus UI (which in-turn registered screen options) using the same ID formula: `add-{$id}`. This caused a conflict between the two elements, resulting in the rendering of a screen option for only the taxonomy or post type but not both. Moving to a new meta box ID for post types, `add-post-type-{$id}`, removes that conflict.
Note: This change in meta box IDs for post types effectively resets current user settings for the visibility of post types in the Menus UI.
Fixes#33925.
git-svn-id: https://develop.svn.wordpress.org/trunk@35450 602fd350-edb4-49c9-b593-d223f7449a82
Just as with wp-signup.php, display of the Toolbar on wp-activate.php was broken in [23512] due to a hook change for the `_wp_admin_bar_init()` callback. wp-signup.php was fixed in [35423] for #34418.
See [35423] for more in-depth background and reasoning behind restoring display of the Toolbar on wp-activate.php and wp-signup.php.
Fixes#34496. See #34418.
git-svn-id: https://develop.svn.wordpress.org/trunk@35449 602fd350-edb4-49c9-b593-d223f7449a82
Sometimes, embedded sites might suffer from less than 100% uptime. Instead of leaving the embedding site with a big blank space where the embed should be, let's fall back to a link to the embedded post, so there's at least some context for the post.
Fixes#34462.
git-svn-id: https://develop.svn.wordpress.org/trunk@35437 602fd350-edb4-49c9-b593-d223f7449a82
Well, while it's here, we probably should make use of it. The oEmbed endpoint now uses the REST API infrastructure, instead of providing its own.
Props swissspidy.
Fixes#34207.
git-svn-id: https://develop.svn.wordpress.org/trunk@35436 602fd350-edb4-49c9-b593-d223f7449a82
The previous name was inadvertently changing the dynamic part of `set_transient_{transient}` action and the transient name passed to the action since [35082].
Props GregLone.
Fixes#34470.
git-svn-id: https://develop.svn.wordpress.org/trunk@35431 602fd350-edb4-49c9-b593-d223f7449a82
Prior to [23512], the Toolbar was still displayed on wp-signup.php while logged-in because it was hooked to the `init` action. When `_wp_admin_bar_init()` was moved to instead fire on `template_redirect` for the front-end and `admin_init` on the back-end, the visibility was lost because `template_redirect` isn't fired on wp-signup.php due to `WP_USE_THEMES` not being defined.
In order to maintain expected display results, a default filter has been added to hook `_wp_admin_bar_init()` to the `before_signup_header` action. This approach has the added benefit of allowing `_wp_admin_bar_init()` to be fired prior to the `wp_head` action where `_admin_bar_bump_cb()` is called (or the callback defined when 'admin-bar' theme support is added).
Fixes#34418.
git-svn-id: https://develop.svn.wordpress.org/trunk@35423 602fd350-edb4-49c9-b593-d223f7449a82
- Check if wp_get_attachment_metadata() has returned an array to prevent errors when using SVGs.
- Only add the srcset attribute if there will be a sizes attribute.
- Better filter names.
- Some more inline docs fixes.
Props jaspermdegroot.
See #34430.
git-svn-id: https://develop.svn.wordpress.org/trunk@35419 602fd350-edb4-49c9-b593-d223f7449a82
The default value should be a null offset. A `0` default overrides any value
of `paged` passed to `get_posts()`. See [34697].
Fixes#34060.
git-svn-id: https://develop.svn.wordpress.org/trunk@35417 602fd350-edb4-49c9-b593-d223f7449a82
- Introduce `wp_calculate_image_srcset()` that replaces `wp_get_attachment_image_srcset_array()` and is used as lower level function for retrieving the srcset data as array.
- Use the new function when generating `srcset` and `sizes` on the front-end. This is faster as no (other) image API functions are used.
- Change the `wp_get_attachment_image_srcset()`. Now it is meant for use in templates and is no longer used in core.
- A few logic fixes and improvements.
- Some names changed to be (hopefully) more descriptive.
- Fixed/updated tests.
Props joemcgill, jaspermdegroot, azaozz.
See #34430.
git-svn-id: https://develop.svn.wordpress.org/trunk@35412 602fd350-edb4-49c9-b593-d223f7449a82