Commit Graph

36890 Commits

Author SHA1 Message Date
Drew Jaynes a3fb39bc51 Docs: Add full documentation for members in the labels object returned by get_taxonomy_labels().
Props truongwp.
Fixes #41108.


git-svn-id: https://develop.svn.wordpress.org/trunk@40944 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 21:41:09 +00:00
Drew Jaynes 42801d8896 Docs: Add a note to the DocBlock for `wp_signon()` mentioning that it doesn't handle setting the current user.
Also outlines the conditions that must be met for is_user_logged_in() to work with it.

Part props SergeyBiryukov.
Fixes #28116.


git-svn-id: https://develop.svn.wordpress.org/trunk@40943 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 20:07:08 +00:00
Drew Jaynes 9b91a663df Docs: Add full documentation for arguments accepted by `wp_get_nav_menu_items()`.
Also provide differentiation between arguments as passed to `get_posts()` vs used for ordering outputted menu items.

By and large, arguments in the `$args` array are intended to directly affect how nav_menu_item posts are retrieved. When the default ARRAY_A is used for 'output', the 'order' and 'orderby' arguments are essentially ignored, instead giving preference to a hard-coded order of 'ASC' and an orderby value derived from the non-get_posts() argument 'output_key'.

Fixes #15533.


git-svn-id: https://develop.svn.wordpress.org/trunk@40942 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 19:36:45 +00:00
Weston Ruter f25d9d7909 Widgets: Add accessibility mode support for TinyMCE-enhanced Text and Media widgets (Video, Audio, Images).
Amends [40640], [40631].
Props westonruter, afercia.
See #35243, #32417.
Fixes #40986.


git-svn-id: https://develop.svn.wordpress.org/trunk@40941 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 18:47:13 +00:00
John Blackbourn d7fc80ca43 Users: Use more appropriate HTTP status codes for errors relating to user management.
Also re-uses one error message string.

Props tuanmh

Fixes #40230


git-svn-id: https://develop.svn.wordpress.org/trunk@40940 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 18:45:33 +00:00
Weston Ruter 01efaabfc5 Widgets: Forcibly limit Video widget to only accept oEmbed URLs from YouTube and Vimeo (for now).
Amends [40640].
Props timmydcrawford.
See #34115, #39994.
Fixes #40935.


git-svn-id: https://develop.svn.wordpress.org/trunk@40939 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 07:23:52 +00:00
Drew Jaynes ea1ee4f313 Scripts: Correctly reference `WP_Scripts::print_extra_script()` as the replacement for the deprecated `WP_Scripts::print_scripts_l10n()` method, rather than a nonexistent global print_extra_script() function.
Props fergbrain.
See #41121.


git-svn-id: https://develop.svn.wordpress.org/trunk@40938 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 07:19:23 +00:00
Drew Jaynes a6b883434b Docs: Fix alignment of the `$output` parameter in the hook doc for the `do_shortcode_tag` filter.
See #41017.


git-svn-id: https://develop.svn.wordpress.org/trunk@40937 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 07:04:22 +00:00
Peter Wilson ddbee256ad Emoji: Fix typo in `browserSupportsEmoji()` comment.
Fairies not Faries, introduced in [40850].

Fixes #41157.



git-svn-id: https://develop.svn.wordpress.org/trunk@40936 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 07:04:20 +00:00
Weston Ruter 51be161019 Customize: Ensure `header_image_data` setting exists before attempting to use it.
Amends [27497].
Props Collizo4sky.
Fixes #41007.


git-svn-id: https://develop.svn.wordpress.org/trunk@40935 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 07:03:16 +00:00
Sergey Biryukov 84fa8a9ff1 Docs: Add a missing quote in `user-agent` argument description in `WP_Http::request()`.
Props ixkaito.
Fixes #41154.

git-svn-id: https://develop.svn.wordpress.org/trunk@40934 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 06:59:41 +00:00
Drew Jaynes 2a6d816739 Docs: Improve description wording for `get_template_part()` in regard to overloading by child themes.
Also, update the summary to use a third-person singular verb.

Props ixmati.
See #41017.


