Commit Graph

31564 Commits

Author SHA1 Message Date
Drew Jaynes
ad64ee866b Docs: Mark the optional $upgrader parameter as such and add a description in the DocBlock for Language_Pack_Upgrader::async_upgrade().
See [32655].

See #30989. See #32246.


git-svn-id: https://develop.svn.wordpress.org/trunk@34497 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 14:34:15 +00:00
Scott Taylor
04bb8a07d7 Canonical/Rewrite: After [34492], fix rel="canonical" URLs for paginated posts.
Props wonderboymusic, joostdevalk.
See #11694.


git-svn-id: https://develop.svn.wordpress.org/trunk@34496 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 14:30:00 +00:00
Drew Jaynes
02e1102a5b Docs: Add a summary, version, and parameter and return descriptions to the DocBlock for WP_Filesystem_ftpsockets::get_contents().
Also reverses the return types as `string` is expected, `false` is the outlier.

See [30978].

See #30989. See #32246.


git-svn-id: https://develop.svn.wordpress.org/trunk@34495 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 14:21:50 +00:00
Scott Taylor
30554cccab After [34492], no need to import the global instance when we are, in fact, currently, that instance.
See #11694.


git-svn-id: https://develop.svn.wordpress.org/trunk@34494 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 14:19:03 +00:00
Drew Jaynes
6ac2cb05e6 Docs: Add a summary, version, and parameter and return descriptions to the DocBlock for WP_Filesystem_FTPext::get_contents().
Also reverses the return types as `string` is expected, `false` is the outlier.

See [30978].

See #30989. See #32246.


git-svn-id: https://develop.svn.wordpress.org/trunk@34493 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 14:10:47 +00:00
Scott Taylor
0111ecef55 Canonical/Rewrite: sanity check posts that are paged with <!--nextpage-->. Page numbers past the max number of pages are returning the last page of content and causing infinite duplicate content.
Awesome rewrite bug: the `page` query var was being set to `'/4'` in `$wp`. When cast to `int`, it returns `0` (Bless you, PHP). `WP_Query` calls `trim( $page, '/' )` when setting its own query var. The few places that were checking `page`	before posts were queried now have sanity checks, so that these changes work without flushing rewrites.	

Adds/updates unit tests.

Props wonderboymusic, dd32.
See #11694.


git-svn-id: https://develop.svn.wordpress.org/trunk@34492 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 14:03:05 +00:00
Drew Jaynes
c9093207df Docs: Add a summary, version, and @access tag to the property DocBlock for Custom_Image_Header->updated.
See [14907] for where the property was initially introduced.
See [30187] for where the property was actually declared.

Props brentvr.
See #30224. See #32246.


git-svn-id: https://develop.svn.wordpress.org/trunk@34491 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 13:38:03 +00:00
Drew Jaynes
00eab11256 Docs: Add a summary, version, and @access tag to the property DocBlock for Custom_Background->updated.
See [13765] for where the property was initially introduced.
See [30186] for where the property was actually declared.

Props brentvr.
See #30224. See #32246.


git-svn-id: https://develop.svn.wordpress.org/trunk@34490 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 13:33:18 +00:00
Drew Jaynes
72a968ca03 Docs: Add a summary, version, and @access tag to the property DocBlock for WP_Locale->number_format.
See [5308] for where the property was initially introduced.
See [31083] for where the property was actually declared.

Props brentvr.
See #30224. See #32246.


git-svn-id: https://develop.svn.wordpress.org/trunk@34489 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 13:25:55 +00:00
Dominik Schilling (ocean90)
1efbe10b47 Customizer: Update tests for [34487].
Fixes #33634.

git-svn-id: https://develop.svn.wordpress.org/trunk@34488 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 11:31:30 +00:00
Dominik Schilling (ocean90)
15ee0a44b2 Customizer: Use the plural label for available menu item types.
Fixes #33634.

