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