git-svn-id: https://develop.svn.wordpress.org/trunk@40933 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 06:55:43 +00:00
Drew Jaynes 1883d96173 Docs: Clarify the description for `esc_html__()` to note that the original text will be escaped on return if there is no translation, or the text domain isn't loaded.
Props brianlayman.
See #41017.


git-svn-id: https://develop.svn.wordpress.org/trunk@40932 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 06:40:39 +00:00
Drew Jaynes 805f4464a4 Docs: Fix a typo in the description for the `get_previous_post_link()` `$link` parameter. The default value is '%title', not '%title%'.
Props kmgalanakis.
See #41017.


git-svn-id: https://develop.svn.wordpress.org/trunk@40931 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 06:19:24 +00:00
Drew Jaynes f8788a84a2 Docs: Add more complete documentation about expected values in the `$meta` parameter for `wpmu_create_blog()`.
See #41017.


git-svn-id: https://develop.svn.wordpress.org/trunk@40930 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 05:47:27 +00:00
Drew Jaynes f6399c9950 Improve the usefulness of several `_deprecated_function()` calls by passing known replacement functions, methods, or hooks.
Props jrf.
See #41121.


git-svn-id: https://develop.svn.wordpress.org/trunk@40929 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-25 00:04:11 +00:00
Sergey Biryukov c9539e5a3c Import: Increase color contrast for "This importer is not installed" message on Multisite.
Remove `.not-installed-main-site` class introduced in [38075], but never used.

Props nishitlangaliya, mbootsman.
Fixes #41117.

git-svn-id: https://develop.svn.wordpress.org/trunk@40928 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-24 18:06:43 +00:00
Andrew Ozz 31fa66e976 TinyMCE: fix directionality settings for RTL languages.
Props westonruter, sa3idho.
Fixes #40972 for trunk.

git-svn-id: https://develop.svn.wordpress.org/trunk@40927 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-24 09:18:21 +00:00
Weston Ruter d29e68fbda Widgets: Rename "HTML Code" widget to "Custom HTML" widget.
Correspondingly renames files, ID base from `html_code` to `custom_html`, and the filter from `widget_html_code_content` to `widget_custom_html_content`.

See #40907.


git-svn-id: https://develop.svn.wordpress.org/trunk@40926 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-23 23:59:23 +00:00
Sergey Biryukov c1ff9b62f7 Docs: Document `tags_input` parameter in `wp_insert_post()`.
Props barryceelen.
Fixes #41137.

git-svn-id: https://develop.svn.wordpress.org/trunk@40925 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-23 21:26:13 +00:00
Boone Gorges 50de2303b0 When querying for terms, do not assume that `$taxonomies` is a 0-indexed array.
In [25108], the logic of term queries was modified to avoid assuming
that the `taxonomies` array was numerically indexed. See #23506. This
fix was inadvertantly reverted during the refactor in [25162].

Props david.binda.
Fixes #41113.

git-svn-id: https://develop.svn.wordpress.org/trunk@40924 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-23 02:05:19 +00:00
Boone Gorges bb0354dda1 Introduce `loop_no_results` action.
This action fires when a `WP_Query` query returns no results.

Props mgibbs189.
Props #40850.

git-svn-id: https://develop.svn.wordpress.org/trunk@40923 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-23 01:54:59 +00:00
Drew Jaynes c321e10c16 Docs: Standardize and add missing deprecation notations in DocBlocks for the following functions:
* `post_form_autocomplete_off()`
* `_rotate_image_resource()`
* `_flip_image_resource()`
* `wp_get_sites()`
* `deactivate_sitewide_plugin()`

Props jrf.
See #41121.


git-svn-id: https://develop.svn.wordpress.org/trunk@40922 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-22 17:47:47 +00:00
Boone Gorges ddc823a3e9 Cache results in `get_objects_in_term()`.
This helps to reduce database queries when generating nav menus.

Props spacedmonkey.
Fixes #37094.

git-svn-id: https://develop.svn.wordpress.org/trunk@40921 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-22 03:18:18 +00:00
Boone Gorges 7104971dca Improve cache invalidation when splitting shared terms.
This changeset addresses two related issues:

