Commit Graph

32923 Commits

Author SHA1 Message Date
Aaron Jorbin
a1aae78c7d Theme: Escape error messages
[36185] for 4.4 branch

Built from https://develop.svn.wordpress.org/branches/4.4@36186


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36153 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-06 17:24:27 +00:00
Dion Hulse
578b9a1ae4 Background Updates: Remove the 7am/7pm background update check.
This changeset is a more basic version of [36180], clearing the extra now redundant schedule.
As the functionality for this was introduced in 3.9, [28129] has been backported to 3.7/3.8, allowing the API TTL to be respected by those versions.

See #27772.
Fixes #35323.

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


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36151 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-06 13:24:33 +00:00
Aaron Jorbin
be1284566e Bump branches/4.4 to 4.4.1 Release Candidate 1
Built from https://develop.svn.wordpress.org/branches/4.4@36170


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36137 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-04 23:40:28 +00:00
Dion Hulse
49065bd5a4 Bump Akismet externals
git-svn-id: http://core.svn.wordpress.org/branches/4.4@36136 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-04 23:23:55 +00:00
Konstantin Obenland
d99c88fb66 Template: Always display the site title on the front page.
Limits using the page title to the blog page when the site has a static front page,
bringing it N’Sync with `wp_title()`.

Merges [36168] to the 4.4 branch.

Props peterwilsoncc.
Fixes #34962.


Built from https://develop.svn.wordpress.org/branches/4.4@36169


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36135 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-04 17:19:27 +00:00
Andrew Ozz
c9c10c4752 Media: when inserting an attachment in the editor and it is not an image, ensure the link is set to something else than none.
Props eherman24, azaozz.
Fixes #35153 for 4.4.1.
Built from https://develop.svn.wordpress.org/branches/4.4@36167


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36133 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-04 00:41:26 +00:00
Aaron Jorbin
001e5d3951 Add npm-shrinkwrap.json for 4.4
By shrinkwraping our dependencies, the same versions of everything will be installed no matter what rules the dependency package.json has specificed.

See #30787
props nacin, ocean90, netweb

Built from https://develop.svn.wordpress.org/branches/4.4@36165


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36131 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-03 22:37:26 +00:00
Andrew Nacin
fb82faaac6 XML-RPC: Revert [34681] as it broke date handling.
Merges [36163] to the 4.4 branch.

props dossy, hnle, redsweater.
see #35053, #30429 (original ticket).

Built from https://develop.svn.wordpress.org/branches/4.4@36164


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36130 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-03 19:50:22 +00:00
Gary Pendergast
410109ca49 Emoji: Add Emoji Diversity support, and fall back to twemoji if the browser doesn't support diverse emoji.
Merge of [36126] and [36160] to the 4.4 branch.

See #33592.


Built from https://develop.svn.wordpress.org/branches/4.4@36161


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36127 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-03 04:42:23 +00:00
Boone Gorges
15e9e6f6d9 Ensure that non-default pagination values work in wp_list_comments().
Prior to 4.4, it was possible to pass 'page' and 'per_page' values to
`wp_list_comments()` that do not match the corresponding global query vars.
This ability was lost in 4.4 with the refactor of how `comments_template()`
queries for comments; when the main comment query started fetching only the
comments that ought to appear on a page, instead of all of a post's comments,
it became impossible for the comment walker to select comments corresponding to
custom pagination parameters. See #8071.

We restore the previous behavior by (a) detecting when a 'page' or 'per_page'
parameter has been passed to `wp_list_comments()` that does not match the
corresponding query vars (so that the desired comments will not be found in
`$wp_query`), and if so, then (b) querying for all of the post's comments and
passing them to the comment walker for pagination, as was the case before 4.4.

Merges [36157] to the 4.4 branch.

Props boonebgorges, smerriman.
Fixes #35175.

Built from https://develop.svn.wordpress.org/branches/4.4@36158


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36124 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-03 02:07:23 +00:00
Dion Hulse
ced6b063a3 List Tables: When a user has hidden all columns, do not override that with the default_hidden_columns filter.
Merges [36154] to the 4.4 branch.
Props Compute, jorbin, voldemortensen.
Fixes #35057.

