COVID-19 Updates
if ( ! function_exists('covid_19_updates') ) {
// Register Custom Post Type
function covid_19_updates() {
$labels = array(
'name' => _x( 'COVID-19 Updates', 'Post Type General Name', 'tlghotels' ),
'singular_name' => _x( 'COVID-19 Update', 'Post Type Singular Name', 'tlghotels' ),
'menu_name' => __( 'COVID-19 Updates', 'tlghotels' ),
'name_admin_bar' => __( 'COVID-19 Update', 'tlghotels' ),
'archives' => __( 'COVID-19 Update Archives', 'tlghotels' ),
'attributes' => __( 'COVID-19 Update Attributes', 'tlghotels' ),
'parent_item_colon' => __( 'Parent COVID-19 Update:', 'tlghotels' ),
'all_items' => __( 'All COVID-19 Updates', 'tlghotels' ),
'add_new_item' => __( 'Add New COVID-19 Update', 'tlghotels' ),
'add_new' => __( 'Add New', 'tlghotels' ),
'new_item' => __( 'New COVID-19 Update', 'tlghotels' ),
'edit_item' => __( 'Edit COVID-19 Update', 'tlghotels' ),
'update_item' => __( 'Update COVID-19 Update', 'tlghotels' ),
'view_item' => __( 'View COVID-19 Update', 'tlghotels' ),
'view_items' => __( 'View COVID-19 Updates', 'tlghotels' ),
'search_items' => __( 'Search COVID-19 Update', 'tlghotels' ),
'not_found' => __( 'Not found', 'tlghotels' ),
'not_found_in_trash' => __( 'Not found in Trash', 'tlghotels' ),
'featured_image' => __( 'Hotel Logo', 'tlghotels' ),
'set_featured_image' => __( 'Set hotel logo', 'tlghotels' ),
'remove_featured_image' => __( 'Remove hotel logo', 'tlghotels' ),
'use_featured_image' => __( 'Use as hotel logo', 'tlghotels' ),
'insert_into_item' => __( 'Insert into COVID-19 Update', 'tlghotels' ),
'uploaded_to_this_item' => __( 'Uploaded to this COVID-19 Update', 'tlghotels' ),
'items_list' => __( 'COVID-19 Updates list', 'tlghotels' ),
'items_list_navigation' => __( 'COVID-19 Updates list navigation', 'tlghotels' ),
'filter_items_list' => __( 'Filter COVID-19 Updates list', 'tlghotels' ),
);
$args = array(
'label' => __( 'COVID-19 Update', 'tlghotels' ),
'description' => __( 'Updates for closures related to COVID-19', 'tlghotels' ),
'labels' => $labels,
'supports' => array( 'title', 'editor', 'thumbnail' ),
'hierarchical' => false,
'public' => true,
'show_ui' => true,
'show_in_menu' => true,
'menu_position' => 5,
'menu_icon' => 'dashicons-plus-alt',
'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',
);
register_post_type( 'covid_19_updates', $args );
}
add_action( 'init', 'covid_19_updates', 0 );
}