git-svn-id: https://develop.svn.wordpress.org/trunk@34487 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 09:15:15 +00:00
Dominik Schilling (ocean90)
273bd1ed99 Edit Post: Add missing periods.
See #31858.

git-svn-id: https://develop.svn.wordpress.org/trunk@34486 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 08:53:21 +00:00
Drew Jaynes
8e61ab359c Docs: Link up a hook reference with an inline @see tag in the return description for get_locale().
Missed in [34484].

See #32246.


git-svn-id: https://develop.svn.wordpress.org/trunk@34485 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 05:50:49 +00:00
Drew Jaynes
b91804e0bf Docs: Fix the summary for get_locale().
Also update the description to properly link up hook references with inline `@see` tags.

See #32246.


git-svn-id: https://develop.svn.wordpress.org/trunk@34484 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 05:49:07 +00:00
Drew Jaynes
f85670cd36 Docs: Clarify the file header summary for wp-includes/l10n.php and add the version it was introduced.
See #32246.


git-svn-id: https://develop.svn.wordpress.org/trunk@34483 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 05:46:35 +00:00
Drew Jaynes
1810710798 Docs: Split the DocBlock summary for __() into a summary and description.
Also, notate the default value for the optional `$domain` parameter.

See #32246.


git-svn-id: https://develop.svn.wordpress.org/trunk@34482 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 05:42:35 +00:00
Drew Jaynes
4d94ef47de Docs: Add a summary to the hook doc for the nav_menu_item_args filter, introduced in [34471].
Fixes #29417.


git-svn-id: https://develop.svn.wordpress.org/trunk@34481 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 05:08:36 +00:00
Scott Taylor
3a8f42bfe0 Post Thumbnails: In get_the_post_thumbnail_url(), return false instead of empty string when no URL is available.
Fixes #33070.


git-svn-id: https://develop.svn.wordpress.org/trunk@34480 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 04:37:48 +00:00
Scott Taylor
e366584fae Unit Tests: after [34477], make Tests_Link_GetPostCommentsFeedLink more respectable.
See #33693.


git-svn-id: https://develop.svn.wordpress.org/trunk@34479 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 04:31:58 +00:00
Gary Pendergast
e1fafc56d5 WPDB: When attempting to fall back to ext/mysql in db_connect(), return the result of the fall back.
While it doesn't affect Core, we should also be passing the `$allow_bail` parameter, for anything that uses it differently.

Props markoheijnen, johnbillion.

Fixes #33105.



git-svn-id: https://develop.svn.wordpress.org/trunk@34478 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 04:29:40 +00:00
Scott Taylor
158aecc3ec Feeds/Links: after [34336], use a different meat cleaver to fix Rewrite spillage across test cases.
Fixes #33693.


git-svn-id: https://develop.svn.wordpress.org/trunk@34477 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 04:19:56 +00:00
Scott Taylor
b9ad7136d7 WP: after [34443], calling get_queried_object() messes up unit tests. We can just clone the $post prop and call it a day.
Fixes #20226.


git-svn-id: https://develop.svn.wordpress.org/trunk@34476 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 03:53:39 +00:00
Scott Taylor
6ad1c1c380 Plugins: on the plugins admin screen, the "has been deleted" string needs a plural.
Props jmayhak.
Fixes #33239.


git-svn-id: https://develop.svn.wordpress.org/trunk@34475 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 03:41:52 +00:00
Scott Taylor
bab2316129 Date/Time: Add unit tests for the_date().
Props jubstuff.
Fixes #33750.


git-svn-id: https://develop.svn.wordpress.org/trunk@34474 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 03:33:21 +00:00
Scott Taylor
9d71ae4122 Edit Post: After [33666], separate the translation string for pages, avoiding HTML usage.
Props ramiy.
Fixes #31858.