Built from https://develop.svn.wordpress.org/branches/4.4@36155


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36121 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-02 04:45:22 +00:00
Dion Hulse
dd821410c9 Admin: After [35128], make the 'Configure' link work again for dashboard widgets.
This merges the CSS changes from [35896] into an inline function in formatting.php to avoid a `wp-admin.min.css` rebuild.

Fixes #34987.

Built from https://develop.svn.wordpress.org/branches/4.4@36153


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36119 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-02 04:34:22 +00:00
Dion Hulse
2ef6daa428 Responsive images: fix the check whether the attachment meta matches the image src to work with http/https and CDNs.
Merges [36121] to the 4.4 branch.
Props webaware, joemcgill, azaozz.
Fixes #35045 and #35102.

Built from https://develop.svn.wordpress.org/branches/4.4@36152


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36118 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-02 03:56:22 +00:00
Dion Hulse
67c8061bb9 Responsive images: add compatibility for versions < 2.7 when the full image path was stored in the metadata. Introduces _wp_get_attachment_relative_path() and uses it in wp_get_attachment_url().
Merges [36120] to the 4.4 branch.
Props dd32, SergeyBiryukov.
Fixes #35106.

Built from https://develop.svn.wordpress.org/branches/4.4@36151


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36117 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-02 03:54:22 +00:00
Dion Hulse
b2da9c0fd4 Responsive Images: when creating srcset do not exclude the image size which is in the src attribute even when it is larger than max_srcset_image_width.
Merges [36110] to the 4.4 branch.
Props joemcgill.
Fixes #35108.

Built from https://develop.svn.wordpress.org/branches/4.4@36150


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36116 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-02 03:53:22 +00:00
Dion Hulse
fd22afea0c Bump the license.txt year to 2016 to appease the unit tests.
Merges [36141] to the 4.4 branch.

Built from https://develop.svn.wordpress.org/branches/4.4@36149


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36115 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-02 03:48:21 +00:00
Dion Hulse
24967882b6 Widgets: Revert [34465], as it introduced a regression, making the $index argument of dynamic_sidebar() case-sensitive.
Merges [36130] to the 4.4 branch.
See #23423.
Fixes #34995.

Built from https://develop.svn.wordpress.org/branches/4.4@36148


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36114 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-02 03:39:21 +00:00
Dion Hulse
50efb6e0e0 Embeds: Change attachment metadata condition to prevent a warning in the embeds template.
Merges [36123] to the 4.4 branch.
Fixes #35237.

Built from https://develop.svn.wordpress.org/branches/4.4@36147


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36113 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-02 03:36:21 +00:00
Dion Hulse
3ce481f130 Comments: Ensure only approved comments trigger post author notifications
Posts that are trashed shouldn't trigger post author notifications. Adds unit tests to enforce this.

Merges [36119] to the 4.4 branch.
Props scottbrownconsulting, peterwilsoncc, swissspidy.
Fixes #35006.

Built from https://develop.svn.wordpress.org/branches/4.4@36146


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36112 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-02 03:35:21 +00:00
Dion Hulse
ac6b8ae319 Admin: Restore the "Show advanced menu properties" checkboxes IDs.
These checkboxes are used on the Menus screen options and the Customizer Menus options.
Their IDs were removed in [34991] but they're needed to get the checkboxes to be saved
via AJAX. Also, avoids a useless AJAX call.

Merge [36137] to the 4.4 branch.
Props afercia.
Fixes #35112.

Built from https://develop.svn.wordpress.org/branches/4.4@36145


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36111 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-02 03:34:21 +00:00
Dion Hulse
a048514d43 Admin: fix repositioning of notices when the first header is not an immediate children of .wrap.
Merges [36134] to the 4.4 branch.
Props afercia, DvanKooten.
Fixes #35047.

Built from https://develop.svn.wordpress.org/branches/4.4@36144


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36110 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-01-02 03:32:23 +00:00
Dion Hulse
8232ed4640 XMLRPC: Revert [35509] which caused a change of behviour in at least one XMLRPC client.
XMLRPC has many quirks in it's operation, #16980 being just one of the many, #35185 just became yet another quirk.

Merges [36132] to the 4.4 branch.
See #16980.
Fixes #35185.

