Commit Graph

5726 Commits

Author SHA1 Message Date
Dominik Schilling
f3a62b7714 Theme Editor: Change file descriptions of header.php and footer.php.
`header.php` is now "Theme Header" and `footer.php` is "Theme Footer". This prevents a clash with other "Header" strings in the context of "Custom Header".

Props ramiy.
Fixes #32975.
Built from https://develop.svn.wordpress.org/trunk@34290


git-svn-id: http://core.svn.wordpress.org/trunk@34254 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-18 16:03:24 +00:00
Sergey Biryukov
b92955b427 Network Admin: Include IDs for users and sites on their respective views.
Props danielbachhuber, wonderboymusic.
Fixes #18661.
Built from https://develop.svn.wordpress.org/trunk@34289


git-svn-id: http://core.svn.wordpress.org/trunk@34253 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-18 15:58:25 +00:00
Dion Hulse
6113e498fc Updates: FTP: Add a missing PCRE modifer in [34281].
See #16026, #33432x

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


git-svn-id: http://core.svn.wordpress.org/trunk@34246 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-18 08:23:25 +00:00
Dion Hulse
5abc1eaab9 Updates: FTP/PemFTP Library: Remove the usage of deprecated regular expression functions (ereg replaced by PCRE).
Props enshrined, aaroncampbell
Fixes #16026, #33432

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


git-svn-id: http://core.svn.wordpress.org/trunk@34245 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-18 08:20:27 +00:00
Scott Taylor
48d402a395 Posts List Table: Use a more robust technique for calculating $total_items so that pagination still appears when items are removed on the last page of results and ->max_num_pages decreases.
Props A5hleyRich.
Fixes #29870.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34235 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-17 21:18:24 +00:00
Helen Hou-Sandí
48befcf361 Superglobals: Revert [34059] until further notice.
see #33837.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34229 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-17 12:33:26 +00:00
Sergey Biryukov
514eb11cf4 Revert unintended change from [34262].
See #33910.
Built from https://develop.svn.wordpress.org/trunk@34263


git-svn-id: http://core.svn.wordpress.org/trunk@34227 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-17 09:09:28 +00:00
Sergey Biryukov
d91fe61405 Docs: Expand the DocBlock for get_default_post_to_edit().
Props rabmalin.
Fixes #33910.
Built from https://develop.svn.wordpress.org/trunk@34262


git-svn-id: http://core.svn.wordpress.org/trunk@34226 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-17 09:06:34 +00:00
Scott Taylor
f3dd19c6e2 Media: In wp_ajax_send_attachment_to_editor(), the fallback logic for $html should be tucked into an else statement so it isn't run needlessly and overwritten.
Props tychay.
Fixes #32072.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34224 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-17 05:55:25 +00:00
Scott Taylor
63efd92b11 Media: In get_image_send_to_editor(), allow a custom value for $rel.
Props tychay.
Fixes #32074.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34223 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-17 05:46:24 +00:00
Scott Taylor
58ac764859 Media List Table: remove the counts from the "views" portion of the toolbar, which are inconsistent with grid view. Also reduces complexity and removes potentially expensive count query.
Related to the toolbar view, remove the `wp_admin_canonical_url()` action in grid mode. Grid views that result from links from the list table view are lenses into the library and need to be indicated as such vs being a full attachment query.

Fixes #29744.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34220 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-17 02:30:26 +00:00
Boone Gorges
85c00bd943 Move new user notification emails to add_action() callbacks.
When a new user is created in various places throughout the interface,
notifications are sent to the site admin and the new user. Previously, these
notifications were fired through direct calls to `wp_new_user_notification()`,
making it difficult to stop or modify the messages.

This changeset introduces a number of new action hooks in place of direct calls
to `wp_new_user_notification()`, and hooks the new wrapper function
`wp_send_new_user_notifications()` to these hooks.

Props dshanske, thomaswm, boonebgorges.
Fixes #33587.
Built from https://develop.svn.wordpress.org/trunk@34251


git-svn-id: http://core.svn.wordpress.org/trunk@34215 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-16 22:19:24 +00:00
Scott Taylor
1e3807c10d wp-admin/includes/template.php is now a loader for 3 files made via svn cp:
* `Walker_Category_Checklist` class
* `WP_Internal_Pointers` class
* `template-functions.php`

This is BC for plugins that are loading `wp-admin/includes/template.php` for fun.

See #33413.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34205 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-16 15:35:23 +00:00
Sergey Biryukov
d06f5817f8 Docs: Expand the DocBlock for the WP_Theme::get_edit_link() method, introduced in [34084].
Fixes #32376.
Built from https://develop.svn.wordpress.org/trunk@34238


git-svn-id: http://core.svn.wordpress.org/trunk@34202 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-16 15:01:27 +00:00
Drew Jaynes
13c25f5f49 Docs: Put "it's" in its place (again).
Props kitchin.
Fixes #33894.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34198 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-16 12:46:28 +00:00
Sergey Biryukov
4c019c6aee Comments: Fix a fatal error in Comments meta box after [34223].
Props tyxla.
Fixes #33893. See #33413.
Built from https://develop.svn.wordpress.org/trunk@34231


