Make WordPress Core


Ignore:
Timestamp:
05/10/2017 06:09:36 AM (9 years ago)
Author:
rmccue
Message:

Options/Meta: Document valid types for registration.

In 4.7, the REST API introduced types for options and meta passed into the registration functions. This adds the documentation for those types.

Props iandunn, priyankabehera155.
Fixes #40318.

File:
1 edited

Legend:

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

    r40432 r40603  
    18721872 *
    18731873 *     @type string   $type              The type of data associated with this setting.
     1874 *                                       Valid values are 'string', 'boolean', 'integer', and 'number'.
    18741875 *     @type string   $description       A description of the data attached to this setting.
    18751876 *     @type callable $sanitize_callback A callback function that sanitizes the option's value.
Note: See TracChangeset for help on using the changeset viewer.