Built from https://develop.svn.wordpress.org/branches/4.4@36133


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36099 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-31 04:07:22 +00:00
Gary Pendergast
39875a50f3 Upgrade PHPMailer from 5.2.10 to 5.2.14.
The full list of changes is available here: https://github.com/PHPMailer/PHPMailer/compare/v5.2.10...v5.2.14

Merge of [36083] to the 4.4 branch.

Fixes #35212.


Built from https://develop.svn.wordpress.org/branches/4.4@36131


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36097 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-31 03:32:22 +00:00
Gary Pendergast
715dba65bc Redirects: Prevent redirects if a queried object exists.
After [34659], it became possible to cause an incorrect redirect, by changing the slug of a post, then creating a new post with the old slug. The correct behaviour is to prevent redirecting to the old post.

Props dd32, pento.

Merge of [36128] to the 4.4 branch.

Fixes #35031.


Built from https://develop.svn.wordpress.org/branches/4.4@36129


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36095 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-31 03:09:22 +00:00
Dion Hulse
63125cd75c Tests: After [36100] use an object style which is compatible with PHP5 get_object_vars().
Merges [36117] to the 4.4 branch.
See #35249.
Fixes #35058.

Built from https://develop.svn.wordpress.org/branches/4.4@36118


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36084 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-29 05:49:22 +00:00
Dion Hulse
3850e65fb5 Bump Akismet external.
git-svn-id: http://core.svn.wordpress.org/branches/4.4@36081 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-29 00:28:45 +00:00
Boone Gorges
b6cbc9f544 Force non-public taxonomies to have a query_var of false.
[35333] implemented `public=false` for taxonomies. The implementation prevented
non-public taxonomies from having their archives accessed via query_var during
a normal request. But it didn't prevent non-public taxonomies from registering
their query vars in the `$wp_taxonomies` global. The latter implementation
details causes problems specifically when a taxonomy is registered with
`query_var=true`; for public taxonomies, `register_taxonomy()` translates this
into a query_var equivalent to the taxonomy name, but in the case of non-public
taxonomies, the query_var was set to the boolean itself. The boolean then
causes problems when using non-strict comparison to filter taxonomy objects by
query_var, as when using `get_taxonomies()`.

This changeset addresses the issue by forcing the query_var property of
non-public taxonomies to `false`.

Merges [36108] to the 4.4 branch.

Fixes #35089.

Built from https://develop.svn.wordpress.org/branches/4.4@36109


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36074 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-27 16:43:22 +00:00
Dion Hulse
16b4ec9c1c Users: When determining whether to show the reassign content option during user delete, don't rely upon WP_Query as it doesn't return all forms of content wp_delete_user() operates on.
This restores the reassign form when a user has a non-public post type or links assigned to them.

Merges [36068] to the 4.4 branch.
Props swissspidy & tharsheblows for initial patches.
Fixes #34993.

Built from https://develop.svn.wordpress.org/branches/4.4@36106


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36071 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-27 02:17:21 +00:00
Dion Hulse
681646a7e9 Pages: get_page_uri() should return the URI at which the resource being accessed is available at, this may include non-'publish' status posts.
Reverts [34001] and fixes the original issue in #15963 - avoiding a PHP Notice for when the post doesn't exist.

Merges [36094] to the 4.4 branch.
Props tharsheblows.
See #15963.
Fixes #35084.

Built from https://develop.svn.wordpress.org/branches/4.4@36105


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36070 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-27 02:16:22 +00:00
Dion Hulse
b894426307 Help Tab Order should be based on the Priority Argument
[34370] made the order that tabs are returned respect the order they are added, however it broke the respect of priority. By using a ksort instead of a sort, we can restore that default behavior. This adjusts the unit tests so that both order added and priority are tested.

Merges [36089] to the 4.4 branch.
Props meitar, swissspidy, jorbin
Fixes #35215. See #33941.

Built from https://develop.svn.wordpress.org/branches/4.4@36104


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36069 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-27 02:14:22 +00:00
Dion Hulse
1879fa6413 Canonical: Output correct canonical links for paged posts when not using pretty permalinks.
Merges [36096] to the 4.4 branch.
Props peterwilsoncc.
Fixes #34890.

