Make WordPress Core

Changeset 37686


Ignore:
Timestamp:
06/11/2016 05:07:35 PM (9 years ago)
Author:
DrewAPicture
Message:

Docs: Improve the return description for wp_get_post_categories() to include more information about possible return values.

Props jeherve for the initial patch.
Fixes #37002.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/post.php

    r37544 r37686  
    28542854 * @param int   $post_id Optional. The Post ID. Does not default to the ID of the
    28552855 *                       global $post. Default 0.
    2856  * @param array $args    Optional. Category arguments. Default empty.
    2857  * @return array List of categories.
     2856 * @param array $args    Optional. Category arguments. See wp_get_object_terms(). Default empty.
     2857 * @return array List of categories. If the `$fields` argument passed via `$args` is 'all' or
     2858 *               'all_with_object_id', an array of WP_Term objects will be returned. If `$fields`
     2859 *               is 'ids', an array of category ids. If `$fields` is 'names', an array of category names.
    28582860 */
    28592861function wp_get_post_categories( $post_id = 0, $args = array() ) {
Note: See TracChangeset for help on using the changeset viewer.