Commit Graph

19632 Commits

Author SHA1 Message Date
Drew Jaynes 81524f3bfc Filesystem: Following the introduction of the `KB|MB|GB|TB_IN_BYTES` constants in [35286], use them in various places in core.
Props sudar.
Fixes #22405.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35291 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 14:03:25 +00:00
Drew Jaynes 6a51505a23 Docs: Improve the return description in the DocBlock for `rest_send_allow_header()`.
Props danielbachhuber.
Fixes #34374.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35290 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 13:48:27 +00:00
Sergey Biryukov 116f59af60 REST API: Change nonce name to `_wpnonce`.
It's shorter and is compatible with the default name in `wp_nonce_field()`.

Props danielbachhuber.
Fixes #34375.
Built from https://develop.svn.wordpress.org/trunk@35323


git-svn-id: http://core.svn.wordpress.org/trunk@35289 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 08:14:24 +00:00
Sergey Biryukov da157f16b1 Add `get_terms_defaults` filter for the default arguments of `get_terms()`.
Fixes #33369.
Built from https://develop.svn.wordpress.org/trunk@35322


git-svn-id: http://core.svn.wordpress.org/trunk@35288 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 08:08:25 +00:00
Sergey Biryukov d1dea6e6cf Reorder default arguments in `get_terms()` for consistency with the hash notation added in [29128].
See #33369.
Built from https://develop.svn.wordpress.org/trunk@35321


git-svn-id: http://core.svn.wordpress.org/trunk@35287 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 08:01:25 +00:00
Sergey Biryukov 6b5e523996 Docs: Correct function name in `get_terms_args` parameter description.
See #33369.
Built from https://develop.svn.wordpress.org/trunk@35320


git-svn-id: http://core.svn.wordpress.org/trunk@35286 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 07:42:24 +00:00
Sergey Biryukov 1025e22303 Docs: Correct duplicate hook reference for `get_terms`.
See #33369.
Built from https://develop.svn.wordpress.org/trunk@35319


git-svn-id: http://core.svn.wordpress.org/trunk@35285 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 07:40:27 +00:00
Andrew Ozz de881c4a97 Precommit cleanup, see r35313.
Built from https://develop.svn.wordpress.org/trunk@35318


git-svn-id: http://core.svn.wordpress.org/trunk@35284 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 05:33:24 +00:00
Andrew Ozz 71ac079074 Widgets: add a button to delete all inactive widgets simultaneously for better UX.
Props cdog.
Fixes #19159.
Built from https://develop.svn.wordpress.org/trunk@35317


git-svn-id: http://core.svn.wordpress.org/trunk@35283 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 05:23:26 +00:00
Scott Taylor 47879dc83a Export: add missing labels and improvement accessibility of the Export screen.
Props afercia.
Fixes #33046.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35282 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 03:57:24 +00:00
Scott Taylor 85d21feca6 Plugins/Updates: in `request_filesystem_credentials()`, alter the heading HTML tag based on the current screen for improved semantics.
Props afercia.
Fixes #34267.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35281 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 03:51:24 +00:00
Scott Taylor 8eb3de46c9 Formatting: move `url_shorten()` from `wp-admin/includes/misc.php` to `wp-includes/formatting.php` for more global access.
Adds unit tests.

Props mulvane, chriscct7.
Fixes #20166.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35280 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 03:48:24 +00:00
Scott Taylor e525ab849d Administration: the current admin menu item should have an `aria-haspopup` attribute when the menu is folded.
Unify the jQuery selector caching for `window`, `document`, and `body`.

Props afercia.
Fixes #32578.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35279 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 03:41:24 +00:00
Scott Taylor e6015a31ab Site Icon: make the default value for the `site_icon` option `0` in `schema.php`.
Props swissspidy, sebastian.pisula.
Fixes #34339.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35278 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 03:28:25 +00:00
Scott Taylor 97c75b5f07 AJAX UNIT TESTS: Have you ever wondered why these take 600 forevers to run? They all eventually call `do_action( 'admin_init' )`, which has `_maybe_update_core`, `_maybe_update_plugins`, and `_maybe_update_themes` hooked to it. REMOVE THEM, and AJAX unit tests run like the wind. `Tests_Ajax_Response` is still slow.
See #30017, #33968.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35277 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 03:18:25 +00:00
Sergey Biryukov 9fa88a7f27 Autoprefixer for [35281].
See #33322.
Built from https://develop.svn.wordpress.org/trunk@35310


