Commit Graph

10785 Commits

Author SHA1 Message Date
Weston Ruter
ea92bb5f10 Customize: Harden color control's logic for obtaining default value to prevent JS error when non-string default supplied.
Props andreagobetti, yonivh for testing.
Fixes #37174.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41096 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-16 19:04:47 +00:00
John Blackbourn
e06146a9b5 Options, Meta APIs: Update the multisite unit tests after [41254], [41164], and [41163].
This moves some more previously Multisite-only tests into the main test suite, and makes small adjustments to their assertions.

See #39118, #16470, #39117

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


git-svn-id: http://core.svn.wordpress.org/trunk@41095 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-15 09:16:43 +00:00
John Blackbourn
b52e37f9bf Options, Meta APIs: Require a confirmation link in an email to be clicked when an admin attempts to change the site admin email address.
This adds this previously Multisite-only functionality to single site installations too. This change prevents accidental or erroneous email address changes from potentially locking users out of their site.

Props MatheusGimenez, johnbillion

Fixes #39118

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


git-svn-id: http://core.svn.wordpress.org/trunk@41094 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-14 20:13:43 +00:00
John Blackbourn
b51f60de6d Users: Display the "Your email address has not been updated yet" message when a user changes their profile email address from within network admin.
This ensures continuity with the regular profile editing screen and the user admin profile editing screen.

Fixes #41635

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


git-svn-id: http://core.svn.wordpress.org/trunk@41093 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-14 19:42:43 +00:00
Weston Ruter
75ad3494a8 Widgets: Expose link URL input field in Image widget to avoid having to open media modal to discover.
Props timmydcrawford, westonruter.
See #39993.
Fixes #41274.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41092 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-14 17:56:42 +00:00
Weston Ruter
ae47e05f74 Widgets: Suppress PHP warnings raised by DOMDocument::loadHTML() in WP_Widget_Text::is_legacy_instance() which could appear in Text widget forms.
Also explicitly use HTML5 doctype when parsing Text widget contents in legacy mode detection.

