Commit Graph

9808 Commits

Author SHA1 Message Date
John Blackbourn
db4f746b4a Docs: Improve documentation of known return types, plus other docs fixes.
See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46660 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-05 21:21:46 +00:00
Jorge Costa
4cee80b682 Block Editor: Bug fixes targeted for WordPress 5.3 RC4.
The list of included fixes is:

https://github.com/WordPress/gutenberg/pull/18183
https://github.com/WordPress/gutenberg/pull/18194
https://github.com/WordPress/gutenberg/pull/18230
https://github.com/WordPress/gutenberg/pull/18275
https://github.com/WordPress/gutenberg/pull/18287

Updated packages:
 - @wordpress/block-editor@3.2.4
 - @wordpress/block-library@2.9.5
 - @wordpress/edit-post@3.8.5
 - @wordpress/editor@9.7.5
 - @wordpress/format-library@1.9.4

Props @aduth, @mcsf, @youknowriad, @johnbillion.
Fixes #48502.

git-svn-id: https://develop.svn.wordpress.org/trunk@46656 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-05 19:34:07 +00:00
Jake Spurlock
969285d54b REST API: Fix for Yoda condition.
Little coding standards fix for the REST API.

Props mukesh27, spenserhale.

Fixes #48337.


git-svn-id: https://develop.svn.wordpress.org/trunk@46654 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-05 17:36:31 +00:00
John Blackbourn
f6cb28a6a2 Docs: Correct and improve the readability of some parameters of WP_Term_Query.
See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46652 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-04 17:48:55 +00:00
Sergey Biryukov
c231bb4869 Build/Test Tools: Adjust the test for wp_redirect() status codes added in [46641] per the documentation and coding standards.
Move the test to a more appropriate place for consistency with `wp_sanitize_redirect()` and `wp_validate_redirect()` tests.

See #44317.

git-svn-id: https://develop.svn.wordpress.org/trunk@46649 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-04 12:57:17 +00:00
Sergey Biryukov
ec5f1035fe Docs: Correct some array hash notations added in [46644].
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@46647 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-04 09:35:59 +00:00
Timothy Jacobs
a104c82526 REST API: Add tax relation parameter to posts collection.
The REST API supports filtering by terms across multiple taxonomies using an AND relation. This adds support for an OR relation by adding "tax_relation=OR" as a query parameter.

Props earnjam.
Fixes #44326.


git-svn-id: https://develop.svn.wordpress.org/trunk@46646 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-03 23:12:44 +00:00
John Blackbourn
27b67d5624 Docs: Fix some incorrect return tags in docblocks.
See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46644 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-03 22:21:20 +00:00
Jake Spurlock
922721c360 Toolbar: Use add_node() instead of add_menu() in core.
This patch replaces all references to the add_menu() method with the add_node() one. (Also some code structure modifications for wp_admin_bar_appearance_menu().)

Fixes: #19647
Props: linuxologos, paulschreiber, morganestes, akibjorklund, nacin, whyisjake.


git-svn-id: https://develop.svn.wordpress.org/trunk@46642 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-03 22:12:32 +00:00
Aaron Jorbin
40946e984a General: wp_safe_redirect() and wp_redirect() shouldn't allow non-3xx status codes
Redirects should use redirect status codes and if you attempt to call wp_safe_redirect or wp_redirect with a non redirect status it can lead to undesired behavior and head scratching.

Fixes #44317.
Props spenserhale, johnbillion, mjnewman for initial patch.



git-svn-id: https://develop.svn.wordpress.org/trunk@46641 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-03 22:08:56 +00:00
Jake Spurlock
84c794ba41 Login and Registration: Allow email logins to be more flexible.
Allows a login to have an apostorphe. Which would normally be created as a mistake, but this allows the login to happen.

Fixes #38744
Props wpkuf, desrosj, socalchristina, bibliofille, santilinwp, nsubugak, sncoker, cafenoirdesign, whyisjake.



git-svn-id: https://develop.svn.wordpress.org/trunk@46640 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-03 20:10:23 +00:00
Jonathan Desrosiers
9d88dbac58 External Libraries: Revert [46634-46635].
On further investigation, Plupload changed it’s license to a non-GPL compatible license. The newest, GPL compatible version is being used already in Core.