git-svn-id: http://core.svn.wordpress.org/trunk@35276 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 03:02:24 +00:00
Scott Taylor fc850bf274 Unit Tests: consolidate the many separate implementations of `_make_attachment()` into a helper method on `WP_UnitTestCase`.
Fixes #34075.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35275 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-21 01:59:26 +00:00
Weston Ruter d7e13544ea Customizer: Prevent `nav_menu_item` settings from becoming dirty when their controls are set up.
Since `wp_setup_nav_menu_item()` returns the `classes` property as an array but the Customizer manages the value as a string, the setting needs to initially export the value as a string. This prevents the `classes` property type change from causing the setting to get marked as dirty even though nothing changed. This is a regression from [34788].

See #34111.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35274 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 22:45:29 +00:00
Weston Ruter bee05e0cdc Customizer: Introduce `customize_loaded_components` filter to allow core components to be disabled.
Also move style rule from `customize-nav-menus.css` to `customize-controls.css` so that widgets button is properly styled when `nav_menus` component is excluded from loading. See [35304]. See #33327.

Props westonruter, DrewAPicture.
Fixes #33552.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35273 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 22:16:25 +00:00
Andrew Ozz 3451251548 TinyMCE: update to 4.2.6. Changelog: http://www.tinymce.com/develop/changelog/?ctrl=version&act=view&pr_id=1&vr_id=887.
Fixes #34331.
Built from https://develop.svn.wordpress.org/trunk@35306


git-svn-id: http://core.svn.wordpress.org/trunk@35272 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 22:06:24 +00:00
Weston Ruter c77bb38b3d Customizer: Allow new `option` settings to not be saved as autoloaded by passing an `autoload` arg value of `false`.
The `autoload` argument value is passed along to `update_option()` which has accepted an `$autoload` parameter since [31628].

Props westonruter, dlh.
See #26394.
Fixes #33499.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35271 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 21:19:25 +00:00
Andrea Fercia 1e1e7a9fc9 Customizer: Make the widgets "Reorder" and "Add a Widget" buttons... buttons.
For accessibility, UI controls should preferably be native controls. Adds
ARIA attributes and labels to improve accessibility and pair these buttons
with the ones in the Menu Customizer.

Props obenland, TomHarrigan, sanket.parmar, metodiew, afercia.

Fixes #33327.
Built from https://develop.svn.wordpress.org/trunk@35304


git-svn-id: http://core.svn.wordpress.org/trunk@35270 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 20:15:26 +00:00
Drew Jaynes 8549e76d56 Docs: Add translator comments for two `_deprecated_argument()` calls added to `get_wp_title_rss()` and `wp_title_rss()` in [35294].
See #31078. See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35269 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 19:20:25 +00:00
Weston Ruter 6d9d18315d Customizer: Implement indicators for invalid nav menu items.
The same indicator on the nav menus admin page is now present for nav menu items in the Customizer. When a menu item is present for a post type that is no longer registered, the menu item will appear with the indicator.

Props kucrut, westonruter.
Fixes #33665.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35268 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 19:08:25 +00:00
Drew Jaynes 0715dc8a4f Docs: Adjust syntax in the hook doc summaries for the `document_title_separator` and `document_title_parts` filters, introduced in [35294].
See #31078. See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35267 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 18:37:54 +00:00
Drew Jaynes 7c538033dd Docs: Fix indentation and improve usefulness of inline comments surrounding the if/elseif conditions for assigning document titles in `wp_get_document_title()`.
See #31078. See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35266 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 18:32:00 +00:00
Konstantin Obenland f6941fddf4 Site Icon: Get site icon ID only when needed.
Cuts down on unnecessary queries, especially in environments that rely on
post meta a lot. Reverts [32997].

Props ap.koponen, swissspidy.
Fixes #34368.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35265 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 18:23:44 +00:00
Drew Jaynes 0ea90a9174 Docs: Update the hook doc for the `pre_get_document_title` filter to explain ''what'' value is filterable rather than ''why'' the value is filterable :-)
The hook was introduced in [35294].

