OLW Research
if ( ! function_exists('cpt_research') ) {
// Register Custom Post Type
function cpt_research() {
$labels = array(
'name' => 'Research',
'singular_name' => 'Research',
'menu_name' => 'Research',
'name_admin_bar' => 'Research',
'archives' => 'Research Archives',
'attributes' => 'Research Attributes',
'parent_item_colon' => 'Parent Item:',
'all_items' => 'All Research',
'add_new_item' => 'Add New Research',
'add_new' => 'Add New Research',
'new_item' => 'New Research',
'edit_item' => 'Edit Research',
'update_item' => 'Update Research',
'view_item' => 'View Research',
'view_items' => 'View Research',
'search_items' => 'Search Research',
'not_found' => 'Not found',
'not_found_in_trash' => 'Not found in Trash',
'featured_image' => 'Featured Image',
'set_featured_image' => 'Set featured image',
'remove_featured_image' => 'Remove featured image',
'use_featured_image' => 'Use as featured image',
'insert_into_item' => 'Insert into Research',
'uploaded_to_this_item' => 'Uploaded to this Research',
'items_list' => 'Research list',
'items_list_navigation' => 'Research list navigation',
'filter_items_list' => 'Filter Research list',
);
$args = array(
'label' => 'Research',
'description' => 'OLW Research',
'labels' => $labels,
'supports' => array( 'title', 'editor', 'page-attributes' ),
'taxonomies' => array( 'themes', 'research_tag' ),
'hierarchical' => false,
'public' => true,
'show_ui' => true,
'show_in_menu' => true,
'menu_position' => 10,
'menu_icon' => 'dashicons-welcome-learn-more',
'show_in_admin_bar' => true,
'show_in_nav_menus' => true,
'can_export' => true,
'has_archive' => true,
'exclude_from_search' => false,
'publicly_queryable' => true,
'capability_type' => 'page',
'show_in_rest' => true,
);
register_post_type( 'research', $args );
}
add_action( 'init', 'cpt_research', 0 );
}