Or, embed this snippet using GenerateWP WordPress Plugin.

Download

Clone

CPT CIC Properties

// Register Custom Post Type
function cpt_cic_properties() {

	$labels = array(
		'name'                  => 'CIC Properties',
		'singular_name'         => 'CIC Property',
		'menu_name'             => 'CIC Properties',
		'name_admin_bar'        => 'CIC Property',
		'archives'              => 'CIC Property Archives',
		'attributes'            => 'CIC Property Attributes',
		'parent_item_colon'     => 'Parent CIC Property:',
		'all_items'             => 'All CIC Properties',
		'add_new_item'          => 'Add New CIC Property',
		'add_new'               => 'Add New',
		'new_item'              => 'New CIC Property',
		'edit_item'             => 'Edit CIC Property',
		'update_item'           => 'Update CIC Property',
		'view_item'             => 'View CIC Property',
		'view_items'            => 'View CIC Properties',
		'search_items'          => 'Search CIC Property',
		'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 CIC Property',
		'uploaded_to_this_item' => 'Uploaded to this CIC Property',
		'items_list'            => 'CIC Properties list',
		'items_list_navigation' => 'CIC Properties list navigation',
		'filter_items_list'     => 'Filter CIC Properties list',
	);
	$rewrite = array(
		'slug'                  => 'availabilities',
		'with_front'            => true,
		'pages'                 => true,
		'feeds'                 => true,
	);
	$args = array(
		'label'                 => 'CIC Property',
		'description'           => 'Controls the CenterPoint Intermodal Center (Parks) internal Availability pages.',
		'labels'                => $labels,
		'supports'              => array( 'title', 'editor', 'thumbnail', 'custom-fields', 'page-attributes', 'post-formats' ),
		'taxonomies'            => array( 'category', 'post_tag', 'ctt_cic_parks', 'ctt_cic_building_types' ),
		'hierarchical'          => true,
		'public'                => true,
		'show_ui'               => true,
		'show_in_menu'          => true,
		'menu_position'         => 5,
		'menu_icon'             => 'dashicons-networking',
		'show_in_admin_bar'     => true,
		'show_in_nav_menus'     => true,
		'can_export'            => true,
		'has_archive'           => false,
		'exclude_from_search'   => false,
		'publicly_queryable'    => true,
		'rewrite'               => $rewrite,
		'capability_type'       => 'page',
	);
	register_post_type( 'cic_properties', $args );

}
add_action( 'init', 'cpt_cic_properties', 0 );