See #31078. See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35264 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 18:14:24 +00:00
Drew Jaynes 0a1026ac10 Docs: Improve vague changelog entries for functions and hooks where arguments were deprecated in [35294].
See #31078. See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35263 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 18:10:43 +00:00
Drew Jaynes 08f3a3b226 Docs: Fix up DocBlock syntax for the now-deprecated `wp_title()`.
See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35262 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 17:53:24 +00:00
Konstantin Obenland 788cb75879 Tests: Use updated filter names and oembed title for UT sanity.
See [35294], #31078.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35261 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 17:05:25 +00:00
Konstantin Obenland c69e96422b Themes: Improve document title output.
Introduces more flexibility in filtering all parts of the document title,the
separator, and a way to short-circuit title generation. Plugins can now also
check for theme support and reliably filter the entire output. See #18548.
Deprecates `wp_title()`.

Fixes #31078.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35260 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 16:21:25 +00:00
Sergey Biryukov b8e250927f In `wp_list_categories()`, rewrite a long condition for clarity.
See #34363.
Built from https://develop.svn.wordpress.org/trunk@35293


git-svn-id: http://core.svn.wordpress.org/trunk@35259 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 16:13:26 +00:00
Sergey Biryukov e0af554638 Tags: Avoid a double trailing space after tags separator in auto-suggest.
Props afercia.
Fixes #33881.
Built from https://develop.svn.wordpress.org/trunk@35292


git-svn-id: http://core.svn.wordpress.org/trunk@35258 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 16:00:30 +00:00
Boone Gorges b285b3002a Correct inline comment in `wp_list_categories()`.
The fallback link for the 'All' option is 'page_for_posts', not
'page_on_front'. Introduced in [32292].

Props sudar, SergeyBiryukov.
Fixes #34363.
Built from https://develop.svn.wordpress.org/trunk@35291


git-svn-id: http://core.svn.wordpress.org/trunk@35257 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 12:55:27 +00:00
Drew Jaynes 7c3a476909 Docs: Correction: `MONTH_IN_SECONDS` was added in 4.4.0.
Props swissspidy.
See [33698]. See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35256 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 07:35:26 +00:00
Drew Jaynes 3686b78448 Media: Introduce the `image_get_intermediate_size` filter to its like-named function, making it possible to manipulate returned intermedia image size data.
Covers both the default and meaningful short-circuit return cases. Also adds a hash notation to the return documentation in the DocBlock.

Props A5hleyRich, DH-Shredder, wonderboymusic.
Fixes #34124.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35255 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 07:24:27 +00:00
Drew Jaynes 875c82f17f Media: Introduce the `enclosure_links` filter, which makes it possible to adjust the list of audio and video enclosure links derived from post content before querying the database.
Props niallkennedy, stevenkword.
Fixes #19890.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35254 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 07:09:25 +00:00
Drew Jaynes 2eb8672961 Docs: The `MINUTE_IN_SECONDS`, `HOUR_IN_SECONDS`, `DAY_IN_SECONDS`, `WEEK_IN_SECONDS`, `MONTH_IN_SECONDS`, and `YEAR_IN_SECONDS` constants were introduced in 3.5.
See [21996]. See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35253 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 06:59:29 +00:00
Drew Jaynes 02c9aeaef3 Filesystem: Introduce constants to allow for easier expression of file sizes and other data amounts.
Adds:
* `KB_IN_BYTES` (kilobytes)
* `MB_IN_BYTES` (megabytes)
* `GB_IN_BYTES` (gigabytes)
* `TB_IN_BYTES` (terabytes)

Props nbachiyski, sudar.
See #22405.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35252 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 06:55:25 +00:00
Drew Jaynes 7771205935 Query: Introduce the `content_pagination` filter, which makes it possible to manipulate how post content is split into "pages" in `WP_Query::setup_postdata()`.
The "pages" — or chunks of post content – are determined by splitting based on the presence of `<!-- nextpage -->` tags in the post content.

Props sirzooro, chriscct7.
Fixes #9911.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35251 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 06:33:27 +00:00
Scott Taylor afe975d754 Formatting: allow date strings to be passed to `get_gmt_from_date()`, instead of requiring `'Y-m-d H:i:s'`.
Adds unit tests.

