WordPress.org

Make WordPress Core

Opened 4 months ago

Last modified 4 months ago

#53467 new enhancement

Correct and standardise the meta query documentation

Reported by: johnbillion Owned by:
Milestone: 5.9 Priority: normal
Severity: normal Version:
Component: Query Keywords: has-patch dev-feedback
Focuses: docs Cc:

Description

The following query classes all support meta_* arguments because they pass their arguments onto WP_Meta_Query, however their documentation is inconsistent, incomplete, and in some cases incorrect.

  • WP_Comment_Query
  • WP_Query
  • WP_Site_Query
  • WP_Term_Query
  • WP_User_Query

Notably, WP_Query documents a meta_value_num argument which does not exist. This was erroneously introduced in [28887]. meta_value_num is an allowed value for orderby arguments, but is not the name of an argument itself.

Let's standardise the documentation and guide users to WP_Meta_Query for the canonical documentation.

Change History (4)

This ticket was mentioned in PR #1399 on WordPress/wordpress-develop by johnbillion.


4 months ago

  • Keywords has-patch added

#2 @johnbillion
4 months ago

  • Keywords dev-feedback added

#3 @SergeyBiryukov
4 months ago

  • Component changed from General to Query

#4 @desrosj
4 months ago

  • Milestone changed from Awaiting Review to 5.9
Note: See TracTickets for help on using tickets.