Built from https://develop.svn.wordpress.org/branches/4.4@36103


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36068 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-27 02:12:23 +00:00
Dion Hulse
4680a9a281 Allow map_deep() to work with object properties containing a reference. Restores the previous behaviour of stripslashes_deep().
Merges [36100] to the 4.4 branch.
Props jeff@pyebrook.com, swissspidy.
See #22300, [35252].
Fixes #35058.

Built from https://develop.svn.wordpress.org/branches/4.4@36101


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36066 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-26 05:24:22 +00:00
Dion Hulse
dbb12be45a Shortcodes: = is a reserved character in shortcode names, mark it as such.
This allows for shortcodes such as `[shortcode=attribute]` to work, which while never intentionally supported were widely used in the pre-shortcode days.

Merges [36097] to the 4.4 branch, minus a string change.
Props aaroncampbell.
Fixes #34939.

Built from https://develop.svn.wordpress.org/branches/4.4@36098


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36063 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-26 04:48:23 +00:00
Konstantin Obenland
9539dda214 Menus: Bring back line break between menu items.
While removing line breaks was great for all use cases except justified menu
items, it broke menus with justified menu items.
Reverts [34321].

Merges [36081] to the 4.4 branch.
Props wp-architect.
Fixes #35107.

Built from https://develop.svn.wordpress.org/branches/4.4@36082


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36047 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-24 00:26:22 +00:00
Dion Hulse
35c2b1dee2 Widgets: Remove extra quotes from widget title in WP_Widget_RSS, accidentally added in [33814].
Merges [35978] to the 4.4 branch.
Props ShinichiN.
Fixes #34978.

Built from https://develop.svn.wordpress.org/branches/4.4@36067


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36032 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-23 02:00:23 +00:00
Dion Hulse
3941a5ffa7 Remove RDIO from oEmbed providers
RDIO is shutting down. https://www.rdio.com/farewell/

Merges[36007] to the 4.4 branch.
Props swissspidy.
Fixes #35152.

Built from https://develop.svn.wordpress.org/branches/4.4@36066


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36031 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-23 01:53:21 +00:00
Dion Hulse
378e246adf Customize: Ensure that "Change" button appears when there are only 2 themes.
Fixes defect introduced in [35535].

Merges [35943] to the 4.4 branch.
Props igmoweb.
See #34549.
Fixes #35081.

Built from https://develop.svn.wordpress.org/branches/4.4@36065


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36030 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-23 01:51:22 +00:00
Dion Hulse
b4f299c6f9 In WP::handle_404(), make sure $wp_query->post is a WP_Post object before cloning it.
Merges [35994] to the 4.4 branch.
Props igmoweb, swissspidy.
Fixes #35013.

Built from https://develop.svn.wordpress.org/branches/4.4@36064


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36029 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-23 01:42:25 +00:00
Dion Hulse
70d9869e38 I18N: In wp_maybe_decline_date(), bail early if translation functions are not available, e.g. in SHORTINIT mode.
Merges [35880] to the 4.4 branch.
Props SergeyBiryukov.
Fixes #34967.

Built from https://develop.svn.wordpress.org/branches/4.4@36063


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36028 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-23 01:39:28 +00:00
Gary Pendergast
9f78d3f9c3 Embeds: Don't show embed discovery link on a static front page.
There's currently no iframe content being generated for a static front page. Giving out a link to that isn't an ideal user experience.

Props peterwilsoncc.

Merge of [36059] to the 4.4 branch.

Fixes #35194.


Built from https://develop.svn.wordpress.org/branches/4.4@36060


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36025 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-22 10:55:26 +00:00
Dion Hulse
60965cc4a5 Update random_compat to latest
Changes:
 * Checks `disable_classes` for `COM()` before using to avoid PHP Warnings
 * Uses `stream_set_chunk_size()` to avoid reading 8KiB from `/dev/urandom` unintentionally.

Merges [35922] to the 4.4 branch.

Fixes #34948.

Built from https://develop.svn.wordpress.org/branches/4.4@36058


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36023 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-22 03:23:24 +00:00
Boone Gorges
3a748c573f Order terms by 'name' when populating object term cache.
[34217] removed the `ORDER BY` clause from `update_object_term_cache()`, for
improved performance. But this proved to cause problems in cases where users
were expecting the results of `get_the_terms()` to be ordered by 'name'. Let's
revert the change for the time being, and look into more disciplined ordering
in a future release.