Props pbearne.
Fixes #34279.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35250 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 06:08:25 +00:00
Scott Taylor f4cc7b3de8 Feeds: add `CEST` to `$timezone` in `SimplePie_Parse_Date`.
Props swissspidy.
Fixes #32749.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35249 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 05:57:24 +00:00
Scott Taylor b0561ed6e4 Dashboard: use the `create_posts` cap on the post type object when determining if the Quick Press widget can be displayed.
Props jim912, ocean90, chriscct7.
Fixes #25681.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35248 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 05:49:24 +00:00
Scott Taylor f89b90a1c9 Theme Installer: toggle `iframe-ready` on the overlay to control the spinner animated GIF and high CPU usage.
Props afercia, adamsilverstein.
Fixes #33322.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35247 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 05:36:25 +00:00
Scott Taylor 85a6189ad8 Users: when calling `wp_insert_user()` with an valid user ID, return `WP_Error` instead of arbitrarily updating user meta.
Adds unit test.

Props swissspidy, bilalcoder.
Fixes #28004.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35246 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 05:28:24 +00:00
Scott Taylor 5d63788d9a XML-RPC: after [35095], change the name of the `xmlrpc_memory_limit` filter to `xmlrpc_chunk_parsing_size`.
Props ankit.gade.
Fixes #29957.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35245 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 05:19:25 +00:00
Scott Taylor c5b6202dfa Widgets: revert [34376] and [34386] as pertains to the Categories widget supporting custom taxonomies.
Punting on 4th down.

See #21165.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35244 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 04:57:25 +00:00
Scott Taylor 62d8b8c5bc List Tables: revert the majority of [34467]. This was almost universally abhorred (the JS that disabled the bulk dropdowns).
See #31634.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35243 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 04:29:24 +00:00
Scott Taylor 89d1eb1e00 Formatting: when making unique filenames in `wp_unique_filename()` by adding an incrementing number, prefix it with a dash to disambiguate from files that end in numbers.
Updates unit tests.

Props mikejolley, tyxla.
Fixes #21453.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35242 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 04:05:25 +00:00
Scott Taylor 4f16590e8e Customizer: when available, show the `description` when rendering the `dropdown-pages` Control.
Props downstairsdev, MikeHansenMe, _smartik_.
Fixes #31540.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35241 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 03:48:26 +00:00
Drew Jaynes a92d4f6fcb Docs: Update the default scheme for `get_rest_url()` from 'json' to 'rest'.
Also adds 'rest' to the documented list of schemes for `home_url()`, `get_home_url()`, `set_url_scheme()`, and the `home_url` and `set_url_scheme` hooks.

Props rachelbaker.
Fixes #34300.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35240 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-19 22:39:25 +00:00
Andrea Fercia e074209a3d Accessibility: Improve the headings hierarchy in the Add Themes screen.
Fixes #33819.
Built from https://develop.svn.wordpress.org/trunk@35273


git-svn-id: http://core.svn.wordpress.org/trunk@35239 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-19 22:04:25 +00:00
Weston Ruter a89294dc49 Widgets: Modify unit test assertion to be compatible with `widget_nav_menu` option being filtered by plugin to return `ArrayIterator`.
Modifies assertion added in [35100].

See #26876.
See #32474.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35238 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-19 21:27:26 +00:00
Drew Jaynes 9f0f213d5e Docs: Add a missing file header for wp-admin/includes/class-wp-site-icon.php.
See #33701.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35237 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-19 20:09:26 +00:00
Drew Jaynes d5a15475d2 Tests: Add some more test coverage for `get_term_field()`.
See #33968.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35236 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-19 03:29:24 +00:00
Boone Gorges 9cc7660c53 Don't store `data` as a property on `WP_Term` objects.
`wp_ajax_add_term()` fetches a term using `get_term()`, and passes the term to
`WP_Ajax_Response`, which expects each of the term's properties to be scalar.
Having `$data` as a `stdClass` (meant to mimic `WP_User::data`, populated by
a `get_row()` database query) violated this expectation, causing fatal string
conversion errors. As a workaround, `$term->data` is converted so that it is
no longer an actual property of the term object, but is assembled only when
requested in the magic `__get()` method.