* When splitting shared terms from hierarchical taxonomies, the process of regenerating the taxonomy hierarchy (`_get_taxonomy_hierarchy()`) requires recursive calls to `get_terms()` in order to descend the tree. By waiting until all shared terms in a term group have been invalidated before regenerating their taxonomy hierarchies, we avoid certain race conditions.
* Previously, a coding error prevented single-term caches from being invalidated for children of split terms. This error dates from [31418].

See #37189.

git-svn-id: https://develop.svn.wordpress.org/trunk@40920 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-21 04:11:58 +00:00
Boone Gorges a529129de5 Introduce `clean_taxonomy_cache()` function.
Previously, taxonomy-wide caches were cleaned only inside of
`clean_term_cache()`. This made it hard to clean taxonmy caches
in isolation from specific taxonomy terms.

Props spacedmonkey.
See #37189.

git-svn-id: https://develop.svn.wordpress.org/trunk@40919 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-21 04:03:22 +00:00
Boone Gorges deae2f7cbf Use `WP_Term_Query` when transforming tax queries.
This change allows tax query transformations to be cached.

Props spacedmonkey.
Fixes #37038.

git-svn-id: https://develop.svn.wordpress.org/trunk@40918 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-21 03:56:25 +00:00
Sergey Biryukov 9d64fe2172 Docs: Add missing `@param` and `@return` descriptions for `has_term_meta()`, `wp_delete_category()`, and `wp_term_is_shared()`.
Props keesiemeijer.
Fixes #41096.

git-svn-id: https://develop.svn.wordpress.org/trunk@40917 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-20 18:27:53 +00:00
Boone Gorges 03cd8d5b70 Add term meta support to XML-RPC `addTerm` and `editTerm` endpoints.
This changeset also includes the new function `has_term_meta()`, a
counterpart to `has_meta()` (for posts).

Props enrico.sorcinelli.
Fixes #35991.

git-svn-id: https://develop.svn.wordpress.org/trunk@40916 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-18 10:39:12 +00:00
Peter Wilson 21e3c92742 Docs: Add `wp-admin/js/media.js` documentation.
Props jipmoors, jjcomack, diedeexterkate.
Fixes #41072.


git-svn-id: https://develop.svn.wordpress.org/trunk@40915 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 15:36:20 +00:00
Peter Wilson d87ccc1655 Docs: Add `wp-admin/js/custom-background.js` documentation.
Props jipmoors.
Fixes #41067.


git-svn-id: https://develop.svn.wordpress.org/trunk@40914 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 13:23:22 +00:00
Sergey Biryukov 2de1815a16 Docs: Add documentation for `wp-admin/js/comment.js`.
Props ireneyoast, andizer, jipmoors.
Fixes #41065.

git-svn-id: https://develop.svn.wordpress.org/trunk@40913 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 13:01:30 +00:00
Sergey Biryukov 280a9b61f0 Docs: Correct parameter description for `posts_join` filter.
Props anhskohbo.
Fixes #40991.

git-svn-id: https://develop.svn.wordpress.org/trunk@40912 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 12:45:05 +00:00
Sergey Biryukov cf9d667583 I18N: Add `@global` entry for `$wp_locale` in `wp_maybe_decline_date()`.
Props Dency.
Fixes #41046.

git-svn-id: https://develop.svn.wordpress.org/trunk@40911 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 12:23:55 +00:00
Sergey Biryukov 9338781b41 Editor: Correct `$settings` parameter description in `_WP_Editors::editor()`.
Props truongwp.
Fixes #40963.

git-svn-id: https://develop.svn.wordpress.org/trunk@40910 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 12:18:08 +00:00
Sergey Biryukov 01e2b8b1e2 I18N: Correct translator comment for response error message in `WP_Community_Events::get_events()`.
Props Soean, tfirdaus.
Fixes #40939.

git-svn-id: https://develop.svn.wordpress.org/trunk@40909 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 12:06:06 +00:00
Sergey Biryukov c40cbe75de Twenty Sixteen: Allow category display in post preview even when there is only one category.
Props lancewillett, davidakennedy.
Fixes #39531.