git-svn-id: http://core.svn.wordpress.org/trunk@34195 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-16 11:37:25 +00:00
Drew Jaynes
3c73b53f66 Docs: Remove markdown from the DocBlock summary for WP_List_Table::get_primary_column(), introduced in [34166].
The PHP inline documentation standards for [https://make.wordpress.org/core/handbook/best-practices/inline-documentation-standards/php/#summary-formerly-short-description summaries] call for not using an markup or markdown. Also, using the full Class::method() in this context allows for better clarity in what is being referenced.

See #33854. See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34193 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-16 10:51:25 +00:00
Scott Taylor
5920e8eb13 Move WP_Post_Comments_List_Table to its own file.
See #33413.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34187 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-16 06:53:24 +00:00
John Blackbourn
a9e5cfddc7 Implement wp_login_url() and wp_registration_url() in places where wp-login.php is currently hard-coded.
See #31495
Props GregLone

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


git-svn-id: http://core.svn.wordpress.org/trunk@34177 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 17:11:35 +00:00
Scott Taylor
ff3ae0e747 Don't redirect to the Term list table after submitting the form on the Edit Term page.
Props chiragswadia, UmeshSingla, rhyswynne, afercia.
Fixes #17455.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34166 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 15:59:42 +00:00
John Blackbourn
a5a8ae45a6 Remove outdated references to the preview_post_link filter docs.
See #24345
Props paulwilde

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


git-svn-id: http://core.svn.wordpress.org/trunk@34146 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 10:32:31 +00:00
Scott Taylor
ab6d1fa247 Use get_attached_file() in attachment_submitbox_metadata().
Props kitchin.
Fixes #33386.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34139 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 04:18:25 +00:00
Scott Taylor
54829b6305 Create a function, get_preview_post_link(), to DRY the logic for applying the 'preview_post_link' filter to a URL.
Props TomHarrigan, wonderboymusic.
Fixes #24345.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34138 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 04:15:25 +00:00
Scott Taylor
ee42803e21 Move WP_Screen to its own file.
See #33413.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34137 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 04:08:24 +00:00
Scott Taylor
fde014e85e Move the admin Nav Menu Walker subclasses into their own files. Load in nav-menu.php to remain BC.
See #33413.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34136 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 04:02:25 +00:00
Scott Taylor
780487556b Add a doc block to WP_List_Table::get_primary_column().
Fixes #33854.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34134 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 03:35:25 +00:00
Scott Taylor
191400f9e6 Don't ever use the guid value when retrieving URLs for media, use wp_get_attachment_url(). Use get_attached_file() for path to file.
Fixes #33386.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34131 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 02:50:25 +00:00
Scott Taylor
69e3a390b2 In _wp_ajax_delete_comment_response(), read the new 'all' prop returned by get_comment_count() via wp_count_comments() when setting $total. 'all' doesn't include spam in its count.
Updates unit tests.

Props dipesh.kakadiya.
Fixes #32362.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34129 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 01:47:25 +00:00
Nikolay Bachiyski
097c4fd2f4 List tables: escape user e-mails
Better safe than sorry.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34101 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-14 22:33:25 +00:00
Scott Taylor
7639a89a1f wp_unspam_comment() can accept a full object instead of comment_ID to reduce cache/db lookups..
See #33638.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34098 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-14 21:47:25 +00:00
Scott Taylor
b1bc8a6522 More comment functions can accept a full object instead of comment_ID to reduce cache/db lookups.
See ##33638.


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


git-svn-id: http://core.svn.wordpress.org/trunk@34097 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-14 21:40:24 +00:00
Scott Taylor
b2a30103ae In WP_List_Table, make a new public method, ->get_primary_column(), and revert [34101] due to BC issues.
Fixes #33854.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34096 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-14 20:29:26 +00:00
Scott Taylor
4d33644373 In WP_Media_List_Table, fetch all pending comment counts at once, instead of for each row in the loop.
See #11381.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34095 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-14 19:25:25 +00:00
Dominik Schilling
4af3a3374e Passwords: Deprecate second parameter of wp_new_user_notification().
The second parameter `$plaintext_pass` was removed in [33023] and restored as `$notify` in [33620] with a different behavior. If you have a plugin overriding `wp_new_user_notification()` which hasn't been updated you would get a notification with your username and the password "both".
To prevent this the second parameter is now deprecated and reintroduced as the third parameter.

Adds unit tests.

Props kraftbj, adamsilverstein, welcher, ocean90.
Fixes #33654.

(Don't ask for new pluggables kthxbye)
Built from https://develop.svn.wordpress.org/trunk@34116


git-svn-id: http://core.svn.wordpress.org/trunk@34084 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-14 12:43:26 +00:00
Scott Taylor
ecc4106ed1 Add an argument to parent_dropdown(), $post, to allow it to be called for an arbitrary post.
Fixes #23162.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34079 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-14 03:20:25 +00:00
Scott Taylor
ae6a3aee7f Make WP_List_Table::get_primary_column_name() public in list table classes that have it.
Fixes #33854.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34069 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-14 01:12:25 +00:00
Helen Hou-Sandí
7f772bdaff Comments: Fix inline edit/reply on small screens.
props ocean90, SergeyBiryukov.
fixes #33596.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34062 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-13 12:47:27 +00:00
Weston Ruter
bd801ae5db Customize: Remove redundant aria-label attributes.
Adds an `$options` array argument to `WP_Screen::render_screen_options()` to allow the `div#screen-options-wrap` element to be omitted when `wrap` value is `false`.

Props afercia, westonruter.
Fixes #33182.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34061 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-13 06:16:26 +00:00
Scott Taylor
8591f94b0a WP_Posts_List_Table: there are a cadre of edit.php URLs that are generated by string-building instead of using our handy functions. Create a helper method, ->get_edit_link() that standardizes the generation and escaping of these URLs.
Props BdN3504 for the initial patch on the ticket.
Fixes #32376.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34052 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-12 17:13:25 +00:00
Scott Taylor
281faeb69d After [34076], fix the logic for post_status in months dropdown.
See #21015.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34045 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-12 08:19:24 +00:00
Scott Taylor
eb230b5424 List Tables: don't render "extra tablenav" if there are no posts. This includes Bulk Actions, Dates Dropdown, Category Dropdowns, Pagination.
Also ensure that the Months dropdown, when it is shown, shows months from the proper set of posts.

Props egower, CoenJacobs, MikeHansenMe, mehulkaklotar.
Fixes #33824, #21015, #21856.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34044 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-12 08:13:24 +00:00
Scott Taylor
ed83979728 AJAX Reply to Comment: check the edit_comment cap when parent comment will be auto-approved.
Props rachelbaker.
Fixes #23939.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34042 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-12 07:19:25 +00:00
Scott Taylor
821939d6d1 Quick Edit: fix an ID attribute name collision by renaming one of the author fields author-name.
Props afercia.
Fixes #33770.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34038 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-12 02:35:25 +00:00
Scott Taylor
b453af5718 When clicking "Show More Comments" in the Comments meta box on the Edit Post screen, change the click behavior to call a new class method on commentsBox, ->load(), that resets st (cool name) to the number of visible <tr>s before calling ->get(). This will account for spam'd and trash'd comments when returning comments at the proper offset.
Props utkarshpatel.
Fixes #33829.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34037 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-12 02:28:26 +00:00
Scott Taylor
cd7c0f0b0d Introduce wp_validate_action( $action = '' ), a helper function that checks $_REQUEST for action and returns it, or empty string if not present. If $action is passed, it checks to make sure they match before returning it, or an empty string. Strings are always returned to avoid returning multiple types.
Implementing this removes 27 uses of direct superglobal access in the admin.

For more reading:
https://codeclimate.com/github/WordPress/WordPress/wp-admin/edit-comments.php

See #33837.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34027 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-11 21:08:26 +00:00
Scott Taylor
58c3c30e8d After [33961], pass $comment to comment_class() where possible to avoid extra cache/db lookups.
See #33638.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34008 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-11 06:12:24 +00:00
Scott Taylor
4465a83b95 After [34015], handle orphaned comments in the Dashboard comments widget. Pass full $comment versus just passing the comment ID when possible.
See #33710.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34006 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-11 05:56:24 +00:00
Scott Taylor
b9bbdabfe7 Create a new file, wp-admin/includes/noop.php, which loads all of the noop functions for load-script|styles.php and is only loaded by those files. DRYs in the process.
See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34005 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-11 05:04:23 +00:00
Scott Taylor
db9c5c81f5 Move ad hoc functions from wp-admin/credits.php to wp-admin/includes/credits.php, which is only included by the former.
See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@34004 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-11 04:55:26 +00:00
Boone Gorges
39fb7992a9 Require numeric IDs in user deletion functions.
`wp_delete_user()` and `wpmu_delete_user()` both require an `$id` parameter.
Previously, the functions did not verify that the value passed was, in fact,
a number. As such, passing an object or any other entity that would be cast
to int `1` would result in user 1 being deleted. We fix this by enforcing
the requirement that `$id` be numeric.

Props dipesh.kakadiya, utkarshpatel, juliobox.
Fixes #33800.
Built from https://develop.svn.wordpress.org/trunk@34034


git-svn-id: http://core.svn.wordpress.org/trunk@34002 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-11 02:25:23 +00:00
Gary Pendergast
0d85038ce6 Schema: Increase the length of wp_options.option_name.
It's pretty easy to run over the `option_name` length, which causes undefined behaviour when inserting and retrieving options. Increasing the length from `VARCHAR(64)` to `VARCHAR(191)` significantly reduces the risk of this occurring.

Because `option_name` has a `UNIQUE` index, we can only increase it to 191 characters, rather than 255. The index can only use a prefix of 191 characters, so will incorrectly restrict long different strings that have the same prefix, if we make the column longer.

Props scribu, OriginalEXE, khromov, MikeHansenMe, netweb, pento.

Fixes #13310.


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


git-svn-id: http://core.svn.wordpress.org/trunk@33999 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-11 01:26:24 +00:00
Scott Taylor
5918b30cdd Move network_settings_add_js() from wp-admin/network/settings.php to wp-admin/includes/ms.php.
See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33995 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 22:24:24 +00:00
Scott Taylor
2d2e3c911e Move confirm_delete_users() from wp-admin/network/users.php to wp-admin/includes/ms.php.
See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33994 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 22:23:46 +00:00
Scott Taylor
bd0a6bbf8c Create wp-admin/includes/network.php via svn cp and only load it in wp-admin/network.php. Move the functions there.
See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33992 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 22:01:24 +00:00
Scott Taylor
1d68ccec25 Move ad hoc Options functions to wp-admin/includes/options.php:
* Move `options_discussion_add_js()` from `wp-admin/options-discussion.php`
* Move `options_general_add_js()` from `wp-admin/options-general.php`
* Move `options_permalink_add_js()` from `wp-admin/options-permalink.php`
* Move `options_reading_add_js()` from `wp-admin/options-reading.php`
* Move `options_reading_blog_charset()` from `wp-admin/options-reading.php`

See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33991 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 21:45:24 +00:00
Scott Taylor
a40e30e7f4 Move 2 ad hoc user admin functions:
* Move `use_ssl_preference()` from `wp-admin/user-edit.php` to `wp-admin/includes/user.php`.
* Move `admin_created_user_email()` from `wp-admin/user-new.php` to `wp-admin/includes/user.php`.

See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33990 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 21:33:33 +00:00
Scott Taylor
503aa8b76d Move redirect_post() from wp-admin/post.php to wp-admin/includes/post.php.
See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33989 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 21:31:24 +00:00
Scott Taylor
f0b95b7bcc Move comment_footer_die() from wp-admin/comment.php to wp-admin/includes/comment.php.
See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33988 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 21:29:24 +00:00
Scott Taylor
a1d949f361 Move plugin_sandbox_scrape() from wp-admin/plugins.php to wp-admin/includes/plugin.php.
See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33987 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 21:24:24 +00:00
Scott Taylor
f8d7a43920 Move wp_widgets_access_body_class() (a hook callback) from wp-admin/widgets.php to wp-admin/includes/widgets.php.
See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33986 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 21:22:23 +00:00
Scott Taylor
98acab10ea Comments/PHP Notices: check that a parent comment exists before displaying an orphan's link to it in the admin.
Props rachelbaker.
Fixes #33710.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33984 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 20:51:23 +00:00
Scott Taylor
8cd584e6ed In wp_generate_attachment_metadata(), also pass $metadata to the intermediate_image_sizes_advanced filter.
Props amereservant, wonderboymusic.
Fixes #23401.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33976 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 18:04:24 +00:00
Scott Taylor
6e22d94488 Add a "View" row action for approved comments on the Dashboard screen, remove the link labeled #.
Props rachelbaker, zeo.
Fixes #18885. 

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


git-svn-id: http://core.svn.wordpress.org/trunk@33975 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 17:49:24 +00:00
Scott Taylor
527b5b1405 In WP_Posts_List_Table::column_date(), the order of status and time should be switched. It doesn't make sense for phrases like "Last Modified" to occur AFTER the date. Should be before.
Props johnbillion, wonderboymusic.
Fixes #18641. 

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


git-svn-id: http://core.svn.wordpress.org/trunk@33974 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 17:43:24 +00:00
Scott Taylor
52498a8546 In wp_media_upload_handler(), replace a lingering instance of media_upload_gallery() with wp_iframe(...)
Props jeffstieler, antpb.
Fixes #17812. 

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


git-svn-id: http://core.svn.wordpress.org/trunk@33972 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 17:24:23 +00:00
Scott Taylor
49b8ccec79 When deleting via User List Table, don't prompt for re-attribution if the user(s) do(es) not have any posts.
Props rajnikmit, wojtek.szkutnik, benjmay, wonderboymusic.
Fixes #6405. 

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


git-svn-id: http://core.svn.wordpress.org/trunk@33969 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 16:47:24 +00:00
Sergey Biryukov
f9e7fb306c Merge two similar strings.
Props dipesh.kakadiya.
Fixes #33777.
Built from https://develop.svn.wordpress.org/trunk@33998


git-svn-id: http://core.svn.wordpress.org/trunk@33967 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 10:59:27 +00:00
Scott Taylor
52516a68ab After the global churn in [33964], also set $post to null at the end of WP_Comments_List_Table::single_row() to ensure that an orphaned comment doesn't inherit the previous row's $post context.
See #33638.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33955 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 03:12:23 +00:00
Scott Taylor
2c21d12232 Implement a priority system for Help Tabs to add them at specific positions.
Adds unit tests.

Props swissspidy.
Fixes #19828.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33954 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 01:27:23 +00:00
Scott Taylor
b8c37073d8 Add @access docs to class-wp-filesystem-* files.
Props wenthemes.
Fixes #33725.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33953 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 01:21:24 +00:00
Drew Jaynes
55f3b892fb Docs: Add a changelog entry to the DocBlock for touch_time() to mention the shift from accessing the global $comment to using get_comment().
See #33638.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33948 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-09 15:48:25 +00:00
Scott Taylor
02ae926dfd Round 2 of: We should use ellipses &hellip; / … instead of three dots/periods ... e.g Loading… not Loading...
Props yoavf.
Fixes #32875.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33939 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-09 04:39:25 +00:00
Scott Taylor
246f2a6bd9 Use get_comment() instead of a global in touch_time().
See #33638.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33934 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-09 03:05:24 +00:00
Scott Taylor
71f955dc84 In WP_Comments_List_Table, favor passing WP_Comment instances instead of $comment_ID to template functions. This allows us to bypass unnecessary cache lookups and simply pass the object through when it is set.
See #33638.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33933 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-09 03:00:24 +00:00
Scott Taylor
d973339738 After [33891], get_comment() returns global $comment if no args are passed and the global is set (after setting the default to null here). This allows us to ditch global comment imports.
See #33638.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33932 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-09 02:51:24 +00:00
Scott Taylor
8879565c0a In WP_User, add @property docs for description, first_name, and last_name. user_firstname and user_lastname only exist for back-compat.
See #33491.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33927 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-09 01:13:24 +00:00
Sergey Biryukov
a3f82f92f1 Widgets: Don't display sidebar description container if it's empty.
Props paulwilde.
Fixes #32448.
Built from https://develop.svn.wordpress.org/trunk@33934


git-svn-id: http://core.svn.wordpress.org/trunk@33903 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-06 07:59:24 +00:00
Sergey Biryukov
c177344508 Merge two permission error strings.
Props pavelevap.
Fixes #33745.
Built from https://develop.svn.wordpress.org/trunk@33933


git-svn-id: http://core.svn.wordpress.org/trunk@33902 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-06 06:42:26 +00:00
Sergey Biryukov
c65f37f892 Correct description for version and current_version parameters in wp_check_browser_version() response.
Props extendwings.
Fixes #33753.
Built from https://develop.svn.wordpress.org/trunk@33932


git-svn-id: http://core.svn.wordpress.org/trunk@33901 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-06 00:17:24 +00:00
Sergey Biryukov
4b5ef333a0 Correct the docblock for wp_list_widget_controls().
Props swissspidy.
Fixes #33751.
Built from https://develop.svn.wordpress.org/trunk@33930


git-svn-id: http://core.svn.wordpress.org/trunk@33899 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-05 23:38:25 +00:00
Sergey Biryukov
465e348c12 Fix closing div in wp_print_request_filesystem_credentials_modal().
Props trepmal.
Fixes #33737.
Built from https://develop.svn.wordpress.org/trunk@33908


git-svn-id: http://core.svn.wordpress.org/trunk@33877 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-05 15:17:24 +00:00
Boone Gorges
cc5eddda74 Allow wp_terms_checklist() to return markup rather than echoing it.
Props kevinlangleyjr.
Fixes #33720.
Built from https://develop.svn.wordpress.org/trunk@33904


git-svn-id: http://core.svn.wordpress.org/trunk@33873 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-04 21:25:25 +00:00
Scott Taylor
80a20e5c3d Handle more cases (untrailingslashit, HTTPS urls) for sanitizing an author URL for display in the comments list table.
Props afercia, mehulkaklotar, swissspidy, johnbillion.
Fixes #33291.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33863 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-03 23:23:24 +00:00
Scott Taylor
e73ee5ac98 Introduce WP_Comment class to model/strongly-type rows from the comments database table. Inclusion of this class is a pre-req for some more general comment cleanup and sanity.
* Takes inspiration from `WP_Post` and adds sanity to comment caching. 
* Clarifies when the current global value for `$comment` is returned. The current implementation in `get_comment()` introduces side effects and an occasion stale global value for `$comment` when comment caches are cleaned.
* Strongly-types `@param` docs
* This class is marked `final` for now

Props wonderboymusic, nacin.

See #32619.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33860 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-03 18:17:24 +00:00
Sergey Biryukov
771b29455b Provide more helpful feedback than just "Cheatin' uh?" for permission errors in wp-admin/includes/bookmark.php.
props ericlewis, kraftbj, lukecarbis, mrmist.
fixes #33682. see #14530.
Built from https://develop.svn.wordpress.org/trunk@33887


git-svn-id: http://core.svn.wordpress.org/trunk@33856 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-03 08:59:24 +00:00
John Blackbourn
606b6d15f1 Introduce wp_removable_query_args(), which returns an array of single-use query variables which can be removed from a URL.
Also applies the function to the return URL when the Customizer is closed.

Fixes #32692
Props swissspidy, Mte90

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


git-svn-id: http://core.svn.wordpress.org/trunk@33817 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-02 11:29:23 +00:00
Jeremy Felt
9666aec8d1 Multisite: Remove duplicate span element output from row actions
Fixes #32961.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33816 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-01 21:51:21 +00:00
Sergey Biryukov
43194cea1c Add 'dashboard_secondary_items' filter for the number of secondary link items in the 'WordPress News' dashboard widget.
props MikeHansenMe, DrewAPicture.
fixes #31434.
Built from https://develop.svn.wordpress.org/trunk@33833


git-svn-id: http://core.svn.wordpress.org/trunk@33801 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-31 21:57:21 +00:00
Sergey Biryukov
a53d6b471f Add 'update_right_now_text' filter for the text displayed in the 'At a Glance' dashboard widget.
props obenland.
fixes #33355.
Built from https://develop.svn.wordpress.org/trunk@33832


git-svn-id: http://core.svn.wordpress.org/trunk@33800 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-31 21:45:21 +00:00
Drew Jaynes
375d30f699 Docs: Add a duplicate filter comment to the comment_email filter call in WP_Comments_List_Table, introduced in [33829].
See #11566.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33798 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-31 21:22:21 +00:00
Scott Taylor
a5b157ffde Remove the hamburger global'ing from [33828]: since no args are passed to comment_author_email_link(), the internals can be simplified and applied inline.
See #11566. 

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


git-svn-id: http://core.svn.wordpress.org/trunk@33797 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-31 21:09:21 +00:00
Scott Taylor
d0a1a47708 Fix warnings after [33826]. Only only one function call needs a global $comment, we shall hamburger it.
See #11566. 

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


git-svn-id: http://core.svn.wordpress.org/trunk@33796 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-31 20:59:21 +00:00
Scott Taylor
7ab015c5ab WP_Comments_List_Table::single_row() has no reason to set the $comment global. No other methods use it, and we are not in template/loop context. This can mess with the response of get_comment() elsewhere, since get_comment() internally bypasses the cache/db when a global is set.
See #11566. 

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


git-svn-id: http://core.svn.wordpress.org/trunk@33794 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-31 20:42:21 +00:00
Sergey Biryukov
8b1fe986c3 Use wp_html_excerpt() to properly cut comment author URL for display on Comments screen.
props brettz95, solarissmoke.
fixes #15659.
Built from https://develop.svn.wordpress.org/trunk@33825


git-svn-id: http://core.svn.wordpress.org/trunk@33793 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-31 20:41:21 +00:00
Sergey Biryukov
5a97ff5206 Bump H3 headings to H2 on Themes screen for better accessibility.
props joehills.
fixes #33560.
Built from https://develop.svn.wordpress.org/trunk@33820


git-svn-id: http://core.svn.wordpress.org/trunk@33788 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-31 03:51:21 +00:00
Scott Taylor
db11b48627 Favor using the consistent and agnostic string 'Attach' over 'Attach to a post' in the media list table.
Props pavelevap.
Fixes #33515.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33778 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-30 03:10:21 +00:00
John Blackbourn
6ee45a9606 Bring network admin user searching to parity with single site user searching by wrapping search terms in asterisks. This means that searches don't require an exact match and therefore significantly reduces friction when searching for users on the network admin screens.
Fixes #32913

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


git-svn-id: http://core.svn.wordpress.org/trunk@33769 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-29 00:19:24 +00:00
Sergey Biryukov
d10fc64ab5 Network Admin: Hide the bulk actions checkbox for super admins.
See [25125] for hiding the checkbox for the main site in Sites table.

props bordoni.
fixes #28529.
Built from https://develop.svn.wordpress.org/trunk@33777


git-svn-id: http://core.svn.wordpress.org/trunk@33745 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-28 03:49:21 +00:00
Helen Hou-Sandí
1f500055a6 Drop the hyphen from e-mail and standardize on email.
The AP Stylebook changed this in 2011, and we're woefully inconsistent, so let's go with the standard.

props morganestes, voldemortensen, niallkennedy (for patching on the previous AP style).
fixes #26156.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33742 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-28 03:17:21 +00:00
John Blackbourn
6d7aeeac03 Don't change the View Post button permalink in the sample permalink HTML when updating the slug on a published or future post.
Fixes #32954
Props boonebgorges, johnbillion

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


git-svn-id: http://core.svn.wordpress.org/trunk@33741 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-27 20:57:22 +00:00
Sergey Biryukov
4ae4d94dbb Remove wp-includes/comment-functions.php from the $_old_files array. See [33750].
props rachelbaker.
fixes #33569.
Built from https://develop.svn.wordpress.org/trunk@33772


git-svn-id: http://core.svn.wordpress.org/trunk@33740 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-27 20:40:24 +00:00
John Blackbourn
b9ec4136d9 Remove error from the query variables when cleaning up a URL in wp_admin_canonical_url().
Fixes #32847

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


git-svn-id: http://core.svn.wordpress.org/trunk@33738 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-27 17:26:21 +00:00
John Blackbourn
a60d143f7b Correct the hook docs for the user_profile_update_errors action.
Fixes #33537
Props yamchhetri

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


git-svn-id: http://core.svn.wordpress.org/trunk@33737 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-27 17:16:21 +00:00
Sergey Biryukov
fc9961ca22 Make post meta box toggles accessible.
props joedolson.
fixes #33544.
Built from https://develop.svn.wordpress.org/trunk@33762


git-svn-id: http://core.svn.wordpress.org/trunk@33730 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-26 15:23:24 +00:00
Scott Taylor
93f745fd9b In WP_Users_List_Table::single_row(), $actions is not always set before being used.
See #33491.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33703 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-25 20:38:20 +00:00
Scott Taylor
ef87172270 foreach is a statement, not a function.
See #33491.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33702 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-25 20:28:22 +00:00
Scott Taylor
c2a0336d22 Instead of [33713], allow WP_Posts_List_Table::get_bulk_actions() to check edit_posts AND delete_posts.
Props DeBAAT.
Fixes #29789.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33701 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-25 20:12:22 +00:00
Drew Jaynes
e8283a6f88 Docs: The type for the $t_time parameter in the post_date_column_time filter docs should be string, not array.
Props jjeaton
Fixes #33540.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33699 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-25 17:15:21 +00:00
Scott Taylor
767dd35a47 Media:
When inserting an image into a post, the values in `wp.media.controller.Library` should not default to linking the image when no user settings are present.

The default display setting value for `link` is now `none`. User settings persist and will override or confirm this value based on user actions.

Props liljimmi, janhenckens, eherman24, wonderboymusic.
Fixes #31467.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33697 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-25 12:13:23 +00:00
Dion Hulse
4f8ce1c232 Term Splitting: Switch to a faster cron unschedule process to benefit sites with thousands of affected jobs. Fix the cron hook name in the failsafe rescheduler.
Props Otto42, dd32, peterwilsoncc
See #33423

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


git-svn-id: http://core.svn.wordpress.org/trunk@33695 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-25 04:32:21 +00:00
Scott Taylor
b1c00f2653 Posts List Table:
Don't show bulk actions if the user can't edit posts.

Props DrewAPicture.
Fixes #29789.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33680 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-23 16:28:28 +00:00
Scott Taylor
0fa7f817c4 In wp_ajax_add_meta(), do not juggle the value of $_POST and alter it directly. This was done so that edit_post() could pull $_POST out of the air by-reference and alter it (equally as bad). edit_post() accepts a $post_data array. Do that instead.
See #33491.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33664 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-21 18:13:24 +00:00
Scott Taylor
e9305edbce When createing "Sample Page" on install, comments should be closed.
Props macmanx. 
Fixes #33490.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33660 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-21 17:42:25 +00:00
Scott Taylor
fa2d0a2d55 Comment List Tables:
* Toggle visibility of pending bubble when a comment is dynamically moderated
* Add a CSS class to the pending bubble to hide it / remove to show it

See #11200.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33659 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-21 17:26:26 +00:00
Drew Jaynes
54b2e39fdd Docs: Add a changelog entry for the $post_type parameter added to the restrict_manage_posts hook in [33644].
Props pavelevap
Fixes #17891.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33658 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-21 16:12:25 +00:00
Helen Hou-Sandí
514caf0120 List tables: Allow filtering of hidden and default hidden columns.
Similar to `get_hidden_meta_boxes()`, there are now filters named `default_hidden_columns` and `hidden_columns`.

props Compute, MikeHansenMe, chriscct7.
fixes #32499.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33656 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-21 15:32:29 +00:00
Dion Hulse
09da29102b WP_Filesystem: SSH2 handler: Remove support for is_writable() via SSH, it turns out PHP doesn't verify the writability via SFTP and instead uses a comparison based on the current php system process user instead of the ssh user.
This fixes the 'The update cannot be installed because we will be unable to copy some files.' error encountered during updates by skipping the write test completely.

Props jobst.
Fixes #33480 for trunk

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


git-svn-id: http://core.svn.wordpress.org/trunk@33655 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-21 11:43:25 +00:00
Drew Jaynes
93009543bc Docs: Fix some minor inline documentation syntax issues in the hook docs for the post_edit_category_parent_dropdown_args filter, introduced in [33682].
See #32246. See #33026.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33653 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-21 04:54:26 +00:00
Drew Jaynes
416df545ba Docs: Fix a variety of inline documentation syntax issues and add some strategic spacing.
Fixes #29086.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33652 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-21 04:13:24 +00:00
Drew Jaynes
3bb87e08e4 Docs: Add missing @access tags to properties and methods in wp-admin/includes/class-wp-upgrader.
See #29086.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33651 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-21 04:05:25 +00:00
Drew Jaynes
73d6dec8eb Docs: Correct a typo in the summary for the Theme_Upgrader->bulk property.
Also adds a couple of missing `@access` tags.

Props kraftbj
See #29086.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33650 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-21 03:15:25 +00:00
Boone Gorges
52614b491a Filter the arguments passed to wp_dropdown_categories() in the Categories post edit metabox.
The new 'post_edit_category_parent_dropdown_args' provides parity with other
places in wp-admin where `wp_dropdown_categories()` args are filtered, such as
'taxonomy_parent_dropdown_args'.

Props theMikeD.
Fixes #33026.
Built from https://develop.svn.wordpress.org/trunk@33682


git-svn-id: http://core.svn.wordpress.org/trunk@33649 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-21 01:28:25 +00:00
Drew Jaynes
c8638a285a Docs: Standardize @deprecated tag formatting for deprecated functions in wp-admin/includes/ms-deprecated.php.
Props Alphawolf for the initial patch
Props DrewAPicture

See #28806.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33642 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-20 22:26:24 +00:00
Drew Jaynes
bac6e69b3c Docs: Standardize @deprecated tag formatting and add missing DocBlocks to deprecated functions in wp-admin/includes/deprecated.php.
Opted not to use the multi-function DocBlock syntax in the name of not taking shortcuts in documentation for the sake of brevity.

Props Alphawolf for the initial patch.
See #28806

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


git-svn-id: http://core.svn.wordpress.org/trunk@33638 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-20 21:23:25 +00:00
Drew Jaynes
c36c4efea6 Docs: Add a missing summary to the DocBlock for wp_media_upload_handler().
See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33637 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-20 21:01:25 +00:00
Drew Jaynes
89c39e7eab Docs: Clarify the different return conditions in the DocBlock for WP_List_Table->handle_row_actions().
This clarification follows the introduction of primary columns in 4.3. See #33313.

Props morganestes.
Fixes #33436.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33635 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-20 20:22:25 +00:00
Scott Taylor
4254f22c2d In WP_Posts_List_Table::inline_edit(), check that $post_formats[0] is an array before traversing.
Props DrewAPicture.
Fixes #33025.


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


git-svn-id: http://core.svn.wordpress.org/trunk@33634 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-20 20:19:25 +00:00
Scott Taylor
4694c477d3 Custom Post Types:
* Introduce `is_post_type_viewable( $post_type_object )`
* Separate the HTML bits from the translatable bits in the `post` messages array in `edit-form-advanced.php`
* Don't show certain UI pieces when a post is not viewable on the front end

When a custom post type item is not viewable on the front end, we don't want to show links to View it (on the front end) all over the admin. We also want to hide the Preview link, et al. We also want our admin messages to not contain said links.

Custom post types with `public_queryable` set to `false` are not viewable on the front end. 
`'page'` is viewable on the front end, but `'page'` is a `_builtin` type, and `public_queryable` is set to `false` when it is registered - see `WP::parse_request()` for when `public_queryable` gets used.

This is confusing, but also somewhat straightforward: to determine if a post type is viewable on the front end, we can check one way for `_builtin => true` and another way for `_builtin => false`:

`$post_type->publicly_queryable || ( $post_type->_builtin && $post_type->public )`

If a post type is `publicly_queryable`, it's viewable. If that value is `false`, it is viewable if it's a `_builtin` type that is also `public`.

I am in search of edge cases, so this shall land.

Props wonderboymusic, DrewAPicture.
See #17609.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33633 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-20 19:40:25 +00:00
Scott Taylor
20f6db2b18 Comment List Tables:
* Ensure that dynamic bubble counts are in sync by `comment_post_ID`
* Scope `:animated` to `#the-comment-list`

See #11200.


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


git-svn-id: http://core.svn.wordpress.org/trunk@33629 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-20 16:36:25 +00:00
Scott Taylor
2e2223ae74 Comments List Table:
* In a view that initially has comments, but they get removed due to user actions: show the `No Items` row instead of bombing out and showing nothing (which looks broken)
* To accomplish this, in `WP_Comments_List_Table::display()`: call `->display_rows_or_placeholder()` instead of `->display()`
* Listen for the end of row `.fadeOut()`s if necessary using jQuery Promises

Fixes #11200.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33624 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-20 05:54:25 +00:00
Scott Taylor
df618f3461 Comments List Table:
* Show count next to "Approved"
* Properly increment/decrement counts when row actions are clicked
* In `_wp_ajax_delete_comment_response()`, return the comment's `status` with the `supplemental` data
* Handle counts properly on each scenario of `undo`

See #11200.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33622 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-20 02:51:25 +00:00
Dion Hulse
a32d83586e Upgrades: When upgrading via FTP, use LIST -a to detect if a file exists.
`LIST` & `NLST` by default on some servers require the `-a` flag to view hidden files (ie. `.maintenance`)
Although we could simply pass the `-a` flag to `NLST`, opting to use `LIST` which we use elsewhere should mean less chance of server incompatibilities.

Props jcroucher.
Fixes #28013.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33615 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-19 12:38:25 +00:00
Dion Hulse
25c5d372d3 Term Splitting: Fix a reversal of parameters to wp_schedule_single_event() introduced in [33621].
The existing invalid cron entries will not be purged automatically (as the 'timestamp' is never matched) so we do this ourselves.

Props mechter for noticing!
See #30261.
Fixes #33423 for trunk.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33613 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-19 11:31:26 +00:00
Dion Hulse
096b2f58fa Fix PHP notice after [33492] when updating themes.
Props bobbingwide.
See #33208.
Fixes #33427.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33612 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-19 10:35:25 +00:00
Scott Taylor
3923017f82 The 'restrict_manage_posts' hook currently fires on the Post and Media list tables, but is passed zero arguments. Pass $post_type.
Props sunnyratilal, scribu.
Fixes #17891.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33611 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-19 06:23:25 +00:00
Scott Taylor
23f62a59da Correct typo in doc block for WP_Filesystem_ftpsockets::rmdir
Props Toro_Unit.
Fixes #33255.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33606 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-18 23:33:24 +00:00
Dominik Schilling
96a6f0ac1f Pinking shears.
Built from https://develop.svn.wordpress.org/trunk@33627


git-svn-id: http://core.svn.wordpress.org/trunk@33594 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-17 21:39:25 +00:00
Dominik Schilling
ce557062f4 Upgrade: Update $_old_files for 4.3.
fixes #33394.
Built from https://develop.svn.wordpress.org/trunk@33626


git-svn-id: http://core.svn.wordpress.org/trunk@33593 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-17 20:24:26 +00:00
Helen Hou-Sandí
50e42e8a07 List tables: Yet more primary column fallbacks.
Some custom list tables override enough methods for the column definition fallback to never kick in, so let's ensure that toggling columns only applies when a primary column is defined in some way. We also need to show a toggle button when we can when there are no row actions.

props Chouby, obenland, ocean90.
fixes #33313.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33590 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-17 15:38:25 +00:00
Boone Gorges
dba7c50d29 Don't run term-splitting routine on new installations.
Props pento.
Fixes #30261.
Built from https://develop.svn.wordpress.org/trunk@33621


git-svn-id: http://core.svn.wordpress.org/trunk@33588 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-17 14:29:25 +00:00
Konstantin Obenland
e6bc6242ad Passwords: Restore second parameter for wp_new_user_notification().
After [33023] users would always be notified, this restores previous behavior.

Props markjaquith, ocean90.
Fixes #33358.


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


git-svn-id: http://core.svn.wordpress.org/trunk@33587 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-17 14:25:27 +00:00
Boone Gorges
151d27369d Term splitting routine should be run in a separate process, triggered via wp-cron.
[32814] introduced a routine to split shared terms, which was run during the
regular WP database upgrade. This turned out to be problematic because plugins
are not loaded during the db upgrade (due to `WP_INSTALLING`), with the result
that plugins were not able to hook into the 'split_shared_term' action during
the bulk split. We work around this limitation by moving the term splitting
routine to a separate process, triggered by a wp-cron hook.

Props boonebgorges, Chouby, peterwilsoncc, pento, dd32.
Fixes #30261.
Built from https://develop.svn.wordpress.org/trunk@33615


git-svn-id: http://core.svn.wordpress.org/trunk@33582 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-14 03:59:26 +00:00
Dominik Schilling
f74a907eac Capabilities: Fall back to the edit_posts capability for orphaned comments.
Also avoid PHP notices because of orphaned comments in the comments list table.
Includes unit test.

props pento, dd32.
fixes #33154.
Built from https://develop.svn.wordpress.org/trunk@33614


git-svn-id: http://core.svn.wordpress.org/trunk@33581 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-13 22:31:24 +00:00
Andrew Ozz
3bfd096440 Fix paste typos in upgrade.php.
Props tellyworth. Fixes #33206.
Built from https://develop.svn.wordpress.org/trunk@33609


git-svn-id: http://core.svn.wordpress.org/trunk@33576 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-11 23:44:24 +00:00
Dion Hulse
aace7c2c8d Function documentation: Fix a broken docbock introduced with [32642].
See #32444.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33568 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-10 10:50:26 +00:00
Dion Hulse
e2b10dad49 Upgrade: Skip the sitecategories table when it doesn't exist (Global Terms is disabled).
Props nofearinc, obenland, SergeyBiryukov, and pento.
Fixes #33206

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


git-svn-id: http://core.svn.wordpress.org/trunk@33564 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-09 02:22:26 +00:00
John Blackbourn
6bd6069fc0 Remove all existing internal feature pointers.
Fixes #33289
Props obenland, ocean90, SergeyBiryukov

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


git-svn-id: http://core.svn.wordpress.org/trunk@33560 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-07 00:59:24 +00:00
Mark Jaquith
309516a6c1 Move media hooks out of admin-filters.php as sometimes editors are used on the front end.
fixes #33257
props wonderboymusic
Built from https://develop.svn.wordpress.org/trunk@33590


git-svn-id: http://core.svn.wordpress.org/trunk@33557 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-06 20:40:26 +00:00
Dominik Schilling
198cdb1dde Multisite mails: Initialize $current_user before accessing $current_user->user_login.
props Toro_Unit.
see #31217.
fixes #33254.
Built from https://develop.svn.wordpress.org/trunk@33569


git-svn-id: http://core.svn.wordpress.org/trunk@33536 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-04 11:39:25 +00:00
Dominik Schilling
a9b3f12826 Heartbeat: Ensure post locks are released.
Built from https://develop.svn.wordpress.org/trunk@33542


git-svn-id: http://core.svn.wordpress.org/trunk@33509 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-04 04:54:34 +00:00