Or, embed this snippet using GenerateWP WordPress Plugin.

Download

Clone

EFINOR – Moyens

// Register Custom Post Type
function moyens() {

	$labels = array(
		'name'                => _x( 'Moyens', 'Post Type General Name', 'altitude-moyens' ),
		'singular_name'       => _x( 'Moyen', 'Post Type Singular Name', 'altitude-moyens' ),
		'menu_name'           => __( 'Moyens', 'altitude-moyens' ),
		'name_admin_bar'      => __( 'Moyens', 'altitude-moyens' ),
		'parent_item_colon'   => __( 'Parent Item:', 'altitude-moyens' ),
		'all_items'           => __( 'Tout', 'altitude-moyens' ),
		'add_new_item'        => __( 'Ajouter', 'altitude-moyens' ),
		'add_new'             => __( 'Nouveau', 'altitude-moyens' ),
		'new_item'            => __( 'Nouveau', 'altitude-moyens' ),
		'edit_item'           => __( 'Éditer', 'altitude-moyens' ),
		'update_item'         => __( 'Mettre à jour', 'altitude-moyens' ),
		'view_item'           => __( 'Voir', 'altitude-moyens' ),
		'search_items'        => __( 'Rechercher', 'altitude-moyens' ),
		'not_found'           => __( 'Non trouvé', 'altitude-moyens' ),
		'not_found_in_trash'  => __( 'Non trouvé dans la corbeille', 'altitude-moyens' ),
	);
	$args = array(
		'label'               => __( 'moyens', 'altitude-moyens' ),
		'description'         => __( 'Gestions des moyens', 'altitude-moyens' ),
		'labels'              => $labels,
		'supports'            => array( ),
		'taxonomies'          => array( 'category_moyens' ),
		'hierarchical'        => false,
		'public'              => true,
		'show_ui'             => true,
		'show_in_menu'        => true,
		'menu_position'       => 5,
		'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'     => 'post',
	);
	register_post_type( 'moyens', $args );

}

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