튜토리얼
// Register Custom Post Type
function tutorial_post_type() {
$labels = array(
'name' => _x( '튜토리얼', 'Post Type General Name', 'text_domain' ),
'singular_name' => _x( '튜토리얼', 'Post Type Singular Name', 'text_domain' ),
'menu_name' => __( '튜토리얼', 'text_domain' ),
'name_admin_bar' => __( '튜토리얼', 'text_domain' ),
'archives' => __( '튜토리얼 아카이브', 'text_domain' ),
'attributes' => __( '튜토리얼 속성', 'text_domain' ),
'parent_item_colon' => __( '부모 튜토리얼', 'text_domain' ),
'all_items' => __( '모든 튜토리얼', 'text_domain' ),
'add_new_item' => __( '새로운 튜토리얼 추가', 'text_domain' ),
'add_new' => __( '튜토리얼 추가하기', 'text_domain' ),
'new_item' => __( '튜토리얼 추가하기', 'text_domain' ),
'edit_item' => __( '튜토리얼 수정하기', 'text_domain' ),
'update_item' => __( '튜토리얼 업데이트', 'text_domain' ),
'view_item' => __( '튜토리얼 보기', 'text_domain' ),
'view_items' => __( '튜토리얼 보기', 'text_domain' ),
'search_items' => __( '튜토리얼 찾기', 'text_domain' ),
'not_found' => __( '튜토리얼을 찾을 수 없습니다', 'text_domain' ),
'not_found_in_trash' => __( '휴지통에서 튜토리얼을 찾을 수 없습니다', 'text_domain' ),
'featured_image' => __( '튜토리얼 커버', 'text_domain' ),
'set_featured_image' => __( '튜토리얼 커버 지정', 'text_domain' ),
'remove_featured_image' => __( '튜토리얼 커버 삭제', 'text_domain' ),
'use_featured_image' => __( '튜토리얼 커버 이미지로 사용', 'text_domain' ),
'insert_into_item' => __( '항목에 삽입', 'text_domain' ),
'uploaded_to_this_item' => __( '이 항목에 업데이트 됨', 'text_domain' ),
'items_list' => __( '항목 목록', 'text_domain' ),
'items_list_navigation' => __( '항목 목록 탐색', 'text_domain' ),
'filter_items_list' => __( '항목 필터링 목록', 'text_domain' ),
);
$args = array(
'label' => __( '튜토리얼', 'text_domain' ),
'description' => __( 'tthouse tutorial', 'text_domain' ),
'labels' => $labels,
'supports' => array( 'title', 'editor', 'thumbnail', 'comments', 'revisions', 'custom-fields', 'post-formats' ),
'taxonomies' => array( 'category', 'post_tag' ),
'hierarchical' => true,
'public' => true,
'show_ui' => true,
'show_in_menu' => true,
'menu_position' => 25,
'menu_icon' => 'dashicons-welcome-learn-more',
'show_in_admin_bar' => true,
'show_in_nav_menus' => false,
'can_export' => true,
'has_archive' => false,
'exclude_from_search' => false,
'publicly_queryable' => false,
'rewrite' => false,
'capability_type' => 'page',
'show_in_rest' => true,
);
register_post_type( 'tutorial', $args );
}
add_action( 'init', 'tutorial_post_type', 0 );