WordPress.org

Make WordPress Core

Changeset 44660


Ignore:
Timestamp:
01/21/2019 01:44:49 AM (6 months ago)
Author:
pento
Message:

Docs: Improve the docblocks for wp_insert_post() and wp_set_post_categories().

Their respective post_category and post_categories parameters were not correct.

Props Takahashi_Fumiki.
Fixes #45171.

File:
1 edited

Legend:

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

    r44636 r44660  
    33693369 *     @type string $post_mime_type        The mime type of the post. Default empty.
    33703370 *     @type string $guid                  Global Unique ID for referencing the post. Default empty.
    3371  *     @type array  $post_category         Array of category names, slugs, or IDs.
     3371 *     @type array  $post_category         Array of category IDs.
    33723372 *                                         Defaults to value of the 'default_category' option.
    33733373 *     @type array  $tags_input            Array of tag names, slugs, or IDs. Default empty.
     
    43824382 * @param int       $post_ID         Optional. The Post ID. Does not default to the ID
    43834383 *                                   of the global $post. Default 0.
    4384  * @param array|int $post_categories Optional. List of categories or ID of category.
     4384 * @param array|int $post_categories Optional. List of category IDs, or the ID of a single category.
    43854385 *                                   Default empty array.
    4386  * @param bool      $append         If true, don't delete existing categories, just add on.
    4387  *                                  If false, replace the categories with the new categories.
     4386 * @param bool      $append          If true, don't delete existing categories, just add on.
     4387 *                                   If false, replace the categories with the new categories.
    43884388 * @return array|false|WP_Error Array of term taxonomy IDs of affected categories. WP_Error or false on failure.
    43894389 */
Note: See TracChangeset for help on using the changeset viewer.