Commit Graph

36225 Commits

Author SHA1 Message Date
Gary Pendergast dc63393569 Build/Test Tools: Pass correct `$message` argument to `WP_UnitTestCase::setExpectedException()` in `Tests_Ajax_CompressionTest::test_logged_out()` and `Tests_Ajax_TagSearch::test_no_results()`.
PHPUnit 6.4.1 and earlier versions ignored the `'0'` value, causing the issue to go unnoticed.

Merge of [41870] to the 4.7 branch.

Props SergeyBiryukov.
See #42232.



git-svn-id: https://develop.svn.wordpress.org/branches/4.7@42052 602fd350-edb4-49c9-b593-d223f7449a82
2017-10-31 06:19:42 +00:00
Dominik Schilling (ocean90) ed053e1cd6 Taxonomy/Users: Use correct escaping function for URLs.
Merge of [41522] to the 4.7 branch.

git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41524 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 21:20:09 +00:00
Dominik Schilling (ocean90) 71cf727550 Bump 4.7 branch to version 4.7.6.
git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41511 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 19:55:25 +00:00
Dominik Schilling (ocean90) 065a0ac2f4 Bump 4.7 branch to version 4.7.3.
git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41510 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 19:50:22 +00:00
Aaron D. Campbell c134dea3b6 Database: Hardening to bring `wpdb::prepare()` inline with documentation.
`wpdb::prepare()` supports %s, %d, and %F as placeholders in the query string. Any other non-escaped % will be escaped.

Merges [41496] to 4.7 branch.



