if ( ! function_exists('mista_post_type') ) { // Register Custom Post Type function mista_post_type() { $labels = array( 'name' => _x( 'Místa', 'Post Type General Name', 'customify' ), 'singular_name' => _x( 'Místo', 'Post Type Singular Name', 'customify' ), 'menu_name' => __( 'Místa', 'customify' ), 'name_admin_bar' => __( 'Místa', 'customify' ), 'archives' => __( 'Archiv míst', 'customify' ), 'attributes' => __( 'Atributy místa', 'customify' ), 'parent_item_colon' => __( 'Nadřazená položka:', 'customify' ), 'all_items' => __( 'Všechna místa', 'customify' ), 'add_new_item' => __( 'Přidat nové místo', 'customify' ), 'add_new' => __( 'Přidat nové', 'customify' ), 'new_item' => __( 'Nová položka', 'customify' ), 'edit_item' => __( 'Upravit místo', 'customify' ), 'update_item' => __( 'Upravit místo', 'customify' ), 'view_item' => __( 'Zobrazit místo', 'customify' ), 'view_items' => __( 'Zobrazit místa', 'customify' ), 'search_items' => __( 'Hledat místo', 'customify' ), 'not_found' => __( 'Nenalezeno', 'customify' ), 'not_found_in_trash' => __( 'Nenalezeno v koši', 'customify' ), 'featured_image' => __( 'Náhledový obrázek', 'customify' ), 'set_featured_image' => __( 'Zvolit náhledový obrázek', 'customify' ), 'remove_featured_image' => __( 'Odstranit náhledový obrázek', 'customify' ), 'use_featured_image' => __( 'Nastavit jako náhledový obrázek', 'customify' ), 'insert_into_item' => __( 'Vložit do položky', 'customify' ), 'uploaded_to_this_item' => __( 'Nahráno do této položky', 'customify' ), 'items_list' => __( 'Seznam položek', 'customify' ), 'items_list_navigation' => __( 'Navigace seznamu položek', 'customify' ), 'filter_items_list' => __( 'Filtrovat seznam položek', 'customify' ), ); $args = array( 'label' => __( 'Místo', 'customify' ), 'description' => __( 'Místa', 'customify' ), 'labels' => $labels, 'supports' => array( 'title', 'editor', 'thumbnail', 'custom-fields' ), 'taxonomies' => array( 'mista' ), 'hierarchical' => true, 'public' => true, 'show_ui' => true, 'show_in_menu' => true, 'menu_position' => 5, 'menu_icon' => 'dashicons-location', 'show_in_admin_bar' => false, 'show_in_nav_menus' => true, 'can_export' => true, 'has_archive' => 'mista', 'exclude_from_search' => false, 'publicly_queryable' => true, 'capability_type' => 'post', ); register_post_type( 'mista', $args ); } add_action( 'init', 'mista_post_type', 0 ); }