Or, embed this snippet using GenerateWP WordPress Plugin.

Download

Clone

Band Bios

Holds band members specific data.

if ( ! function_exists('cuervox_band_bios') ) {

// Register Custom Post Type
function cuervox_band_bios() {

	$labels = array(
		'name'                => _x( 'Band Bios', 'Post Type General Name', 'text_domain' ),
		'singular_name'       => _x( 'Band Bio', 'Post Type Singular Name', 'text_domain' ),
		'menu_name'           => __( 'Band Bios', 'text_domain' ),
		'parent_item_colon'   => __( 'Parent Bio:', 'text_domain' ),
		'all_items'           => __( 'All Band Bios', 'text_domain' ),
		'view_item'           => __( 'View Band Bio', 'text_domain' ),
		'add_new_item'        => __( 'Add New Band Bio', 'text_domain' ),
		'add_new'             => __( 'Add New Band Bio', 'text_domain' ),
		'edit_item'           => __( 'Edit Band Bio', 'text_domain' ),
		'update_item'         => __( 'Update Band Bio', 'text_domain' ),
		'search_items'        => __( 'Search Band Bios', 'text_domain' ),
		'not_found'           => __( 'No Band Bio found', 'text_domain' ),
		'not_found_in_trash'  => __( 'No Band Bio found in Trash', 'text_domain' ),
	);
	$rewrite = array(
		'slug'                => 'bio',
		'with_front'          => true,
		'pages'               => true,
		'feeds'               => true,
	);
	$args = array(
		'label'               => __( 'band_bios', 'text_domain' ),
		'description'         => __( 'Holds band member specific data.', 'text_domain' ),
		'labels'              => $labels,
		'supports'            => array( 'title', 'editor', 'excerpt', 'thumbnail', 'comments', 'revisions', ),
		'taxonomies'          => array( 'category' ),
		'hierarchical'        => false,
		'public'              => true,
		'show_ui'             => true,
		'show_in_menu'        => true,
		'show_in_nav_menus'   => true,
		'show_in_admin_bar'   => true,
		'menu_position'       => 60,
		'menu_icon'           => 'dashicons-admin-users',
		'can_export'          => true,
		'has_archive'         => false,
		'exclude_from_search' => false,
		'publicly_queryable'  => true,
		'rewrite'             => $rewrite,
		'capability_type'     => 'page',
	);
	register_post_type( 'band_bios', $args );

}

// Hook into the 'init' action
add_action( 'init', 'cuervox_band_bios', 0 );

}