BVG_Mannschaften
// Register Custom Post Type
function register_mannschaften() {
$labels = array(
'name' => 'Mannschaften',
'singular_name' => 'Mannschaft',
'menu_name' => 'Mannschaften',
'name_admin_bar' => 'Mannschaften',
'parent_item_colon' => '',
'all_items' => 'Alle Mannschaften',
'add_new_item' => '',
'add_new' => '',
'new_item' => 'Neue Mannschaft',
'edit_item' => 'Mannschaft bearbeiten',
'update_item' => '',
'view_item' => '',
'search_items' => 'Mannschaft suchen',
'not_found' => '',
'not_found_in_trash' => '',
);
$args = array(
'label' => 'mannschaften',
'labels' => $labels,
'supports' => array( 'title', 'editor', 'thumbnail', 'revisions', 'page-attributes', ),
'taxonomies' => array( 'bereiche' ),
'hierarchical' => false,
'public' => true,
'show_ui' => true,
'show_in_menu' => true,
'menu_position' => 20,
'menu_icon' => 'dashicons-groups',
'show_in_admin_bar' => true,
'show_in_nav_menus' => false,
'can_export' => true,
'has_archive' => false,
'exclude_from_search' => false,
'publicly_queryable' => true,
'capability_type' => 'post',
);
register_post_type( 'mannschaften', $args );
}
// Hook into the 'init' action
add_action( 'init', 'register_mannschaften', 0 );