Unprops desrosj.
See #48277.

git-svn-id: https://develop.svn.wordpress.org/trunk@46638 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-03 17:07:42 +00:00
Jonathan Desrosiers
6d413590b7 Customize: Formally deprecate unused Customizer classes.
The `WP_Customize_New_Menu_Control` and `WP_Customize_New_Menu_Section` PHP classes and `wp.customize.Menus.NewMenuControl` JS class were deprecated in 4.9 through [42034] with the intention of removing them in 5.0. Since more time has passed than originally intended, this change leaves `WP_Customize_New_Menu_Control` and `WP_Customize_New_Menu_Section` to prevent any potential backwards compatibility issues, and formally deprecates them. The `wp.customize.Menus.NewMenuControl` JS class is removed.

Props weston.ruter, matthias-reuter, jrf.
Fixes #42364.

git-svn-id: https://develop.svn.wordpress.org/trunk@46637 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-03 16:46:55 +00:00
Jonathan Desrosiers
669e701a5b External Libraries: Update Plupload from 2.1.9 to 2.3.6.
This change also updates the MoxieJS dependency from 1.3.5 to 1.5.7, converts Plupload to a dependency in NPM, and integrates all relevant parts into the build process.

For a full list of upstream changes, see https://github.com/moxiecode/plupload/compare/v2.1.9...v2.3.6.

Props desrosj, hareesh-pillai.
Fixes #48277.

git-svn-id: https://develop.svn.wordpress.org/trunk@46634 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-03 15:29:46 +00:00
Sergey Biryukov
b0cdad744b General: Wrap the error message in _deprecated_constructor() in <code> tags instead of <pre>.
Props aftabmuni.
Fixes #48483.

git-svn-id: https://develop.svn.wordpress.org/trunk@46633 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-03 10:54:39 +00:00
Sergey Biryukov
358364e1ca Code Modernization: Call PHP 5 constructors in methods extending POMO_Reader.
Follow-up to [46629].

See #48252.

git-svn-id: https://develop.svn.wordpress.org/trunk@46632 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-02 20:47:44 +00:00
Sergey Biryukov
74795ca384 Docs: Correct version number in @deprecated tags for PHP 4 constructors in pomo/entry.php and pomo/streams.php.
Follow-up to [46629].

Props jrf.
See #48252.

git-svn-id: https://develop.svn.wordpress.org/trunk@46631 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-02 20:28:31 +00:00
Sergey Biryukov
d3f486ed3f Docs: Correct @see references for PHP 4 constructors in wp-includes/class-json.php.
See #48252, #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@46630 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-02 20:11:20 +00:00
Sergey Biryukov
168bb48084 Docs: Add missing @deprecated tags to PHP 4 constructors in pomo/entry.php and pomo/streams.php.
Props jrf.
Fixes #48252.

git-svn-id: https://develop.svn.wordpress.org/trunk@46629 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-02 20:09:35 +00:00
Sergey Biryukov
dcced77dbb Docs: Add missing @deprecated tags to PHP 4 constructors in WP_Widget and WP_Widget_Factory().
Correct version number in `_deprecated_constructor()` call in `WP_Widget_Factory()`, see [32990].

Props jrf.
See #48252.

git-svn-id: https://develop.svn.wordpress.org/trunk@46627 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-02 20:04:27 +00:00
Sergey Biryukov
00384f94db Docs: Update URLs in some @link tags and switch them to HTTPS.
Props tsuyoring.
Fixes #48479.

git-svn-id: https://develop.svn.wordpress.org/trunk@46626 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-01 14:55:51 +00:00
Sergey Biryukov
89621877f8 Code Modernization: Pass an appropriate error level to trigger_error() in _doing_it_wrong() and related functions:
* `_deprecated_function()`
* `_deprecated_argument()`
* `_deprecated_constructor()`
* `_deprecated_file()`

The error level passed is `E_USER_DEPRECATED` for the deprecated function group and `E_USER_NOTICE` for `_doing_it_wrong()`.

Props jrf.
Fixes #36561.

git-svn-id: https://develop.svn.wordpress.org/trunk@46625 602fd350-edb4-49c9-b593-d223f7449a82
2019-11-01 00:39:04 +00:00
johnbillion
3623ab0ad8 Docs: Correct some more invalid inline docs.
See https://make.wordpress.org/core/handbook/best-practices/inline-documentation-standards/php/#summary-formerly-short-description

