WordPress.org

Make WordPress Core

Changeset 47157


Ignore:
Timestamp:
02/01/2020 09:59:14 PM (22 months ago)
Author:
SergeyBiryukov
Message:

Docs: Correct DocBlock formatting for register_setting().

Document the full list of whitelisted option key names.

See #48303.

Location:
trunk/src
Files:
4 edited

Legend:

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

    r47084 r47157  
    161161 *
    162162 * @param string $option_group A settings group name. Should correspond to a whitelisted option key name.
    163  *  Default whitelisted option key names include "general," "discussion," and "reading," among others.
     163 *                             Default whitelisted option key names include 'general', 'discussion', 'media',
     164 *                             'reading', 'writing', 'misc', 'options', and 'privacy'.
    164165 * @param string $option_name The name of an option to sanitize and save.
    165166 * @param callable $sanitize_callback A callback function that sanitizes the option's value.
  • trunk/src/wp-admin/options.php

    r47156 r47157  
    197197
    198198/**
    199  * Filters the options white list.
     199 * Filters the options whitelist.
    200200 *
    201201 * @since 2.7.0
    202202 *
    203  * @param array $whitelist_options White list options.
     203 * @param array $whitelist_options Whitelist options.
    204204 */
    205205$whitelist_options = apply_filters( 'whitelist_options', $whitelist_options );
  • trunk/src/wp-includes/nav-menu.php

    r47122 r47157  
    788788 * - description:      The description of this menu item.
    789789 * - menu_item_parent: The DB ID of the nav_menu_item that is this item's menu parent, if any. 0 otherwise.
    790  * - object:           The type of object originally represented, such as "category," "post", or "attachment."
     790 * - object:           The type of object originally represented, such as 'category', 'post', or 'attachment'.
    791791 * - object_id:        The DB ID of the original object this menu item represents, e.g. ID for posts and term_id for categories.
    792792 * - post_parent:      The DB ID of the original object's parent object, if any (0 otherwise).
     
    794794 * - target:           The target attribute of the link element for this menu item.
    795795 * - title:            The title of this menu item.
    796  * - type:             The family of objects originally represented, such as "post_type" or "taxonomy."
     796 * - type:             The family of objects originally represented, such as 'post_type' or 'taxonomy'.
    797797 * - type_label:       The singular label used to describe this type of menu item.
    798798 * - url:              The URL to which this menu item points.
     
    983983 *
    984984 * @param int    $object_id   The ID of the original object.
    985  * @param string $object_type The type of object, such as "taxonomy" or "post_type."
    986  * @param string $taxonomy    If $object_type is "taxonomy", $taxonomy is the name of the tax that $object_id belongs to
     985 * @param string $object_type The type of object, such as 'taxonomy' or 'post_type'.
     986 * @param string $taxonomy    If $object_type is 'taxonomy', $taxonomy is the name of the tax
     987 *                            that $object_id belongs to.
    987988 * @return int[] The array of menu item IDs; empty array if none;
    988989 */
  • trunk/src/wp-includes/option.php

    r47122 r47157  
    20992099 *
    21002100 * @param string $option_group A settings group name. Should correspond to a whitelisted option key name.
    2101  *  Default whitelisted option key names include "general," "discussion," and "reading," among others.
     2101 *                             Default whitelisted option key names include 'general', 'discussion', 'media',
     2102 *                             'reading', 'writing', 'misc', 'options', and 'privacy'.
    21022103 * @param string $option_name The name of an option to sanitize and save.
    21032104 * @param array  $args {
Note: See TracChangeset for help on using the changeset viewer.