Merges [36056] to the 4.4 branch.

Props afercia.
See #28922. Fixes #35180.

Built from https://develop.svn.wordpress.org/branches/4.4@36057


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36022 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-22 01:53:22 +00:00
John Blackbourn
635d9160af Tests: Correct the public query vars test for the 4.4 branch.
See #35115

Built from https://develop.svn.wordpress.org/branches/4.4@36052


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36017 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-21 08:36:22 +00:00
John Blackbourn
9bfdf6ebd2 Query: Re-initialise any dynamically-added public query vars before running the public query vars test.
Merges [36048] to the 4.4 branch.

Fixes #35115

Built from https://develop.svn.wordpress.org/branches/4.4@36051


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36016 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-21 07:57:24 +00:00
John Blackbourn
8cce3f2f75 Query: Introduce a unit test which will fail when new public query vars are introduced without also updating the test. This adds an extra layer of explicitness to introducing public query vars in order to avoid introducing unintentional clashes with URL query vars that are already in use.
Merges [36045] to the 4.4 branch.

Fixes #35115

Built from https://develop.svn.wordpress.org/branches/4.4@36046


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36011 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-21 05:50:22 +00:00
John Blackbourn
b7fdda8edb Avoid a PHP notice when trying to access the post_parent property of hierarchical post type nav menu items.
Merges [35876] to the 4.4 branch.

Fixes #34446

Built from https://develop.svn.wordpress.org/branches/4.4@36044


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36009 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-21 03:53:25 +00:00
John Blackbourn
ce18aadc7b Login: Revert [34213] and [35897]. It has become apparent that there is a need for a separate function (and corresponding filter) which allows for the login form action URL to differ from the URL used to access the login form, so that plugins or implementations which change the login URL do not need to worry about handling the form submission at the same URL.
For now, we'll revert to the pre-4.4 behaviour of hard-coding the login form action URL as `wp-login.php` and look at implementing a separate function and corresponding filter in 4.5.

Merges [36042] to the 4.4 branch.

Props KrissieV, salcode, JPry
Fixes #34925
Fixes #35103

Built from https://develop.svn.wordpress.org/branches/4.4@36043


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36008 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-21 03:30:27 +00:00
Boone Gorges
d524151147 Respect approval status when determining comment page count in comments_template().
Since 4.4, when fetching the first page of comments and the 'newest' comments
are set to display first, `comments_template()` must perform arithmetic to
determine which comments to show. See #8071. This arithmetic requires the
total comment count for the current post, which is calculated with a separate
`WP_Comment_Query`. This secondary comment query did not properly account for
non-approved comment statuses; all unapproved comments should be part of the
comment count for admins, and individual users should have their own
unapproved comments included in the count. As a result, `comments_template()`
was, in some cases, being fooled into thinking that a post had fewer comments
available for pagination than it actually had, which resulted in empty pages
of comments.

We correct this problem by mirroring 'status' and 'include_unapproved' params
of the main comment query within the secondary query used to calculate pagination.

Merges [36040] to the 4.4 branch.

Fixes #35068.

Built from https://develop.svn.wordpress.org/branches/4.4@36041


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36006 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-21 03:11:21 +00:00
John Blackbourn
472e427731 Comments: When a comment is submitted, ensure the user_ID element in the array that's passed to the preprocess_comment filter gets populated.
Merges [36038] to the 4.4 branch.

Fixes #34997

Built from https://develop.svn.wordpress.org/branches/4.4@36039


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36004 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-21 02:58:23 +00:00
Gary Pendergast
b702c2f95b Texturize: Transform & into &#038; in tag attributes.
[35709] was overly broad, and stopped transforming `&` characters within tag attributes. So that sites aren't generating invalid HTML, we need to restore this functionality, while continuing to not transform `&` within blocked tags.

Merge of [36036] to the 4.4 branch.

Fixes #35008.


Built from https://develop.svn.wordpress.org/branches/4.4@36037


git-svn-id: http://core.svn.wordpress.org/branches/4.4@36002 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-21 02:46:22 +00:00