This commit adds a new `WP_REST_Server#remove_header` method and uses it to clear the `Last-Modified` header when the "no caching" headers are sent (by default for all authenticated REST API requests). This matches the behavior of the `nocache_headers` function used in other parts of WordPress.
Previously, the REST API would send an empty `Last-Modified` header in this situation. Under some server and browser configurations, this causes browsers to cache authenticated REST API requests, which is undesirable.
Props iv3rson76, zinigor, rmccue, jnylen0.
Fixes#40444.
git-svn-id: https://develop.svn.wordpress.org/trunk@40805 602fd350-edb4-49c9-b593-d223f7449a82
Since the feed URL can be localized the cache key has to be built with the same locale as the current user is using.
Props iandunn.
Fixes#40417.
git-svn-id: https://develop.svn.wordpress.org/trunk@40793 602fd350-edb4-49c9-b593-d223f7449a82
Strings have been reviewed and are ready for translation—design will come soon.
Props bridgetwillard, jenblogs4u, michelleweber, ryelle, melchoyce.
See #40721.
git-svn-id: https://develop.svn.wordpress.org/trunk@40791 602fd350-edb4-49c9-b593-d223f7449a82
- Close the form after obtaining a valid location.
- Fix focusing the toggle button after closing the form.
- Fix aria attribute values.
- Fix positions in IE11.
- Some JS and CSS cleanup.
Props afercia, coreymckrill.
Fixes#40735.
git-svn-id: https://develop.svn.wordpress.org/trunk@40789 602fd350-edb4-49c9-b593-d223f7449a82
Aligns behavior of field with Text widget and other widgets whereby the server-sanitized title (via the `widget-update` request) is supplied into the field after the `change` event.
See #32417.
Fixes#40805.
git-svn-id: https://develop.svn.wordpress.org/trunk@40785 602fd350-edb4-49c9-b593-d223f7449a82
The new version of TinyMCE introduces a cursor-boundary feature for some formatting elements but, by default, it does not provide much in the way of styles. This tweaks their appearance in the WordPress custom skin to match the intended design of the feature.
Props joen.
Fixes#40767.
git-svn-id: https://develop.svn.wordpress.org/trunk@40783 602fd350-edb4-49c9-b593-d223f7449a82
Only set these headers if (1) `WP_DEBUG` is enabled and (2) headers have not already been sent.
Previously, this code could generate warnings by trying to set a header after response data has already been sent. This happens when code attached to the `shutdown` filter calls a deprecated function, for example.
Also, these headers are unlikely to be useful in the majority of cases; let's only send them if `WP_DEBUG` is enabled.
Props kraftbj, jnylen0, ocean90, rmccue.
Fixes#40787.
git-svn-id: https://develop.svn.wordpress.org/trunk@40782 602fd350-edb4-49c9-b593-d223f7449a82
Previously, a role selected below the list table would not apply on save. This aligns the behavior with `wp-admin/users.php` and allows role changes from both selections, deferring to the bottom selection when both are populated.
Props desrosj.
Fixes#40113.
git-svn-id: https://develop.svn.wordpress.org/trunk@40780 602fd350-edb4-49c9-b593-d223f7449a82
Documents the reason why the request is proxied through WP, instead of being
made directly to api.wordpress.org.
Props iandunn, michelleweber.
See #40702.
git-svn-id: https://develop.svn.wordpress.org/trunk@40777 602fd350-edb4-49c9-b593-d223f7449a82
Also avoid showing error notice in media widget when URL field is empty.
Props timmydcrawford, westonruter.
Fixes#40771.
git-svn-id: https://develop.svn.wordpress.org/trunk@40772 602fd350-edb4-49c9-b593-d223f7449a82
This ensures that 3rd-party scripts that users paste into Text widgets will gracefully recover and result in the expected preview.
See #27355.
Fixes#40658.
git-svn-id: https://develop.svn.wordpress.org/trunk@40771 602fd350-edb4-49c9-b593-d223f7449a82
Removes extra border around TinyMCE-wrapped `textarea` and removes gap at bottom due to lack of `display:block`.
Props johnjamesjacoby, westonruter.
See #35243.
Fixes#40755.
git-svn-id: https://develop.svn.wordpress.org/trunk@40675 602fd350-edb4-49c9-b593-d223f7449a82
On Chrome 58 and above, plugin names within the plugin details modal were collapsed down into an ellipsis. This fix rewrites the CSS to make sure the titles are always shown.
Props mrwweb, afercia, Presskopp.
Fixes#40579.
git-svn-id: https://develop.svn.wordpress.org/trunk@40672 602fd350-edb4-49c9-b593-d223f7449a82