Fixes #34348.
Built from https://develop.svn.wordpress.org/trunk@35269


git-svn-id: http://core.svn.wordpress.org/trunk@35235 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-19 03:12:24 +00:00
Boone Gorges 2543ffbbae Bust object term cache in `wp_remove_object_terms()`.
Props tszming.
Fixes #34338.
Built from https://develop.svn.wordpress.org/trunk@35268


git-svn-id: http://core.svn.wordpress.org/trunk@35234 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-19 01:53:24 +00:00
Dion Hulse 85258bb914 In `insert_with_markers()` restore the 4.3 behaviour of creating the file if it doesn't exist.
This change also makes it bail early (without writing) if the markers content is the same as the existing, and uses `ftell()` rather than `$bytes` for the location to truncate the file to - based on the file pointer being at the end of the written stream.

Props willmot tigertech kevinatelement
See #31767

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


git-svn-id: http://core.svn.wordpress.org/trunk@35233 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-19 00:53:24 +00:00
Drew Jaynes fd9bcf111d Docs: Fix a typo in the `$blog_id` parameter name in the `rest_url` filter doc.
Props rachelbaker.
Fixes #34351.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35232 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 23:12:25 +00:00
Andrea Fercia 579246ab4a Multisite: Improve the Admin Bar parent menu items color on hover and focus.
Props Nikschavan for the initial patch.
Fixes #34040.
Built from https://develop.svn.wordpress.org/trunk@35265


git-svn-id: http://core.svn.wordpress.org/trunk@35231 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 16:22:24 +00:00
Drew Jaynes 2e11f8cc16 Taxonomy: Improve deprecated argument strings for the 'link' type in `get_categories()` and `wp_dropdown_categories()`.
Props swissspidy, gagan0123.
Fixes #34318.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35230 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 15:35:24 +00:00
Drew Jaynes b37bb95aad Administration: Introduce the `manage_posts_extra_tablenav` action, which fires inside the tablenav for the posts list table, and just outside the "actions" container.
Props hlashbrooke, wonderboymusic.
Fixes #30341.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35229 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 14:56:23 +00:00
Drew Jaynes 0aaa2900eb Docs: Add a version to the file header for wp-admin/includes/comment.php.
See #33701.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35228 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 14:34:25 +00:00
Ella Iseulde Van Dorpe 9845e08340 TinyMCE: Drag and drop link with image
Make sure images don't loose their link after drag and drop.

Fixes #28272.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35227 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 11:05:23 +00:00
John Blackbourn 532e1fb856 Some cleanup that was missed in [35259].
See #33728, #24853

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


git-svn-id: http://core.svn.wordpress.org/trunk@35226 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 06:26:24 +00:00
John Blackbourn 46a191dfcc Some rewrite endpoint tests in preparation for new endpoint masks. More to come.
See #33728, #24853

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


git-svn-id: http://core.svn.wordpress.org/trunk@35225 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 06:24:24 +00:00
John Blackbourn 9564ccf373 Preserve the public and private query var properties on the global `WP` instance when using `WP_UnitTestCase::go_to()`. These properties apply to the application state, not the current request.
See #34346

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


git-svn-id: http://core.svn.wordpress.org/trunk@35224 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 05:01:24 +00:00
John Blackbourn 53f5767ee1 Add `is_embed()` to `WP_UnitTestCase::assertQueryTrue()` and update the relevant embed tests.
See #32522

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


git-svn-id: http://core.svn.wordpress.org/trunk@35223 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 04:51:25 +00:00
John Blackbourn c01a64ad31 Move the `test_is_home_should_be_false_when_visiting_custom_endpoint_without_a_registered_query_var_and_page_on_front_is_set()` test into a more appropriate place.
See #25143

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


git-svn-id: http://core.svn.wordpress.org/trunk@35222 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 01:35:24 +00:00
John Blackbourn 0b845bed03 Correct a test after r35253.
See #34272

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


git-svn-id: http://core.svn.wordpress.org/trunk@35221 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 00:56:24 +00:00
John Blackbourn 9da3b964fc Remove an IDE-specific rule in `.gitignore`. These should be managed in the user's `~/.gitignore_global` file.
Fixes #34345

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


