Nominees
if ( ! function_exists('nhwf_nominees') ) {
// Register Custom Post Type
function nhwf_nominees() {
$labels = array(
'name' => _x( 'Nominees', 'Post Type General Name', 'nhwf' ),
'singular_name' => _x( 'Nominee', 'Post Type Singular Name', 'nhwf' ),
'menu_name' => __( 'Nominees', 'nhwf' ),
'name_admin_bar' => __( 'Nominees', 'nhwf' ),
'archives' => __( 'Nominees', 'nhwf' ),
'attributes' => __( 'Nominee Attributes', 'nhwf' ),
'parent_item_colon' => __( 'Parent Item:', 'nhwf' ),
'all_items' => __( 'All Items', 'nhwf' ),
'add_new_item' => __( 'Add New Nominee', 'nhwf' ),
'add_new' => __( 'Add New', 'nhwf' ),
'new_item' => __( 'New Nominee', 'nhwf' ),
'edit_item' => __( 'Edit Nominee', 'nhwf' ),
'update_item' => __( 'Update Nominee', 'nhwf' ),
'view_item' => __( 'View Nominee', 'nhwf' ),
'view_items' => __( 'View Nominees', 'nhwf' ),
'search_items' => __( 'Search Nominee', 'nhwf' ),
'not_found' => __( 'Not found', 'nhwf' ),
'not_found_in_trash' => __( 'Not found in Trash', 'nhwf' ),
'featured_image' => __( 'Featured Image', 'nhwf' ),
'set_featured_image' => __( 'Set featured image', 'nhwf' ),
'remove_featured_image' => __( 'Remove featured image', 'nhwf' ),
'use_featured_image' => __( 'Use as featured image', 'nhwf' ),
'insert_into_item' => __( 'Insert into item', 'nhwf' ),
'uploaded_to_this_item' => __( 'Uploaded to this Nominee', 'nhwf' ),
'items_list' => __( 'Nominees list', 'nhwf' ),
'items_list_navigation' => __( 'Nominees list navigation', 'nhwf' ),
'filter_items_list' => __( 'Filter Nominees list', 'nhwf' ),
);
$args = array(
'label' => __( 'Nominee', 'nhwf' ),
'description' => __( 'People nominated for an honor', 'nhwf' ),
'labels' => $labels,
'supports' => array( 'title', 'editor', 'thumbnail' ),
'taxonomies' => array( 'celebration' ),
'hierarchical' => false,
'public' => true,
'show_ui' => true,
'show_in_menu' => true,
'menu_position' => 5,
'menu_icon' => 'dashicons-universal-access-alt',
'show_in_admin_bar' => false,
'show_in_nav_menus' => false,
'can_export' => true,
'has_archive' => false,
'exclude_from_search' => true,
'publicly_queryable' => true,
'capability_type' => 'post',
);
register_post_type( 'nominee', $args );
}
add_action( 'init', 'nhwf_nominees', 0 );
}