Field Render

Display a Post Status selector as radio, checkbox or select field type.

Field Group

Field Settings

Setting nameDescription
Allow post statusesFilter which post status can be chosen
AppearanceSelect the appearance of this field
Return ValueReturn the post status name or object
Allow NullAllow empty value
LayoutChoose the layout
ToggleAllow to toggle all values
Allow CustomAllow custom value
Select multiple valuesAllow multiple values selection
Stylised UIEnable Select2 UI style

Field Value

Return Format: Post Status Object

$post_statuses = get_field('post_statuses');

/**
 * array(
 *     'label'                     => 'Published',
 *     'label_count'               => array(
 *         'Published <span class="count">(%s)</span>',
 *         'Published <span class="count">(%s)</span>',
 *         'singular' => 'Published <span class="count">(%s)</span>',
 *         'plural'   => 'Published <span class="count">(%s)</span>',
 *         'context'  => null,
 *         'domain'   => null,
 *     ),
 *     'exclude_from_search'       => false,
 *     '_builtin'                  => true,
 *     'public'                    => true,
 *     'internal'                  => false,
 *     'protected'                 => false,
 *     'private'                   => false,
 *     'publicly_queryable'        => true,
 *     'show_in_admin_status_list' => true,
 *     'show_in_admin_all_list'    => true,
 *     'date_floating'             => false,
 *     'name'                      => 'publish',
 * )
 */

Return Format: Post Status Name

$post_statuses = get_field('post_statuses');

// publish

Unformatted Value

$post_statuses = get_field('post_statuses', false, false);

// publish