See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46624 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-31 21:18:01 +00:00
John Blackbourn
c6c46a5a48 Docs: Miscellaneous docblock corrections.
See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46610 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-28 19:46:13 +00:00
John Blackbourn
38dd307f5a Docs: Coding standards fix after [46608].
See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46609 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-28 19:33:24 +00:00
John Blackbourn
0cd24d5c60 Docs: Remove some funky nested filters.
See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46608 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-28 19:02:31 +00:00
Sergey Biryukov
7548aa86ba Docs: Restore correct placement for duplicate hook reference in render_block_core_latest_comments().
Previously fixed in [46604], accidentally reverted in [46606].

See #48447, #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@46607 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-28 15:15:51 +00:00
Riad Benguella
6352823e6e Block Editor: Bug fixes targetted for WordPress 5.3 RC3.
The list of included fixes is:

- https://github.com/WordPress/gutenberg/pull/18108
- https://github.com/WordPress/gutenberg/pull/18051
- https://github.com/WordPress/gutenberg/pull/18106
- https://github.com/WordPress/gutenberg/pull/18102

Updated packages:
 - @wordpress/api-fetch@3.6.4
 - @wordpress/block-directory@1.0.4
 - @wordpress/block-library@2.9.4
 - @wordpress/core-data@2.7.4
 - @wordpress/data-controls@1.3.4
 - @wordpress/edit-post@3.8.4
 - @wordpress/editor@9.7.4
 - @wordpress/list-reusable-blocks@1.8.4
 - @wordpress/media-utils@1.2.4
 - @wordpress/server-side-render@1.3.4

Props desrosj.
See #48447.


git-svn-id: https://develop.svn.wordpress.org/trunk@46606 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-28 14:11:06 +00:00
John Blackbourn
8c21607a97 Docs: Correct invalid hook docblock placement.
See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46604 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-27 19:33:12 +00:00
John Blackbourn
b422cc2ef6 Docs: Correct invalid hook docblocks.
See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46603 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-27 19:09:10 +00:00
Sergey Biryukov
6ac79feeeb Docs: Remove "private" designation from _doing_it_wrong() and related functions:
* `_deprecated_function()`
* `_deprecated_argument()`
* `_deprecated_constructor()`
* `_deprecated_file()`

Plugins and themes should be allowed to use these functions to throw appropriate error notices.

This brings them in line with newer `do_action_deprecated()` and `apply_filters_deprecated()` functions, which are not marked as private.

Props jrf.
Fixes #48251.

git-svn-id: https://develop.svn.wordpress.org/trunk@46602 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-27 14:19:13 +00:00
Sergey Biryukov
f06419d070 Editor: Fix typo in an error message in WP_Block_Styles_Registry::register().
Props man4toman, alishankhan, shaampk1.
Fixes #48437.

git-svn-id: https://develop.svn.wordpress.org/trunk@46601 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-27 14:06:04 +00:00
Sergey Biryukov
fa02b8917e Docs: Improve DocBlock formatting in WP_Block_Styles_Registry per the documentation standards.
See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@46600 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-27 14:05:18 +00:00
John Blackbourn
1ec1c5872b Docs: Correct and improve inline docs for the file type functions.
See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46599 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-26 23:47:04 +00:00
John Blackbourn
e228178d1b Docs: Add missing docs for the auth_cookie_bad_session_token action.
See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46598 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-26 23:44:02 +00:00
John Blackbourn
4f281f1650 Docs: Switch more docs over to typed array notation, plus some fixes.
See #48303, #41756


git-svn-id: https://develop.svn.wordpress.org/trunk@46596 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-26 21:07:10 +00:00
John Blackbourn
e07cf22fd0 Docs: Switch to typed array notation for the docs for asset dependency functions.
Props marekdedic

See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46595 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-26 21:00:08 +00:00
John Blackbourn
a2e08032dc Docs: Miscellaneous docblock fixes and improvements.
See #48303