git-svn-id: http://core.svn.wordpress.org/trunk@35220 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-18 00:16:24 +00:00
Sergey Biryukov d76d340036 Embeds: After [35235], replace some missed `oembed` references with `embed`.
Props peterwilsoncc.
Fixes #34272.
Built from https://develop.svn.wordpress.org/trunk@35253


git-svn-id: http://core.svn.wordpress.org/trunk@35219 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 23:26:47 +00:00
John Blackbourn 5576cd3978 Introduce `map_deep()`, a utility function that recursively maps a callable function to every item in an array or object. Works like `array_walk_recursive()` but works with objects too.
Updates `rawurlencode_deep()`, `urlencode_deep()`, and `stripslashes_deep()` to use `map_deep()`. Introduces `urldecode_deep()` for completeness.

Props wpmuguru, nbachiyski, boonebgorges, MikeHansenMe, chriscct7, realloc, johnbillion
Fixes #22300

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


git-svn-id: http://core.svn.wordpress.org/trunk@35218 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 23:26:24 +00:00
Weston Ruter f676fdcee3 Customizer: Fix `margin-top` calculation for Themes section.
Ensure that the Themes section calculates its `margin-top` as a panel, since the section behaves as one. Fixes regression caused by [35231].

See #33567.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35217 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 22:41:25 +00:00
Scott Taylor 443ce28304 Media: in `wp_get_attachment_image_sizes()`, ensure that `$img_width` exists when the image does not.
Props kraftbj.
See #33641.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35216 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 22:12:24 +00:00
Scott Taylor c7b0db99a6 Unit Tests: better fixtures for `Tests_Meta_Slashes` and `Tests_WP_Customize_Section`.
See #30017, #33968.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35215 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 21:29:24 +00:00
Scott Taylor 11d1e8af8b Unit Tests: better fixtures for `Tests_User_WpSetCurrentUser`.
See #30017, #33968.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35214 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 21:19:24 +00:00
Scott Taylor 32bb609d88 Unit Tests: better fixtures for `Tests_User`.
See #30017, #33968.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35213 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 21:15:25 +00:00
Scott Taylor a9134691d4 Unit Tests: better fixtures for `Tests_AdminBar`. Don't force-delete some posts: some filter callbacks are no-ops on Multisite if the post is vanquished.
See #30017, #33968.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35212 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 20:49:24 +00:00
Scott Taylor 4204afdd40 Unit Tests: better fixtures for `Tests_Admin_Includes_Post`.
See #30017, #33968.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35211 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 19:48:23 +00:00
Scott Taylor d54f567862 Unit Tests: `WP_UnitTest_Generator_Sequence` needs a static incrementer - otherwise, it assumes every test class is a reset, which it no longer is (it is now static).
While we're at it, remove unnecessary `tearDown()` code.

See #30017, #33968.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35210 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 19:25:24 +00:00
Scott Taylor 7d7c85b83d Unit Tests: after [35242], declare some missing instance props on individual test classes.
See #30017, #33968.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35209 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 18:30:24 +00:00
Scott Taylor 7f8dca02b7 Unit Tests: after [35225], make `factory` a method/getter on `WP_UnitTestCase` and add magic methods for BC for every plugin that is extending `WP_UnitTestCase` and accessing the `$factory` instance prop.
Props nerrad, wonderboymusic.
See #30017, #33968.


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


git-svn-id: http://core.svn.wordpress.org/trunk@35208 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 18:03:25 +00:00
Drew Jaynes 8a386cb24f Docs: Add missing file headers to the list table classes and adjust class DocBlocks accordingly.
See #33701.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35207 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 15:13:25 +00:00
Drew Jaynes 767d091c74 Docs: Improve the hook doc for the `get_post_status` filter, introduced in [35233].
Also adds a missing parameter description for `$post`.

See #23458. See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35206 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 14:24:25 +00:00
Ella Iseulde Van Dorpe 08f71faac3 JSHint after [35238]
Built from https://develop.svn.wordpress.org/trunk@35239