Amends [41050].
See #40951.
Fixes #41622.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41091 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-14 05:59:42 +00:00
Peter Wilson
d8bf666313 Emoji: Update Twemoji to 2.5.0.
Twemoji 2.3.0 has a rendering issue in Safari, emoji can sometimes be followed by U+FEOF (which is just a flag meaning "render the preceding character as emoji).

Twemoji wasn't catching this character correctly, and Safari rendered it incorrectly.

Twemoji 2.5.0 resolves this issue.

Fixes #41584.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41090 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-14 02:04:45 +00:00
Weston Ruter
18613c0010 Widgets: Add missing open class for expanded widgets in Customizer; utilize open class for expansion detection in Text and Media widgets.
Fixes #41625.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41089 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-13 06:25:43 +00:00
Weston Ruter
5c755f652b Customize: Prevent attachment deletions from silently failing in media modals opened for Media widgets.
Amends [40640].
See #32417.
Fixes #41609.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41088 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-13 06:11:43 +00:00
Weston Ruter
e956aa4176 Customize: Prevent wide widgets from being displayed as wide when Customizer is displayed in mobile breakpoint.
Fixes #41624.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41087 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-13 05:55:43 +00:00
Weston Ruter
a5d3688157 Customize: Update selector to add max-height/max-width for wide widgets to account for JS-driven Text widget and Media widgets.
Fixes #41623.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41086 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-13 05:42:42 +00:00
Weston Ruter
9c3cdaf3fb Widgets: Fix extensibility of Text widgets so that JS logic will initialize on subclassed widgets.
Amends [40631].
See #35243.
Fixes #41540.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41085 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-13 05:25:46 +00:00
Weston Ruter
300894da61 Customize: Prevent _delete_option_fresh_site() from hitting DB if fresh_site flag already cleared.
Amends [38991].
Props dlh, westonruter.
Fixes #41039.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41084 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-13 00:57:43 +00:00
Weston Ruter
6428de97a7 Customize: Fix PHP warning raised when deleting a setting from changeset via passing null as params in WP_Customize_Manager::save_changeset_post().
Props dlh.
Fixes #41621.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41083 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-12 21:21:48 +00:00
Felix Arntz
473e1ba73b Multisite: Remove references to $wpdb->siteid and use get_current_network_id() instead.
Props sathyapulse, spacedmonkey.
Fixes #41507.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41082 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-12 13:11:43 +00:00
Felix Arntz
820d3973a3 Multisite: Rename internal $site_id variables referencing networks to $network_id.
This change improves code clarity by using the current naming conventions for networks.

Props lemacarl.
Fixes #41510.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41081 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-12 12:48:47 +00:00
Weston Ruter
f0ee106d86 Media: Upgrade MediaElement.js from 4.2.3 to 4.2.5.
Props rafa8626.
See #39686.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41080 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-12 06:20:44 +00:00
Adam Silverstein
f42a3a2440 Docs: Improve JavaScript documentation in audiovideo.manifest.js.
Add and improve JSDOC blocks.

Props nicollle, manuelaugustin.
Fixes #41602.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41079 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-11 20:37:45 +00:00
James Nylen
fce0b2dcd9 REST API: Always call rest_get_server() instead of accessing the $wp_rest_server global.
This is a consistency improvement and also a bug fix for fairly obscure cases involving modified WP load order.

Fixes #41555.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41078 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-10 01:38:43 +00:00
Konstantin Obenland
e183d59acb Map nav menu locations on theme switch
This will send nav menu locations through three levels of mapping:
1. If both themes have only one location, that gets mapped.
2. If both themes have locations with the same slug, they get mapped.
3. Locations that (even partially) match slugs from a similar kind of menu location will get mapped.

Menu locations are mapped for Live Previews in the Customizer and during theme switches.

Props westonruter, obenland, welcher, melchoyce.
Fixes #39692.


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


git-svn-id: http://core.svn.wordpress.org/trunk@41077 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-09 21:04:47 +00:00
Sergey Biryukov
5fe8d31118 Link Template: Allow the type argument to be passed through get_the_comments_pagination() as long as its value isn't array.
See [30820] for `get_the_posts_pagination().

Props jainnidhi, poena.
Fixes #39792.
Built from https://develop.svn.wordpress.org/trunk@41236


git-svn-id: http://core.svn.wordpress.org/trunk@41076 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-09 04:07:43 +00:00
Sergey Biryukov
dd330359eb Docs: Correct @param type for $term_id in get_term_children().
Props Soean, wido.
Fixes #41585.
Built from https://develop.svn.wordpress.org/trunk@41235


git-svn-id: http://core.svn.wordpress.org/trunk@41075 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-08 20:53:46 +00:00
Sergey Biryukov
187b4ad48b Media: Pass shortcode attributes to wp_audio_shortcode_class and wp_video_shortcode_class filters.
Props sathyapulse.
Fixes #37329.
Built from https://develop.svn.wordpress.org/trunk@41234


git-svn-id: http://core.svn.wordpress.org/trunk@41074 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-05 16:42:45 +00:00
Drew Jaynes
1a123e432f External Libraries: Update jQuery Form (unused in core) to the latest version, 4.2.1.
Fixes #41565.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41073 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-05 13:00:47 +00:00
John Blackbourn
41f71598f7 Formatting: Introduce get_the_post_type_description() to allow post type archive descriptions to be formatted the same as author and term archives.
Props henry.wright

Fixes #40040

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


git-svn-id: http://core.svn.wordpress.org/trunk@41072 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-04 23:01:44 +00:00
John Blackbourn
c96b33e3a5 Plugins: Correct and improve docblocks for the various plugin_action_links filters on the Plugins screen.
This also adds a changelog for the removal of the Edit links in [41160].

See #41017
Fixes #38169

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


git-svn-id: http://core.svn.wordpress.org/trunk@41071 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-04 22:15:45 +00:00
John Blackbourn
c26b735c8a Multisite: Clarify descriptions of the wpmu_signup_blog_notification() and wpmu_signup_user_notification() functions.
See #41017

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


git-svn-id: http://core.svn.wordpress.org/trunk@41070 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-04 14:21:43 +00:00
John Blackbourn
5062d7d134 Media: Move the Tests_Media::test_video_shortcode_body() method so it runs before other tests in the class that depend on it.
The following tests were never executed as they have `@depends` annotations which means they get skipped because the `test_video_shortcode_body()` test has not run by the time they run. Re-ordering the test methods fixes this.

* `test_wp_video_shortcode_with_empty_params()`
* `test_wp_video_shortcode_with_bad_attr()`
* `test_wp_video_shortcode_attributes()`
* `test_wp_video_shortcode_youtube_remove_feature()`
* `test_wp_video_shortcode_youtube_force_ssl()`
* `test_wp_video_shortcode_vimeo_force_ssl_remove_query_args()`
* `test_wp_video_shortcode_vimeo_adds_loop()`
* `test_wp_video_shortcode_vimeo_force_adds_loop_true()`

See #35367

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


git-svn-id: http://core.svn.wordpress.org/trunk@41069 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-04 14:06:43 +00:00
John Blackbourn
22779110c4 REST API: Populate some missing tests from test cases which extend the controller test case.
See #41463

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


git-svn-id: http://core.svn.wordpress.org/trunk@41068 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-04 13:56:46 +00:00
Andrea Fercia
a029f83fb5 Menus: Visually hide the menu item edit link text in a consistent way.
Fixes a visual glitch visible on Ubuntu. WordPress uses system fonts and they have
different metrics across operating systems. Uses screen-reader-text as a more
solid way to visually hide text.

Props punit5658, afercia.
Fixes #41497.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41067 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 22:12:43 +00:00
Felix Arntz
1d0478d4b1 REST API: Allow site administrators to edit user roles in multisite.
While site administrators cannot generally edit users in multisite, they have always been able to change the roles of users on their site. In the REST API however, this has not been possible so far. This changeset brings parity with how it is handled in the administration panel: A REST request to edit only a user's roles succeeds correctly, while a REST request to edit any further details of a user fails.

Props jnylen0.
Fixes #40263.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41066 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 21:59:44 +00:00
Felix Arntz
7e2ca92e69 Multisite: Introduce a can_add_user_to_blog filter to prevent adding a user to a site.
Under certain circumstances, it can be necessary that a user should not be added to a site, beyond the restrictions that WordPress core applies. With the new `can_add_user_to_blog` filter, plugin developers can run custom checks and return an error in case of a failure, that will prevent the user from being added.

The user-facing parts and the REST API route that interact with `add_user_to_blog()` have been adjusted accordingly to provide appropriate error feedback when a user could not be added to a site. Furthermore, two existing error feedback messages in the site admin's "New User" screen have been adjusted to properly show inside an error notice instead of a success notice.

Props jmdodd.
Fixes #41101.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41065 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 21:41:45 +00:00
Andrea Fercia
19aab9d3d6 REST API: Make jshint happy again after [41222].
See #40919.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41064 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 20:36:42 +00:00
James Nylen
0ef4d4289f REST API: Exclude numeric parameters from regex parsing
The list of endpoint parameters should only include explicitly named and requested parameters.

Props flixos90, rmccue, jnylen0.
Fixes #40704.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41063 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 19:55:43 +00:00
James Nylen
17c48865db REST API: Add QUnit tests for api-request.js
These should have been included in [41206].

See #40919.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41062 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 19:47:45 +00:00
John Blackbourn
4981452aba General: Fix more instances of inconsistent parameters passed to various filters, plus fix some filter docs.
See #38462, #41017

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


git-svn-id: http://core.svn.wordpress.org/trunk@41061 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 16:13:44 +00:00
John Blackbourn
38f91be819 General: Fix a typo introduced in [41219].
See #38462

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


git-svn-id: http://core.svn.wordpress.org/trunk@41060 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 15:46:44 +00:00
John Blackbourn
b140e8f574 General: Fix various instances of incorrect filter docs and incorrect filter and action parameters.
Props keesiemeijer for identifying the issues

See #38462

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


git-svn-id: http://core.svn.wordpress.org/trunk@41059 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 15:43:43 +00:00
Drew Jaynes
8e71c49a12 Docs: Add missing documentation for the $data parameter for WP_Http::browser_redirect_compatibility().
Props ronakganatra for the initial patch.
Fixes #41380.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41058 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 15:24:44 +00:00
John Blackbourn
375f495231 General: Add missing parameters to instances of the the_permalink filter.
This ensures every instance of this filter receives the same parameters.

Props keesiemeijer for identifying the issue

See #38462

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


git-svn-id: http://core.svn.wordpress.org/trunk@41057 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 14:59:44 +00:00
John Blackbourn
4cdbe950e9 Docs: Add a missing docblock for the the_content_rss filter.
See #38462, #41017

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


git-svn-id: http://core.svn.wordpress.org/trunk@41056 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 14:46:43 +00:00
John Blackbourn
d510413811 Docs: Fix various filter documentation.
See #38462, #41017

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


git-svn-id: http://core.svn.wordpress.org/trunk@41055 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 14:34:44 +00:00
John Blackbourn
763ac66754 Networks and Sites: Display an indicator for the active theme or child theme when viewing a site's themes within Network Admin.
Props palmiak, euthelup

Fixes #41168

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


git-svn-id: http://core.svn.wordpress.org/trunk@41054 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 13:49:43 +00:00
John Blackbourn
dee0e3a67b Users: Switch to using array style filters for the newly introduced filters in wp_password_change_notification() and wp_new_user_notification().
This introduces three new filters, replacing those that were introduced in [41153]:

* `wp_password_change_notification_email`
* `wp_new_user_notification_email_admin`
* `wp_new_user_notification_email`

Props pbearne

Fixes #38068

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


git-svn-id: http://core.svn.wordpress.org/trunk@41053 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-03 13:21:46 +00:00
John Blackbourn
c184d766e9 Docs: Correct and improve the documentation for the send_confirmation_on_profile_email() function and the new_user_email_content filter.
See #41017

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


git-svn-id: http://core.svn.wordpress.org/trunk@41049 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-02 20:43:44 +00:00
John Blackbourn
e0c397bdfa Docs: Correct and improve the documentation for the update_option_new_admin_email() function and the new_admin_email_content filter.
See #41017

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


git-svn-id: http://core.svn.wordpress.org/trunk@41048 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-02 20:04:43 +00:00
James Nylen
e77ac0c6eb Remove unnecessary semicolon
See #40919.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41047 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-02 17:16:44 +00:00
James Nylen
c91b130b53 REST API: Allow overriding jQuery.ajax calls from within wp-admin
There are now 3 places where we call out to the REST API from within wp-admin.  This commit introduces a small library to allow overriding these calls, centralize nonce-passing logic, and eliminate the need to pass a full REST URL down to client code (this last feature is not yet used and will be explored in a separate ticket).

Fixes #40919.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41046 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-02 16:45:44 +00:00
Weston Ruter
a193916f46 Customize: Introduce settings_previewed arg and getter on WP_Customize_Manager which controls whether WP_Customize_Setting::preview() should be called on settings.
The `settings_previewed` property eliminates the need for the Customizer components from having to look at global `doing_ajax` state. This is in particular needed when saving settings, as some settings will short-circuit the update operation if they detect no changes are introduced. This is also needed for low-level integrations with the Customizer, such as in REST API endpoints under development.

Props stubgo, westonruter, utkarshpatel for testing.
See #38900.
Fixes #39221.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41045 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-02 05:35:41 +00:00
Weston Ruter
eb658592df Customize: For selective refresh of nav menus, prevent preg_replace() from dropping backslashes in JSON replaced into the data-customize-partial-placement-context HTML attribute.
Props dlh, westonruter.
Fixes #41488.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41044 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-02 05:11:44 +00:00
Drew Jaynes
0401cee8b3 Docs: Reduce confusion in @since MU notationss by indicating the WP version (3.0.0) the code was merged into core while retaining the original context.
Props sathyapulse.
Fixes #41509.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41040 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-01 20:44:43 +00:00
John Blackbourn
ed60c36fb8 Formatting: Add the $number and $decimals arguments to the number_format_i18n filter.
Props alpipego

Fixes #41505

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


git-svn-id: http://core.svn.wordpress.org/trunk@41039 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-01 14:38:48 +00:00
Weston Ruter
7af3b92736 Media: Upgrade MediaElement.js from 2.22.0 to 4.2.3.
Props rafa8626, grosbouff, westonruter, azaozz, Plastikschnitzer for testing.
See #39686.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41038 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-01 04:43:51 +00:00
Andrea Fercia
59279ab349 Menus: Improve the responsive view for the Menu Name field and Save button.
Props punit5658.
Fixes #41499.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41037 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-31 21:22:44 +00:00
Scott Taylor
6bcf4d6f63 Media: update the getID3 library to version 1.9.14 to avoid fatal errors in PHP7.
Props MyThemeShop for the initial patch.
Fixes #41496.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41036 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-31 19:50:45 +00:00
Drew Jaynes
82d0a53e77 Docs: Use a third-person singular verb in the DocBlock summary for WP_Importer::stop_the_insanity().
Also add a missing `@since` tag. Introduced in 3.0.0, see [14760].

See #41017.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41035 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-30 15:46:43 +00:00
Drew Jaynes
4835f7e817 Docs: Add a missing description for the $wpdb global notation in the DocBlock for WP_Importer::stop_the_insanity().
Props tejas5989.
Fixes #41447.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41034 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-30 15:43:42 +00:00
Drew Jaynes
8fd5ec4e62 Docs: Use a third-person singular verb in the summary for _wp_customize_publish_changeset().
Also adding missing `@since` and `@access` tags. Introduced in 4.7, see [38810].

See #41017.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41033 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-30 15:34:42 +00:00
Drew Jaynes
6ce9846893 Docs: Document use of the $wpdb and $wp_customize globals in _wp_customize_publish_changeset().
Props sagarladani for the initial patch.
Fixes #41479.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41032 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-30 15:31:42 +00:00
Boone Gorges
42ac7e7e13 Taxonomy: Introduce pre_term_link filter.
This filter allows developers to filter the taxonomy permalink
structure before a term's permalink is generated. It parallels
the 'pre_post_link' filter for the 'post' post type.

Props nikeo.
Fixes #39601.
Built from https://develop.svn.wordpress.org/trunk@41191


git-svn-id: http://core.svn.wordpress.org/trunk@41031 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-30 15:10:44 +00:00
Boone Gorges
c657a2c060 Comments: Ignore the 'fields' parameter in the comment query cache.
`WP_Comment_Query` always queries runs an ID query, and so is unaffected
by the 'fields' parameter. As such, 'fields' can be ignored when building
a cache key for the results of the ID query.

Props spacedmonkey.
Fixes #41348.
Built from https://develop.svn.wordpress.org/trunk@41190


git-svn-id: http://core.svn.wordpress.org/trunk@41030 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-30 14:56:41 +00:00
Sergey Biryukov
e412ea2e6b Docs: Replace HTTP links to stackoverflow.com in DocBlocks with HTTPS.
Update the Nginx "Missing (disappearing) HTTP Headers" link.

Props johnpgreen.
Fixes #41331.
Built from https://develop.svn.wordpress.org/trunk@41189


git-svn-id: http://core.svn.wordpress.org/trunk@41029 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-30 14:52:44 +00:00
Boone Gorges
f1fb17fbb5 Ensure that an assertion takes place in Tests_Comment_Query::test_comment_query_should_be_cached().
Missed during [37608]. See #36906.

Fixes #41357.
Built from https://develop.svn.wordpress.org/trunk@41188


git-svn-id: http://core.svn.wordpress.org/trunk@41028 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-30 14:43:42 +00:00
Sergey Biryukov
3d26fab9f6 Post Formats: In bulk_edit_posts(), set post format before the post is updated, for consistency with edit_post().
This makes sure that plugins hooked to `save_post` get the right post format.

Props Chouby, SergeyBiryukov.
Fixes #41396.
Built from https://develop.svn.wordpress.org/trunk@41187


git-svn-id: http://core.svn.wordpress.org/trunk@41027 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-30 14:41:42 +00:00
Drew Jaynes
7f5e00ba29 Docs: Remove an unrelated description about post meta from the DocBlock for add_user_meta().
Clean up syntax.

See #41017.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41026 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-30 14:32:45 +00:00
Sergey Biryukov
a6e0b16749 Tests: Fully reset MockPHPMailer between tests.
Props pessoft.
Fixes #41485.
Built from https://develop.svn.wordpress.org/trunk@41185


git-svn-id: http://core.svn.wordpress.org/trunk@41025 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-29 20:53:42 +00:00
Sergey Biryukov
6a74b306da Plugins: In wp_star_rating(), use explicit type casting for $rating to avoid a "non-numeric value encountered" warning in PHP 7.1.
Clarify in the function DocBlock that `$rating` can be a float.

Props afragen.
Fixes #41484.
Built from https://develop.svn.wordpress.org/trunk@41184


git-svn-id: http://core.svn.wordpress.org/trunk@41024 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-29 20:35:45 +00:00
Pascal Birchler
66a3b24b72 Permalinks: Remove unnecessary semicolon after [41182].
See #29872.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41023 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-28 17:55:46 +00:00
Pascal Birchler
fd07b2254d Permalinks: Add buttons for the available structure tags to the admin UI.
Often times, it can be confusing to set a custom permalink structure. One has to double-check the documentation, make 
sure to correctly insert the structure tag, and hope not to break their site.

With this addition, the available structure tags are being displayed as a list of easily clickable buttons that can be 
used to insert tags to the custom structure input field and to remove them again.

Props kpdesign, swissspidy, joedolson, afercia.
Fixes #29872.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41022 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-28 17:43:45 +00:00
Sergey Biryukov
2b1644b974 Docs: Add a @staticvar entry for $first_dropdown in WP_Widget_Categories::widget().
Props ajayghaghretiya1.
Fixes #41473.
Built from https://develop.svn.wordpress.org/trunk@41181


git-svn-id: http://core.svn.wordpress.org/trunk@41021 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-28 14:25:42 +00:00
Sergey Biryukov
acb9773212 Users: After [41027], assign $author_posts_url outside of the condition to simplify the logic.
See #38085.
Built from https://develop.svn.wordpress.org/trunk@41180


git-svn-id: http://core.svn.wordpress.org/trunk@41020 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-28 14:21:45 +00:00
Weston Ruter
18fd50d2b6 Media: Improve acceptance of YouTube /embed/ URLs when inserting in media modal.
Props timmydcrawford.
Fixes #41201.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41019 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-28 02:36:46 +00:00
John Blackbourn
df808fc42d General: Move the __autoload() compat function into its own file to prevent deprecated notices being thrown by the compiler in PHP 7.2.
The `__autoload()` function is deprecated in PHP 7.2, which means WordPress' own `__autoload()` compat function for PHP 5.2 needs to be moved into a separate file to prevent the PHP 7.2 compiler from complaining.

Props ayeshrajans

See #40109

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


git-svn-id: http://core.svn.wordpress.org/trunk@41018 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-28 01:15:52 +00:00
John Blackbourn
4f2ef5438f Build/Test Tools: More PHP 7.2 tweaks for Travis CI.
See #40109

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


git-svn-id: http://core.svn.wordpress.org/trunk@41017 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 21:32:40 +00:00
John Blackbourn
9ae6e6fb54 REST API: Add some missing assertions to various REST API tests.
See #41463

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


git-svn-id: http://core.svn.wordpress.org/trunk@41016 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 19:04:44 +00:00
Aaron Jorbin
89fa297113 Build/Test Tools: Add PHP 7.2 to test matrix
PHP has branched 7.2 and master is now 7.3. This change ensures that 7.2 is tested. As 7.2 is still in development and is not ready for production, failures are allowed.

See #40109.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41015 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 17:38:42 +00:00
John Blackbourn
219de8acd5 General: Avoid counting uncountable values when reading theme directories, and in some unit tests.
See #40109

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


git-svn-id: http://core.svn.wordpress.org/trunk@41014 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 17:00:44 +00:00
John Blackbourn
96183d09bd Formatting: Update the author description tests since the formatting change made in [41172].
See #40040

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


git-svn-id: http://core.svn.wordpress.org/trunk@41013 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 16:06:55 +00:00
John Blackbourn
01e64d9ed0 Formatting: Add formatting and texturization to author descriptions so they match the formatting of term descriptions.
Props henry.wright

Fixes #40040

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


git-svn-id: http://core.svn.wordpress.org/trunk@41012 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 15:10:42 +00:00
John Blackbourn
fb515a8a63 Users: Further fixes to entitiy decoding in the user email address change confirmation email, and the corresponding tests.
See #16470, #40015

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


git-svn-id: http://core.svn.wordpress.org/trunk@41011 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 14:59:43 +00:00
John Blackbourn
efa54e6cdb Users: Update some tests for admin email change confirmation emails after [41164].
See #40015, #39117

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


git-svn-id: http://core.svn.wordpress.org/trunk@41010 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 14:34:42 +00:00
John Blackbourn
2e767d2e1a Build/Test Tools: Clarify the error message when running the test suite without the WordPress Importer plugin present in the test suite.
See #41345

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


git-svn-id: http://core.svn.wordpress.org/trunk@41009 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 14:01:42 +00:00
Drew Jaynes
8c7f5367c0 Docs: Remove some more top-level @aacess tags from function DocBlocks.
See #414532.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41008 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 08:19:43 +00:00
John Blackbourn
6a16d726ef Options, Meta APIs: Fix a typo introduced in [41164].
See #39117

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


git-svn-id: http://core.svn.wordpress.org/trunk@41007 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 03:12:44 +00:00
John Blackbourn
ff20054573 Users: Add the new email address to the email address change notification email.
Fixes #39112

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


git-svn-id: http://core.svn.wordpress.org/trunk@41006 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 02:57:43 +00:00
John Blackbourn
30d5450508 Users: Re-add entity decoding to the site name before it's used in the email address change confirmation email.
This was accidentally removed in [41163].

See #40015, #16470

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


git-svn-id: http://core.svn.wordpress.org/trunk@41005 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 02:55:43 +00:00
John Blackbourn
b9b4776800 Options, Meta APIs: Send a notification to the old admin email address when the site admin email or network admin email address is changed.
This reduces the chances of a site compromise going unnoticed, in the same way that the same notifications for user account email address changes reduces the chances of a user account compromise going unnoticed.

Props MatheusGimenez, johnbillion

Fixes #39117

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


git-svn-id: http://core.svn.wordpress.org/trunk@41004 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 02:24:42 +00:00
John Blackbourn
62fe4be994 Users: Require a confirmation link in an email to be clicked when a user attempts to change their email address.
This adds this previously Multisite-only functionality to single site installations too. This change prevents accidental or erroneous email address changes from potentially locking users out of their account.

Props rodrigosprimo, tharsheblows, johnbillion

Fixes #16470

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


git-svn-id: http://core.svn.wordpress.org/trunk@41003 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 02:10:42 +00:00
Drew Jaynes
0860bb2771 Docs: Remove @access notations from method DocBlocks in wp-includes/* classes.
Prior to about 2013, many class methods lacked even access modifiers which made the `@access` notations that much more useful. Now that we've gotten to a point where the codebase is more mature from a maintenance perspective and we can finally remove these notations. Notable exceptions to this change include standalone functions notated as private as well as some classes still considered to represent "private" APIs.

See #41452.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41002 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 00:41:44 +00:00
Drew Jaynes
1a28ec87e1 Docs: Remove @access notations from method DocBlocks in wp-admin/* classes.
Prior to about 2013, many class methods lacked even access modifiers which made the `@access` notations that much more useful. Now that we've gotten to a point where the codebase is more mature from a maintenance perspective and we can finally remove these notations. Notable exceptions to this change include standalone functions notated as private as well as some classes still considered to represent "private" APIs.

See #41452.

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


git-svn-id: http://core.svn.wordpress.org/trunk@41001 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-27 00:40:43 +00:00
John Blackbourn
32128ffd45 Administration: Remove Edit links from all plugin listing screens and the remaining theme listing screens.
This simplifies these list tables, reducing user confusion, without removing functionality.

Fixes #38169

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


git-svn-id: http://core.svn.wordpress.org/trunk@41000 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-26 23:28:46 +00:00
John Blackbourn
be94fa5483 Toolbar: Add View User and Edit User links to the admin toolbar to ease navigation between a user's archives and the user editing screen.
Props georgestephanis, lessbloat, johnbillion

Fixes #20307

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


git-svn-id: http://core.svn.wordpress.org/trunk@40999 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-26 16:45:44 +00:00
John Blackbourn
6b22dbe59a Login and Registration: Introduce a username_exists filter, which allows for control over registration of usernames.
Props shamim51

Fixes #39320

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


git-svn-id: http://core.svn.wordpress.org/trunk@40998 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-26 16:25:40 +00:00
Sergey Biryukov
c7feb8387a Upgrade/Install: In WP_Ajax_Upgrader_Skin, call ::get_error_codes() method on a WP_Error object $this->errors instead of a string variable $errors.
Props yrpwayne.
Fixes #41449.
Built from https://develop.svn.wordpress.org/trunk@41157


git-svn-id: http://core.svn.wordpress.org/trunk@40997 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-26 13:39:44 +00:00
Sergey Biryukov
7d2b400876 Users: Use esc_url() instead of esc_attr() to escape the value of the srcset attribute in get_avatar().
Props joemcgill, henry.wright.
Fixes #41215.
Built from https://develop.svn.wordpress.org/trunk@41156


git-svn-id: http://core.svn.wordpress.org/trunk@40996 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-26 13:22:44 +00:00
Gary Pendergast
a89f1e469b REST API: Update the fixture data for wp-api.js tests.
[41139] changed how the REST API URL is generated, but included an incorrect version of `wp-api-generated.js`.

This updates the generator to create the correct `wp-api-generated.js`, and updates ``wp-api-generated.js`.

See #40886.


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


git-svn-id: http://core.svn.wordpress.org/trunk@40994 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-26 03:53:42 +00:00
John Blackbourn
b6ca2d77a8 Users: Introduce filters for the contents of email notifications for new user registrations and password resets.
Introduces:

* `wp_password_change_notification_subject`
* `wp_password_change_notification_message`
* `wp_password_change_notification_headers`
* `wp_new_user_notification_admin_subject`
* `wp_new_user_notification_admin_message`
* `wp_new_user_notification_admin_headers`
* `wp_new_user_notification_subject`
* `wp_new_user_notification_message`
* `wp_new_user_notification_headers`

Props pbearne, dipesh.kakadiya

Fixes #38068

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


git-svn-id: http://core.svn.wordpress.org/trunk@40993 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-26 00:54:43 +00:00
Sergey Biryukov
760d2b3771 I18N: Use a consistent context for Visual and Text editor tab labels.
Props pedromendonca.
Fixes #41438.
Built from https://develop.svn.wordpress.org/trunk@41152


git-svn-id: http://core.svn.wordpress.org/trunk@40992 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-25 22:58:41 +00:00
Sergey Biryukov
4e4df0e6c9 Docs: Use 3-digit, x.x.x style semantic versioning for @since 4.8.0 entries.
See #41017.
Built from https://develop.svn.wordpress.org/trunk@41151


git-svn-id: http://core.svn.wordpress.org/trunk@40991 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-25 22:48:42 +00:00
John Blackbourn
2dfea4210b Users: Show a Super Admin label next to Super Admins on all user listing screens when the current user can manage network users.
Fixes #41165

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


git-svn-id: http://core.svn.wordpress.org/trunk@40990 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-25 17:43:42 +00:00
Andrea Fercia
de31d6f81c Widgets: make the Recent Posts widget output '(no title)' for posts without a title.
Since WordPress 2.3, the Recent Posts widget used to output the post ID for posts
with an empty title. Using '(no title)' seems a best option and is consistent with
what's already used in other similar cases.

Props antonrinas, Ankit K Gupta.
Fixes #35709.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40989 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-25 16:13:45 +00:00
Andrea Fercia
ac82a26fc5 Administration: WP_Screen: strip all tags from the columns display name.
This ensures all the column titles, not just the Comments column one, are
"clean" when later reused for the Screen Options checkboxes. Also introduces
some consistency with what is already done in WP_List_Table.

Fixes #41261.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40988 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-25 16:05:44 +00:00
Sergey Biryukov
c957321007 Docs: Correct @global entry for $cat_id in WP_Links_List_Table::column_categories().
Props tejas5989.
Fixes #41436.
Built from https://develop.svn.wordpress.org/trunk@41147


git-svn-id: http://core.svn.wordpress.org/trunk@40987 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-25 13:19:42 +00:00
Sergey Biryukov
37a04795b2 Docs: Add a @global entry for $wpdb in _get_cron_lock.
Props tejas5989.
Fixes #41433.
Built from https://develop.svn.wordpress.org/trunk@41146


git-svn-id: http://core.svn.wordpress.org/trunk@40986 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-25 12:56:43 +00:00
Sergey Biryukov
0a24e8d1cd Docs: Add @access entry for WP_Comment_Query::fill_descendants().
Props umangvaghela123.
Fixes #41435.
Built from https://develop.svn.wordpress.org/trunk@41145


git-svn-id: http://core.svn.wordpress.org/trunk@40985 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-25 12:54:45 +00:00
Weston Ruter
4042c0b416 TinyMCE: Fix styling of selected state for linked images containing captions.
Props azaozz.
Fixes #41408.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40981 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-25 02:19:42 +00:00
Gary Pendergast
7819daefd2 REST API: Always add index.php to the REST URL when pretty permalinks are disabled.
When pretty permalinks are disabled, the web server will internally forward requests to `index.php`. Unfortunately, nginx only forwards HTTP/1.0 methods: `PUT`, `PATCH`, and `DELETE` methods will return a 405 error.

To work around this nginx behaviour, including `index.php` in the REST URL skips the internal redirect.

Fixes #40886.


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


git-svn-id: http://core.svn.wordpress.org/trunk@40979 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-25 00:50:43 +00:00
John Blackbourn
b4c2f16d01 Users: Ensure that users with no role on a site are taken into consideration when listing users on Multisite.
This ensures that users who are a member of a site but have no role are correctly listed on the Users screen and can be filtered from the 'None' role filter.

Props tobi823, flixos90, scottlee

Fixes #36196

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


git-svn-id: http://core.svn.wordpress.org/trunk@40978 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-25 00:24:43 +00:00
Weston Ruter
8648fc0bff Customize: Update Text widget starter content to utilize visual mode.
Amends [38991].
Props dlh, westonruter.
See #35243, #38114.
Fixes #41410.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40976 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-24 23:25:44 +00:00
Weston Ruter
4886abf23e Widgets: Improve notice in Text widget's legacy mode.
Also fixes phpunit test which broke in [41132].

Props melchoyce, westonruter, gk.loveweb.
See #41394, #35243, #40951, #40907.
Fixes #41386.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40974 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-24 23:11:43 +00:00
Weston Ruter
ddca4ceff1 Widgets: Rename Text widget's legacy mode to non-visual mode, restore boolean filter prop, and improve compatibility for widget_text filters applied in Custom HTML widget.
Props westonruter, obenland, timmydcrawford for testing.
Amends [41050].
See #35243, #40951, #40907.
Fixes #41394.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40972 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-24 22:46:42 +00:00
John Blackbourn
d8151e9dd1 Networks and Sites: Introduce an AYS when bulk deleting sites from the Sites screen in Network Admin.
Props flixos90, MaximeCulea

Fixes #41177

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


git-svn-id: http://core.svn.wordpress.org/trunk@40971 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-24 22:41:42 +00:00
John Blackbourn
06e6edbd61 Comments: Ensure the correct comment ID is passed to the get_comment_author_url filter.
Props dominik.schwind

Fixes #41334

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


git-svn-id: http://core.svn.wordpress.org/trunk@40967 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-24 22:03:45 +00:00
Sergey Biryukov
8c55e79bef Docs: Correct @access entry for ::load() in WP_Image_Editor, WP_Image_Editor_GD, and WP_Image_Editor_Imagick.
Props upadalavipul.
Fixes #41423.
Built from https://develop.svn.wordpress.org/trunk@41125


git-svn-id: http://core.svn.wordpress.org/trunk@40965 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-24 14:11:44 +00:00
Sergey Biryukov
bed4804424 Tests: Fix typo in Tests_Functions_AllowedProtocols::data_example_urls().
Props redrambles.
Fixes #41415.
Built from https://develop.svn.wordpress.org/trunk@41124


git-svn-id: http://core.svn.wordpress.org/trunk@40964 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-24 10:03:44 +00:00
Sergey Biryukov
00b91b3003 Docs: Add a @global entry for $wpdb in WP_Comment_Query::fill_descendants().
Props jontyravi.
Fixes #41412.
Built from https://develop.svn.wordpress.org/trunk@41123


git-svn-id: http://core.svn.wordpress.org/trunk@40963 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-23 10:40:45 +00:00
John Blackbourn
2d464d4286 Users: Don't show the 'Add Existing User' form on the 'Add New User' screen to users without the promote_users capability.
Props bseddon, Mista-Flo

Fixes #37836

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


git-svn-id: http://core.svn.wordpress.org/trunk@40962 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-23 01:14:43 +00:00
John Blackbourn
1d71fa865c Login and Registration: Correctly encode the redirect location URL when it's passed as a query parameter to the lost password URL.
Props adhun

Fixes #40728

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


git-svn-id: http://core.svn.wordpress.org/trunk@40961 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-23 01:06:42 +00:00
John Blackbourn
2efb81d453 Administration: Send an appropriate HTTP response status code when an invalid action is passed to admin-ajax.php.
Props ryanrolds, ayeshrajans

Fixes #41269

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


git-svn-id: http://core.svn.wordpress.org/trunk@40960 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-23 00:21:42 +00:00
John Blackbourn
a4a0f65a8a Docs: Correct some inline docs for the Ajax test case.
See #41017

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


git-svn-id: http://core.svn.wordpress.org/trunk@40959 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-23 00:02:46 +00:00
Weston Ruter
f3ec3c36a0 Widgets: Fix typo in phpunit test for Custom HTML widget in [41116].
Fixed was applied in 4.8 branch via [41117].
See #41392.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40958 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-21 21:22:42 +00:00
Weston Ruter
f283e9d81f Widgets: Include widget_text class name on Custom HTML widget wrapper for theme styling compatibility, in addition to previously-added textwidget class on nested content container.
Amends [40893], [41115].
See #40907.
Fixes #41392 for trunk.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40956 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-21 21:02:43 +00:00
Weston Ruter
048ac7df67 Widgets: Improve theme styling compatibility for Custom HTML widget by adding container with textwidget class.
The same styling from the Text widget should apply to the Custom HTML widget since users are expected to copy HTML from the (legacy) Text widget into the latter.

Amends [40893].
See #40907.
Fixes #41392.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40955 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-21 18:13:45 +00:00
Sergey Biryukov
e8e68a50f8 Docs: Correct $term_id parameter description in wp_xmlrpc_server::get_term_custom_fields() and ::set_term_custom_fields().
Props upadalavipul.
Fixes #41397.
Built from https://develop.svn.wordpress.org/trunk@41114


git-svn-id: http://core.svn.wordpress.org/trunk@40954 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-21 13:40:43 +00:00
Sergey Biryukov
118dba300e Docs: Add @staticvar entries for $cache and $tested_paths in wp_upload_dir().
Props ajayghaghretiya1.
Fixes #41395.
Built from https://develop.svn.wordpress.org/trunk@41113


git-svn-id: http://core.svn.wordpress.org/trunk@40953 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-21 10:15:44 +00:00
K. Adam White
6aaba32b36 WP-API JS Client: Interpret Settings resource as a model.
The REST API does not provide a mechanism to distinguish between endpoints representing models and those representing collections, so the Backbone client must make that distinction internally. Previously wp-api.js accounted for `/users/me`, but not for `/settings`. This patch updates the logic so that `/settings` is properly registered as a Backbone model.

When calling `wp.api.init`, additional endpoints can be specified to be models using the `modelEndpoints` argument.

Props @adamsilverstein.
Fixes #41056.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40952 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 20:26:45 +00:00
Sergey Biryukov
970afde4c0 Docs: Add a @global entry for $wpdb in get_author_user_ids(), get_editable_authors(), get_editable_user_ids(), get_nonauthor_user_ids(), and get_others_unpublished_posts().
Props parthsanghvi.
Fixes #41368.
Built from https://develop.svn.wordpress.org/trunk@41111


git-svn-id: http://core.svn.wordpress.org/trunk@40951 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 14:02:44 +00:00
Sergey Biryukov
4653f8bcfa Docs: Add a @global entry for $wp_filesystem in wp_ajax_install_theme(), wp_ajax_update_theme(), wp_ajax_delete_theme(), wp_ajax_install_plugin(), wp_ajax_update_plugin(), and wp_ajax_delete_plugin().
Props ronakganatra.
Fixes #41382.
Built from https://develop.svn.wordpress.org/trunk@41110


git-svn-id: http://core.svn.wordpress.org/trunk@40950 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 13:47:43 +00:00
Sergey Biryukov
3946198df8 Docs: Add @staticvar entries for get_html_split_regex() and _get_wptexturize_split_regex().
Props ajayghaghretiya1.
Fixes #41385.
Built from https://develop.svn.wordpress.org/trunk@41109


git-svn-id: http://core.svn.wordpress.org/trunk@40949 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 13:38:44 +00:00
Sergey Biryukov
24f6903c4d Docs: Add @access entries for WP_Upgrader_Skin::set_upgrader(), ::request_filesystem_credentials(), and ::decrement_update_count().
See #41383.
Built from https://develop.svn.wordpress.org/trunk@41108


git-svn-id: http://core.svn.wordpress.org/trunk@40948 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 13:35:43 +00:00
Sergey Biryukov
8728f8ae1e Docs: Add @access entry for Automatic_Upgrader_Skin::request_filesystem_credentials().
Props rushabh4486.
Fixes #41383.
Built from https://develop.svn.wordpress.org/trunk@41107


git-svn-id: http://core.svn.wordpress.org/trunk@40947 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 13:33:43 +00:00
Sergey Biryukov
f8155cedb2 Docs: Add @access entries for Bulk_Upgrader_Skin::before() and ::after().
Props rushabh4486.
Fixes #41384.
Built from https://develop.svn.wordpress.org/trunk@41106


git-svn-id: http://core.svn.wordpress.org/trunk@40946 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 13:25:42 +00:00
Sergey Biryukov
54b8dafd62 Docs: Change @version entry for WP_Http::buildCookieHeader() to @since.
See #41381.
Built from https://develop.svn.wordpress.org/trunk@41105


git-svn-id: http://core.svn.wordpress.org/trunk@40945 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 13:15:43 +00:00
Sergey Biryukov
2026da9512 Docs: Add @access entries for WP_Http::block_request(), ::handle_redirects(), and ::is_ip_address().
Props ronakganatra.
Fixes #41381.
Built from https://develop.svn.wordpress.org/trunk@41104


git-svn-id: http://core.svn.wordpress.org/trunk@40944 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 13:14:44 +00:00
Sergey Biryukov
47bf429c0b Docs: Add @access entries for before() and after() methods in Bulk_Plugin_Upgrader_Skin and Bulk_Theme_Upgrader_Skin.
See #41365.
Built from https://develop.svn.wordpress.org/trunk@41103


git-svn-id: http://core.svn.wordpress.org/trunk@40943 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 12:09:43 +00:00
Sergey Biryukov
90372258a0 Docs: Add @access entries for __construct() in WP_Upgrader_Skin, Bulk_Upgrader_Skin, Language_Pack_Upgrader_Skin, Plugin_Upgrader_Skin, and Theme_Upgrader_Skin.
Props rushabh4486.
Fixes #41376.
Built from https://develop.svn.wordpress.org/trunk@41102


git-svn-id: http://core.svn.wordpress.org/trunk@40942 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 12:06:43 +00:00
Sergey Biryukov
27c38e9b6f Docs: Add @access entries for feedback() and error() methods in WP_Upgrader_Skin, Bulk_Upgrader_Skin, and Language_Pack_Upgrader_Skin.
See #41365.
Built from https://develop.svn.wordpress.org/trunk@41101


git-svn-id: http://core.svn.wordpress.org/trunk@40941 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 12:00:43 +00:00
Sergey Biryukov
5734818e35 Docs: Add @access entries for $admin_header_callback and $admin_image_div_callback properties in Custom_Image_Header and Custom_Background.
Props rushabh4486.
Fixes #41377.
Built from https://develop.svn.wordpress.org/trunk@41100


git-svn-id: http://core.svn.wordpress.org/trunk@40940 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 11:54:43 +00:00
Sergey Biryukov
feeab7ef05 Docs: Correct @access entry for Custom_Image_Header::default_headers.
Props rushabh4486.
Fixes #41378.
Built from https://develop.svn.wordpress.org/trunk@41099


git-svn-id: http://core.svn.wordpress.org/trunk@40939 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-20 11:48:45 +00:00
James Nylen
f48ed236ff About page: Add a privacy policy.
Props MattyRob, johnbillion, swissspidy.
Fixes #40794.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40936 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-19 21:42:42 +00:00
Weston Ruter
8b3d2e0876 Widgets: Improve Text widget's reliability in syncing Visual tab's contents with Text tab and with hidden sync inputs.
Amends [40631].
Props azaozz, westonruter, rinkuyadav999 for testing.
See #35243.
Fixes #40974 for trunk.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40934 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-19 20:49:45 +00:00
Andrew Ozz
a798266ba3 TinyMCE: remove unused code from the wpeditimage plugin.
Fixes #41369.
Built from https://develop.svn.wordpress.org/trunk@41092


git-svn-id: http://core.svn.wordpress.org/trunk@40932 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-19 13:41:46 +00:00
Sergey Biryukov
9ed31682db Docs: Add @access entry for Automatic_Upgrader_Skin::feedback().
Props akbarhusen.
Fixes #41365.
Built from https://develop.svn.wordpress.org/trunk@41091


git-svn-id: http://core.svn.wordpress.org/trunk@40931 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-19 11:14:45 +00:00
James Nylen
793dd51f88 Tests: Be more helpful when the wordpress-importer plugin is missing.
Link to some documentation that explains the problem and how to resolve it.

Props enrico.sorcinelli.
Fixes #41345.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40930 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-19 10:38:47 +00:00
Weston Ruter
9330e39b3d Widgets: Check for existence of wp.customize.state before attempting to access in Text widget.
Amends [40631].
See #35243.
Fixes #41361 for trunk.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40928 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-18 22:36:42 +00:00
Weston Ruter
1a005d853f Widgets: Replace adding balanceTags on widget_custom_html_content filter in favor of just applying widget_text filters in the Custom HTML widget.
Ensures that users who copy HTML from the Text widget in legacy mode over to the Custom HTML widget will continue to get all of the same filters applied, including tag balancing and shortcodes, if a plugin added support. Plugins still have the `widget_text_content` and `widget_custom_html_content` filters they can use to target the specific widget types.

Amends [40893].
See #40951.
Fixes #40907 for trunk.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40926 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-18 22:11:44 +00:00
James Nylen
bcdbe8a0bf Build: Switch PHP 5.2 and 5.3 to Travis' Ubuntu precise image
Starting today, Travis will begin switching the default image to `trusty`, which does not support PHP 5.2 or 5.3.

This is not a full fix, because Travis will be dropping `precise` support entirely in September (https://github.com/travis-ci/travis-ci/issues/8072).  However, it buys us some time until then.

Props netweb.
Fixes #41292 for trunk.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40924 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-18 08:25:46 +00:00
Weston Ruter
770fb1b35c Widgets: Discount shortcodes and leading/trailing line breaks for triggering Text widget legacy mode.
Since plugin-added shortcode handling is just-in-time deferred to run after `wpautop`, there is no need to retain the presence of shortcodes to trigger legacy mode. Also updates Text widget legacy mode notice informing of Custom HTML widget.

Amends [41050].
Props westonruter, melchoyce.
Fixes #40951 for trunk.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40922 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-18 04:17:43 +00:00
Felix Arntz
21f6d256b5 Multisite: Remove help text duplication on Edit Site screens in the network admin.
Prior to this change, the similar help tab and sidebar for these screens were all duplicated for each respective screen. This changeset introduces two internal admin functions `get_site_screen_help_tab_args()` and `get_site_screen_help_sidebar_content()` that make these available in a centralized location.

Props atanasangelovdev.
Fixes #41167.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40917 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-17 20:53:45 +00:00
Felix Arntz
c939425137 Multisite: Fix a user-facing message when adding a new site with a new user as admin.
Previously the message would falsely state that the username and password would be sent to the new user. It is actually a link to set the password that they receive in the email.

Props nishitlangaliya.
Fixes #41169.

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


git-svn-id: http://core.svn.wordpress.org/trunk@40916 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-07-17 20:23:43 +00:00