git-svn-id: https://develop.svn.wordpress.org/trunk@46594 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-26 20:42:00 +00:00
Sergey Biryukov
c951d94c72 Docs: Improve documentation for esc_attr_e(), esc_html_e(), esc_attr_x(), esc_html_x().
Props atachibana.
Fixes #48383.

git-svn-id: https://develop.svn.wordpress.org/trunk@46593 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-26 17:28:20 +00:00
Sergey Biryukov
e2c34a76f9 Docs: Improve documentation for wptexturize().
Props atachibana.
Fixes #48397.

git-svn-id: https://develop.svn.wordpress.org/trunk@46592 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-26 00:56:50 +00:00
Jonathan Desrosiers
10c787f0ca Ensure svn:eol-style is consistently set for all files (part 2).
Continuation of [46586]

See #42594.

git-svn-id: https://develop.svn.wordpress.org/trunk@46587 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-25 19:27:49 +00:00
Jonathan Desrosiers
4b1dd6e549 Trunk is now 5.4 alpha.
git-svn-id: https://develop.svn.wordpress.org/trunk@46582 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-25 14:22:40 +00:00
Sergey Biryukov
c67b47c66e Date/Time: Make sure get_post_time() keeps UTC time on timezone change.
Add `$source` parameter to `get_post_datetime()` to instantiate from local or UTC time in database.

Props Rarst, david.binda.
Reviewed by azaozz, SergeyBiryukov.
Fixes #48384.

git-svn-id: https://develop.svn.wordpress.org/trunk@46580 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-25 13:06:29 +00:00
Sergey Biryukov
38b4ecf2ed Date/Time: Make sure date_i18n() correctly handles zero timestamp after [45901].
Props soulseekah, gravityview, Rarst.
Reviewed by azaozz, SergeyBiryukov.
Fixes #28636.

git-svn-id: https://develop.svn.wordpress.org/trunk@46577 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-25 11:03:13 +00:00
Jonathan Desrosiers
aa34f0d952 Post WordPress 5.3 RC2 version bump.
git-svn-id: https://develop.svn.wordpress.org/trunk@46574 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-22 20:09:15 +00:00
Jonathan Desrosiers
1b411f9e05 WordPress 5.3 RC2.
git-svn-id: https://develop.svn.wordpress.org/trunk@46573 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-22 19:43:01 +00:00
SergeyBiryukov
747f8e2186 Date/Time: Make sure wp_date() does not unnecessarily escape localized numbers, but keeps localized slashes.
Props Rarst, tmatsuur, remcotolsma, peterwilsoncc.
Reviewed by peterwilsoncc.
Fixes #48319.

git-svn-id: https://develop.svn.wordpress.org/trunk@46569 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-22 17:29:02 +00:00
Sergey Biryukov
99d5986b0c Plugins: Restore backward compatibility for PHP4-style passing of array( &$this ) as action argument to do_action().
This is a follow-up to [46149] to avoid unnecessary breakage in case of using the old notation.

Props david.binda, jrf.
Reviewed by azaozz.
Fixes #48312.

git-svn-id: https://develop.svn.wordpress.org/trunk@46568 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-22 00:09:39 +00:00
Andrew Ozz
67a937a2fd Media: After [46237] add the same fix to the .button-group on the "Insert form URL" screen in the media modal.
Props afercia, sabernhardt.
FIxes #48087.

git-svn-id: https://develop.svn.wordpress.org/trunk@46567 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-21 23:21:51 +00:00
Sergey Biryukov
1f7f0a1357 Comments: Add rel="nofollow ugc" attribute when converting plain URLs to <a> tags in comments via make_clickable().
Introduce `make_clickable_rel` filter for the `rel` value that is added to URL matches converted to links.

This is a follow-up to [46349], which added the `rel="nofollow ugc"` attribute to existing `<a>` tags in comments via `wp_rel_ugc()`.

UGC stands for User Generated Content, and the `ugc` attribute value is recommended for links within user generated content, such as comments and forum posts.

See https://webmasters.googleblog.com/2019/09/evolving-nofollow-new-ways-to-identify.html.

Props blogginglife, SergeyBiryukov.
Reviewed by desrosj, audrasjb.
Fixes #48022.

git-svn-id: https://develop.svn.wordpress.org/trunk@46564 602fd350-edb4-49c9-b593-d223f7449a82
2019-10-21 20:39:16 +00:00