git-svn-id: https://develop.svn.wordpress.org/trunk@34473 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 03:27:26 +00:00
Scott Taylor
d98165d1c3 Media Modal: move the translation strings for insertIntoPost and uploadedToThisPost to the get_post_type_labels() array as insert_into_item and uploaded_to_this_item.
Props flixos90.
Fixes #33616.


git-svn-id: https://develop.svn.wordpress.org/trunk@34472 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 03:21:11 +00:00
Scott Taylor
0e81ac08de Nav Menus: Add a 'nav_menu_item_args' filter to Walker_Nav_Menu::start_el().
Props bjornjohansen.
Fixes #29417.


git-svn-id: https://develop.svn.wordpress.org/trunk@34471 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 03:16:44 +00:00
Scott Taylor
000b9e2fb3 Include fourth array parameter in return value doc block for wp_get_attachment_image_src().
Props kadamwhite.
Fixes #33905.


git-svn-id: https://develop.svn.wordpress.org/trunk@34470 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 03:13:08 +00:00
Scott Taylor
c9c9e19260 After [34341], add translation strings.
Props ramiy.
Fixes #31862.


git-svn-id: https://develop.svn.wordpress.org/trunk@34469 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 03:08:34 +00:00
Gary Pendergast
c47ef29b34 Tests: Remove a var_dump() added in [34373].
See #33070.



git-svn-id: https://develop.svn.wordpress.org/trunk@34468 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 03:07:20 +00:00
Scott Taylor
21dad99c1b List Tables: add JS code to dynamically toggle the disabled attribute of the Bulk Actions dropdown and Apply button.
Props wonderboymusic, pareshradadiya.
Fixes #31634.


git-svn-id: https://develop.svn.wordpress.org/trunk@34467 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 01:06:17 +00:00
Scott Taylor
d92723a33f Users: in WP_User::__unset(), don't reset the deprecated prop id to ID. Still throw the deprecated notice.
Update unit test.

Fixes #20043.


git-svn-id: https://develop.svn.wordpress.org/trunk@34466 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 00:48:23 +00:00
Scott Taylor
c1c93f1e95 Widgets: when passing a string arg value to dynamic_sidebar(), don't reset $index when the arg's sanitized value matches the sanitized name of a sidebar.
Adds unit test.

Props tyxla, fjarrett.
Fixes #23423.


git-svn-id: https://develop.svn.wordpress.org/trunk@34465 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 00:29:54 +00:00
Scott Taylor
9209546292 Recent Posts Widget: remove HTML fragment caching. The cache currently doesn't work cross-scheme and causes mixed content issues for links. The widget was written pre-$split_the_query, after which post objects can be served from the cache.
Fixes #27565.


git-svn-id: https://develop.svn.wordpress.org/trunk@34464 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-24 00:16:16 +00:00
Scott Taylor
325a900519 Calendar Widget: remove the title attribute for days and replace with aria-label. Spruce up some of this nasty code. Delete unnecessary bits.
Props wonderboymusic, elusiveunit, 5um17. 
Fixes #30297.


git-svn-id: https://develop.svn.wordpress.org/trunk@34463 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 23:56:05 +00:00
John Blackbourn
1ce18f6e95 Send a 500 HTTP response code when the server's PHP or MySQL checks fail.
Fixes #33689
Props jeichorn


git-svn-id: https://develop.svn.wordpress.org/trunk@34462 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 21:56:32 +00:00
Scott Taylor
a87b30da21 Comments: allow meta boxes for Discussion and Comments in extenuating circumstances.
* Discussion: Post Type stops supporting comments, but comments and/or pings are open on a post. 
* Comments: Post is published or private, the post type has stopped supporting comments, but comments and/or pings are open on a post.

Currently, there is no way to toggle those settings off.

Props couturefreak, wonderboymusic, rachelbaker.
Fixes #28080.


git-svn-id: https://develop.svn.wordpress.org/trunk@34461 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 19:48:41 +00:00
Boone Gorges
daadd27ed4 Allow comment_exists() to match based on GMT date.
The `comment_date_gmt` field of the `wp_comments` table is indexed, which makes
`WHERE` matches against the field much faster than against the unindexed
`comment_date`. For bulk operations like data import, the speed difference can
be meaningful.