git-svn-id: https://develop.svn.wordpress.org/trunk@40908 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 12:05:09 +00:00
John Blackbourn 5d13bdd1ef General: Introduce a `wp_is_mobile` filter for controlling whether a request should be treated as coming from a mobile device.
Props PressLabs

Fixes #41023


git-svn-id: https://develop.svn.wordpress.org/trunk@40907 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 12:04:56 +00:00
John Blackbourn b20ed14939 Database: Add documentation for the allowed `utf8mb4_520` value when detecting features with `wpdb::has_cap()`.
Props rcutmore

Fixes #41044


git-svn-id: https://develop.svn.wordpress.org/trunk@40906 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 11:59:19 +00:00
Sergey Biryukov d4949e31be I18N: Add context for News blog URL in 'WordPress Events and News' dashboard widget.
Props zodiac1978.
Fixes #40929.

git-svn-id: https://develop.svn.wordpress.org/trunk@40905 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 11:51:39 +00:00
Dominik Schilling (ocean90) 93e549f03f Twenty Seventeen: Remove/merge unused variables in content-front-page.php.
#wceu2017

Props dingo_bastard, mariusvetrici.
Fixes #39771.

git-svn-id: https://develop.svn.wordpress.org/trunk@40904 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 10:19:06 +00:00
Boone Gorges f239e62722 Simplify documentation for `wp_dropdown_categories()`.
Props ArnaudBan.
Fixes #41058.

git-svn-id: https://develop.svn.wordpress.org/trunk@40903 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 09:38:30 +00:00
Adam Silverstein b13ab6b4a3 Media: Disable the edit image->replace button when no item selected.
On the edit media screen, ensure that the 'replace' button is disabled until a media item is selected. Fix an issue where clicking the button with no item selected threw a JavaScript error and failed to work.

Props timmydcrawford, subrataemfluence, psiico.
Fixes #40589.



git-svn-id: https://develop.svn.wordpress.org/trunk@40902 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 09:37:53 +00:00
Pascal Birchler e67238f480 Embeds: Update oEmbed endpoint URL for VideoPress.
Props NomNom99.
Fixes #41019.

git-svn-id: https://develop.svn.wordpress.org/trunk@40901 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-15 05:37:51 +00:00
Drew Jaynes 7ecfb17115 Docs: Include 'parent' as an acceptable entry for the `$orderby` argument in `WP_Term_Query`.
h/t kalor.
See #41017.


git-svn-id: https://develop.svn.wordpress.org/trunk@40900 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-13 03:10:29 +00:00
Drew Jaynes 5741c2f6c1 Docs: Clarify that `get_the_author_meta()` can also return an empty string.
h/t aurovrata.
See #41017


git-svn-id: https://develop.svn.wordpress.org/trunk@40899 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-13 02:32:15 +00:00
Drew Jaynes 9b90187611 Docs: Correct a typo in the `sort_column` argument description for `wp_page_menu()`.
h/t spacegrrl.
See #41017.


git-svn-id: https://develop.svn.wordpress.org/trunk@40898 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-13 01:10:23 +00:00
Andrea Fercia 63731a6923 Accessibility: Avoid a keyboard trap on the permalink custom structure setting.
Using the `focus` event on the permalink custom structure field made impossible
to navigate through all the form fields using only the keyboard without actually
selecting the custom structure setting. Instead, using click and input preserves
the original functionality when using any kind of pointing or input device.

Also changes `attr()` to `prop()`` as recommended for a `checked` property.

Fixes #40982.


git-svn-id: https://develop.svn.wordpress.org/trunk@40897 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-12 14:08:34 +00:00
Weston Ruter 662824ceac Customize: Restore right border on footer actions.
Fixes regression introduced in [40511].

Props timmydcrawford.
See #32296.
Fixes #40978.


git-svn-id: https://develop.svn.wordpress.org/trunk@40896 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-12 00:16:03 +00:00
Sergey Biryukov ef2789b737 Docs: Remove duplicate `@return` keyword in `WP_Community_Events::get_request_args`.
Props ketuchetan.
Fixes #40973.

git-svn-id: https://develop.svn.wordpress.org/trunk@40895 602fd350-edb4-49c9-b593-d223f7449a82
2017-06-11 11:09:21 +00:00