git-svn-id: http://core.svn.wordpress.org/trunk@35205 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 07:11:24 +00:00
Ella Iseulde Van Dorpe 47e364de42 Admin: fix repositioning notices
Fixes #34294.
Props afercia.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35204 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 07:04:26 +00:00
Drew Jaynes 10d94ea673 Docs: Add a missing file header for wp-admin/includes/class-wp-list-table.php.
See #33701.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35203 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 06:07:24 +00:00
Weston Ruter c7a951194d Customizer: Add unit test for `WP_Customize_Widgets::is_panel_active()`.
See #33052.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35202 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 04:44:25 +00:00
Sergey Biryukov a908d2d4b1 Embeds: Rename files, functions, and hooks added in [34903] to make it more clear what is oEmbed-specific and what isn't.
See https://core.trac.wordpress.org/ticket/34272#comment:7 for full list of renamed functions and hooks.

Props swissspidy.
Fixes #34272.
Built from https://develop.svn.wordpress.org/trunk@35235


git-svn-id: http://core.svn.wordpress.org/trunk@35201 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 01:21:25 +00:00
Sergey Biryukov 1157540283 Replace Quick Edit and Bulk Edit headings with `<legend>` elements.
Props afercia.
Fixes #34289.
Built from https://develop.svn.wordpress.org/trunk@35234


git-svn-id: http://core.svn.wordpress.org/trunk@35200 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 00:45:25 +00:00
Aaron Jorbin b778726e74 Improve `get_post_permalink` compatibility with non standard post status
This adds a new filter named `get_post_status` to the function named `get_post_status` which can be used to make additional post types behave like unpublished post status in `get_post_permalink`.

Props misterbisson, antpb, iamfriendly
Fixes #23458


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


git-svn-id: http://core.svn.wordpress.org/trunk@35199 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 00:44:26 +00:00
Sergey Biryukov 7c2919c02b Merge two strings for expanding accordion and Customizer sections.
Props pavelevap.
Fixes #33939.
Built from https://develop.svn.wordpress.org/trunk@35232


git-svn-id: http://core.svn.wordpress.org/trunk@35198 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-17 00:28:25 +00:00
Weston Ruter 6bcd8ad757 Customizer: Always show Widgets panel initially if sidebars are registered; show notice to users in panel if no widget areas are in current preview.
Widgets panel will not wait to display until the preview loads.

Also fixes problems with `margin-top` in panels where other panels' `active` states change, as well as ensuring sections of deactivated panel collapse before panel is hidden to prevent the pane from becoming empty of controls.

Fixes #33052.
Fixes #33567.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35197 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-16 23:48:25 +00:00
Sergey Biryukov 5c8522c022 Merge two warning strings.
Props pavelevap.
Fixes #29740.
Built from https://develop.svn.wordpress.org/trunk@35230


git-svn-id: http://core.svn.wordpress.org/trunk@35196 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-16 23:31:25 +00:00
Sergey Biryukov f98136c1b5 Sample permalink: Improve accessibility of changing the permalink on Edit Post screen.
Props afercia.
Fixes #34255.
Built from https://develop.svn.wordpress.org/trunk@35229


git-svn-id: http://core.svn.wordpress.org/trunk@35195 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-16 23:02:25 +00:00
Sergey Biryukov ac630ba233 Embeds: In `print_oembed_embed_styles()`, load non-minified file if `SCRIPT_DEBUG` is true.
This is consistent with `print_oembed_embed_scripts()`.

Props MikeHansenMe.
Fixes #34321.
Built from https://develop.svn.wordpress.org/trunk@35228


git-svn-id: http://core.svn.wordpress.org/trunk@35194 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-16 22:43:24 +00:00
Boone Gorges 4430e5dbbb Return `null` from `get_term()` on taxonomy mismatch.
[34997] caused `get_term()` to return an error object in the case when
`$taxonomy` did not match the taxonomy of the located term. This was an
inadvertant change from the previous behavior, when `get_term()` would return
null in these cases.

Props dlh.
See #14162. Fixes #34332.
Built from https://develop.svn.wordpress.org/trunk@35227


git-svn-id: http://core.svn.wordpress.org/trunk@35193 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-16 21:42:25 +00:00
Scott Taylor efb224e831 Unit Tests: PHP 5.2, I Hate You and You Are Bringing Me Down.
#YOLOFriday

See #30017, #33968.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35192 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-16 21:15:25 +00:00