We continue to default to 'blog' for `$timezone`, to preserve compatibility
with existing uses.

Props apokalyptik.
Fixes #33871.

git-svn-id: https://develop.svn.wordpress.org/trunk@34460 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 18:15:39 +00:00
John Blackbourn
92748bb96e Add an entry for Cloudup to the list of oEmbed providers.
See #26278


git-svn-id: https://develop.svn.wordpress.org/trunk@34459 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 15:59:42 +00:00
John Blackbourn
d8a59791f0 Avoid a PHP notice if the last_updated property isn't present in a plugin's data from the Plugins API.
Fixes #33024
Props icetee


git-svn-id: https://develop.svn.wordpress.org/trunk@34458 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 15:09:42 +00:00
Boone Gorges
cf3042389d Fix comment_exists() unit test introduced in [34456].
See #33871.

git-svn-id: https://develop.svn.wordpress.org/trunk@34457 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 14:46:36 +00:00
Boone Gorges
01c8e7a8e1 Add unit test for comment_exists().
See #33871.

git-svn-id: https://develop.svn.wordpress.org/trunk@34456 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 14:34:37 +00:00
Boone Gorges
4cbd2fbc55 Multisite: Don't limit site titles to 50 chars.
This restriction dates from ye olden times, ie https://mu.trac.wordpress.org/changeset/1140.
It is no longer relevant.

Props chriscct7, theode.
Fixes #33973.

git-svn-id: https://develop.svn.wordpress.org/trunk@34455 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 14:23:13 +00:00
Boone Gorges
e6b7c6b2d4 Bail early when invalid ID is passed to get_comment_class().
This helps to avoid PHP notices later in the function.

Props walterebert, dipesh.kakadiya, DrewAPicture.
Fixes #33947.

git-svn-id: https://develop.svn.wordpress.org/trunk@34454 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 14:08:47 +00:00
Boone Gorges
b23a1fc613 Add a few simple tests for get_comment_class().
Props walterebert, dipesh.kakadiya.
See #33947.

git-svn-id: https://develop.svn.wordpress.org/trunk@34453 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 14:04:55 +00:00
Scott Taylor
fc3b7b20cd Links: the esc_html() additions in [34444] aren't very nice to screen reader <span>s. Revert those specific calls.
See #14900.


git-svn-id: https://develop.svn.wordpress.org/trunk@34452 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-23 04:25:18 +00:00
Sergey Biryukov
6c63977ec2 Make the 'register_post_type_args' filter introduced in [34242] available for built-in post types too.
Props MikeSchinkel.
Fixes #17447.

git-svn-id: https://develop.svn.wordpress.org/trunk@34451 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-22 22:31:25 +00:00
John Blackbourn
9dd4680d2f Add tests for some missing capabilities, including do_not_allow.
See #32394.


git-svn-id: https://develop.svn.wordpress.org/trunk@34450 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-22 22:17:30 +00:00
John Blackbourn
f1191d2e6e Correct a capability name in the roles and capabilities mapping. The delete_others_pages key was missing, and the delete_others_posts key was duplicated.
Introduced in [32812].

See #32394.


git-svn-id: https://develop.svn.wordpress.org/trunk@34449 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-22 22:15:18 +00:00
Aaron Jorbin
dd25cc9a7c Add test image for test_exif_keywords test
[34374] added a test that relies on a new test image. This test image wasn't included in the commit.  This fixes the broken Tests_Image_Meta::test_exif_keywords test.

Props swissspidy, SteveHoneyNZ.
Fixes #33772.



git-svn-id: https://develop.svn.wordpress.org/trunk@34448 602fd350-edb4-49c9-b593-d223f7449a82
2015-09-22 21:42:45 +00:00