git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41498 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 18:11:46 +00:00
Aaron D. Campbell 48d3ca8825 Database: Don’t trigger `_doing_it_wrong()` for null values in `wpdb::prepare()`.
While `wpdb::prepare()` does not support null values (see #12819) they still appear in the wild like in the WordPress Importer and other plugins.

Merges [41483] to 4.7 branch.



git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41485 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 16:18:58 +00:00
Aaron D. Campbell 66f675be1c Database: Hardening for `wpdb::prepare()`
Previously if you passed an array of values for placeholders, additional values could be passed as well. Now additional values will be ignored.

Merges [41470] to 4.7 branch.



git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41472 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 14:58:49 +00:00
John Blackbourn 1dcdbc9d60 Filesystem API: Ensure filenames are valid before attempting to unzip them to ensure malformed file paths don't cause issues.
Merges [41457] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41459 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 14:38:01 +00:00
Aaron D. Campbell 61c059d708 oEmbed: Add extra hardening around allowed HTML for improved sandboxing.
Merges [41448] to 4.7 branch.




git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41451 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 13:47:30 +00:00
Dominik Schilling (ocean90) f97c9838d5 TinyMCE: Improve the previews for shortcodes.
Merge of [41395] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41436 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 12:40:10 +00:00
Dominik Schilling (ocean90) 55f0d1aeb1 Customize: Ensure valid themes in the preview.
Merge of [41397] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41430 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 11:49:40 +00:00
Dominik Schilling (ocean90) b7b7358c90 Taxonomy/Users: Provide a fallback for incorrect HTTP referrers.
Merge of [41398] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41418 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 11:10:23 +00:00
John Blackbourn db84ba77ad General: Add missing URL-encoding and add extra hardening to plugin and template names when they're displayed in the admin area.
Merges [41412] to the 4.7 branch

See #13377


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41413 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 10:17:44 +00:00
Dominik Schilling (ocean90) dd44bf6b4c Editor: Prevent adding `javascript:` and `data:` URLs through the inline link dialog.
Merge of [41393] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41401 602fd350-edb4-49c9-b593-d223f7449a82
2017-09-19 10:14:45 +00:00
John Blackbourn 597a88861b Build/Test tools: Trim the test matrix on Travis in order to speed up the 4.7 branch build.
This removes the PHP 7.0, 5.5, 5.4, 5.3, and nightly jobs.

Fixes #41707


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41307 602fd350-edb4-49c9-b593-d223f7449a82
2017-08-22 21:40:43 +00:00
John Blackbourn f780dd4734 Build/Test Tools: Remove ancient UT ticket handling for the 4.7 branch.
See #40533

Merges [40523] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41305 602fd350-edb4-49c9-b593-d223f7449a82
2017-08-22 19:58:16 +00:00
John Blackbourn 0935a18cc7 Build/Test tools: Use the latest in the 4.x and 6.x branches of PHPUnit when running tests on Travis for the 4.7 branch.
See #41472

Merges [41294] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41296 602fd350-edb4-49c9-b593-d223f7449a82
2017-08-22 17:10:00 +00:00
John Blackbourn d18912d27f 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.

See #41292

Merges [41072] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@41074 602fd350-edb4-49c9-b593-d223f7449a82
2017-07-18 13:05:09 +00:00
John Blackbourn f58726da4b Build/Test Tools: Fix PHP 5.2 compatibility for grandchild methods which expect exceptions to be raised.
This is due to `is_callable( 'parent::setExpectedException' )` not being supported on PHP 5.2 when the method being checked only exists on the grandparent class.

See #39822

Merges [40872] and [40873] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40876 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-05 10:41:02 +00:00
Konstantin Obenland 98e9eaa3e1 Import Twenty Sixteen for the 4.7 branch.
See #36497.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40855 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-30 22:56:39 +00:00
John Blackbourn a10eba08e9 Build/Test Tools: Add a missing class to the PHPUnit 6 back compat.
See #39822

Merges [40853] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40854 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-30 22:07:59 +00:00
Aaron D. Campbell 20b5d4a4e0 Post-4.7.5 version bump for 4.7 branch.
git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40770 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-16 23:00:35 +00:00
Aaron D. Campbell 7719ada25f Bump 4.7 branch to version 4.7.5.
git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40748 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-16 21:47:01 +00:00
Pascal Birchler f5bc3b5a12 Media: Simplify upload error message construction.
Merges [40736] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40737 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-16 17:59:37 +00:00
Pascal Birchler f54b1461ac REST API: JS Client - Enable connecting to multiple endpoints.
Enable connecting to multiple wp-api `endpoints`. Calling `wp.api.init` with a new `apiRoot` will parse the new endpoint's schema and store a new set of models and collections. A collection of 
connected endpoints is stored in `wp.api.endpoints`.

Props lucasstark.
Fixes #39683.

Merges [40364] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40735 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-16 16:34:22 +00:00
Aaron D. Campbell 38b02ca333 Add nonce for updating file system credentials.
Merges [40723] to 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40724 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-16 14:50:27 +00:00
Weston Ruter 76b080defd Customize: Fix phpunit tests after [40704] due to logic inversion error.
Merge of [40716] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40717 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-16 14:36:53 +00:00
Dominik Schilling (ocean90) 85bc8c5dc3 Customize: Ignore invalid customization sessions.
Merge of [40704] to the 4.7 branch.

git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40705 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-16 12:13:07 +00:00
Pascal Birchler 8c2038b21f Adjust post meta checks
Merges [40692] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40693 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-16 08:47:33 +00:00
Pascal Birchler 8a28180db9 Improve redirect handling
Merges[40689] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40690 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-16 08:39:47 +00:00
Pascal Birchler 40ece6751b Whitelist post arguments in XML-RPC
Merges [40677] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40678 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-16 08:16:13 +00:00
Aaron Jorbin 4326500e82 Build/Test: Post Travis results to Slack from WordPress/wordpress-develop
Backports [40604] to 4.7

Now that the WordPress/wordpress-develop GitHub repo is syncing correctly, we can use it for Travis integration.

Props jorbin for getting the ball rolling so long ago, unprops jorbin because his Travis build can finally be retired. Props Pento.

Fixes #40712.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40616 602fd350-edb4-49c9-b593-d223f7449a82
2017-05-11 00:30:29 +00:00
John Blackbourn 8cbc520a94 Build/Test Tools: Backport various recent changes to the 4.7 branch.
* Add support for PHPUnit 6+.
* Add Composer files to the cache on Travis.
* Remove HHVM from the test infrastructure on Travis.

Merges [40536], [40538], [40539], and [40546] to the 4.7 branch.

See #40539
Fixes #39822, #40548


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40547 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-24 00:37:19 +00:00
Boone Gorges a82fe2b598 Restore support for taxonomy 'args' override when querying object terms.
[7520] introduced an undocumented feature whereby developers could
register a custom taxonomy with an 'args' parameter, consisting of
an array of config params that, when present, override corresponding
params in the `$args` array passed to `wp_get_object_terms()` when
using that function to query for terms in the specified taxonomy.

The `wp_get_object_terms()` refactor in [38667] failed to respect
this secret covenant, and the current changeset atones for the
transgression.

Ports [40513] to the 4.7 branch.

Props danielbachhuber.
Fixes #40496.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40514 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-21 19:18:00 +00:00
Dion Hulse 2c0ecb234a List Tables: After [38703], [38706], and [40118], adjust the jQuery selector to make the selection of a range of checkboxes work again.
Unprop afercia.
Merges [40268] to the 4.7 branch.
Fixes #40056.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40512 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-21 07:35:13 +00:00
Pascal Birchler 97f31221c1 Post-4.7.4 version bump for 4.7 branch.
git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40509 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-20 18:53:04 +00:00
Pascal Birchler 986f929a4d Bump 4.7 branch to version 4.7.4.
git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40487 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-20 16:20:22 +00:00
Andrew Ozz 16b1859218 TinyMCE: Fix cursor position after updating a wpview node. Fix hiding the inline toolbar on editor blur.
Props iseulde, azaozz.

Merges [40481] to the 4.7 branch.
Fixes #40480.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40482 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-19 22:17:25 +00:00
Pascal Birchler 45e83df257 Bump 4.7 branch to 4.7.4-RC1.
git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40475 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-18 17:05:28 +00:00
Pascal Birchler 7efa7c5af2 4.7.4-RC
git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40474 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-18 15:51:27 +00:00
Pascal Birchler ea9c78ce42 Twenty Seventeen: Bump version and update the changelog.
Updates changelog to link to Codex pages, like other default themes.

Props swissspidy, davidakennedy.
Fixes #40461.

Merges [40472] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40473 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-18 09:21:52 +00:00
Pascal Birchler aae4c43484 Fix broken audio/video functions when sanitizing ID3 data
This fixes a bug where running `wp_kses_post_deep()` on all the ID3
tag data corrupted blob data.

Fixes #40075, #40085.

Merges [40400] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40460 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-17 12:59:21 +00:00
Pascal Birchler 02c197a874 Twenty Seventeen: Correct heading hierarchy for posts on the front page.
When the posts page is on the front page or within a front page section, the heading hierarchy for the individual post titles needs to be adjusted accordingly.

Props joedolson, celloexpressions, davidakennedy.
Fixes #40264.

Merges [40458] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40459 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-17 10:23:25 +00:00
John Blackbourn e412ead1ac Build/Test tools: Reverse the order in which the Travis jobs run.
As a general rule, this means the fastest test jobs now run first because each subsequent version of PHP is faster than the previous. When a committer is patiently waiting for a Travis build to complete, they are at least more likely to see unexpected failures earlier than they otherwise would.

In addition, this updates the JavaScript test job to run on PHP 7.1.

Props netweb

See #39705

Merges [40434] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40435 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-15 17:44:01 +00:00
Pascal Birchler 232293a9f5 Media: Ensure Crop Image is always visible.
Previously, the crop button in the media modal after uploading header images or similar was hidden and the task could not be completed.

Props karinedo, sagarprajapati, Cybr, mayurk.
Fixes #40152.

Merges [40428] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40429 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-14 09:33:35 +00:00
Pascal Birchler 6c2132089e REST API: Allow fetching multiple terms at once via the slug parameter.
This matches a similar change previously made for posts (#38579) and an upcoming change for users (#40213).

Props wonderboymusic, MatheusGimenez, curdin.
Fixes #40027.

Merges [40376] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40427 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-14 08:53:11 +00:00
Pascal Birchler 0b17a58481 REST API: Allow fetching multiple users at once via the `slug` parameter.
This matches similar changes previously made for posts (#38579) and terms (#40027).

Props curdin, MatheusGimenez.
Fixes #40213.

Merges [40378] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40426 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-14 08:46:22 +00:00
Pascal Birchler 59e00d43a5 Media: Add filters to allow overriding slow media queries.
There are a couple of queries that do a full table scan of attachment posts to support features of the media library. Pending a more complete solution, allow overriding these queries via filters.

Props sboisvert, jnylen0.
See #31071.

Merges [40382] and [40421] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40425 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-14 08:39:46 +00:00
Pascal Birchler 41e53f4385 Customize: Verify availability of `history.replaceState` (in IE9) before attempting to populate `changeset_uuid` parameter.
Props westonruter, timmydcrawford for testing.
Amends [39686].
See #39227.
Fixes #40405.

Merges[40405] to the 4.7 branch.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40420 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-13 12:31:23 +00:00
Andrew Ozz 3f0f8d4a31 Update TinyMCE to 4.5.6. Has many improvements and bug fixes. Changelog: https://github.com/tinymce/tinymce/blob/4.5.x/changelog.txt.
Merges [40398] to the 4.7 branch.

Props programmin, eclev91 and boldwater for finding and reporting this.
Fixes #40305.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40419 602fd350-edb4-49c9-b593-d223f7449a82
2017-04-13 01:51:44 +00:00