-
Notifications
You must be signed in to change notification settings - Fork 4
/
functions-post-type.php
32 lines (29 loc) · 2.47 KB
/
functions-post-type.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
<?php
function mbs_register_post_type() {
register_post_type( 'book', [
'has_archive' => true,
'labels' => [
'name' => '책',
'singular_name' => '책',
'menu_name' => '책',
'name_admin_bar' => '책',
'add_new' => '새 책 추가',
'add_new_item' => '새 책을 추가합니다',
'new_item' => '새 책',
'edit_item' => '책 수정',
'view_item' => '책 보기',
'all_items' => '책 목록',
'search_items' => '책 검색',
'parent_item_colon' => '상위 책:',
'not_found' => '현재 입력한 책이 없습니다.',
'not_found_in_trash' => '휴지통에 책이 없습니다.',
],
'public' => true,
'menu_position' => 3,
'supports' => [ 'title', 'editor', 'thumbnail' ],
// 'menu_icon' => 'dashicons-book',
// 'menu_icon' => get_template_directory_uri() . '/images/book-solid.svg',
'menu_icon' => 'data:image/svg+xml;base64,PHN2ZyBoZWlnaHQ9IjIwIiB2aWV3Qm94PSIwIDAgMTcuNSAyMCIgd2lkdGg9IjE3LjUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0ibTE3LjUgMTQuMDYyNXYtMTMuMTI1YzAtLjUxOTUzLS40MTc5NjktLjkzNzUtLjkzNzUtLjkzNzVoLTEyLjgxMjVjLTIuMDcwMzEyNSAwLTMuNzUgMS42Nzk2OS0zLjc1IDMuNzV2MTIuNWMwIDIuMDcwMzEgMS42Nzk2ODc1IDMuNzUgMy43NSAzLjc1aDEyLjgxMjVjLjUxOTUzMSAwIC45Mzc1LS40MTc5Ny45Mzc1LS45Mzc1di0uNjI1YzAtLjI5Mjk3LS4xMzY3MTktLjU1ODU5LS4zNDc2NTYtLjczMDQ3LS4xNjQwNjMtLjYwMTU2LS4xNjQwNjMtMi4zMTY0MSAwLTIuOTE3OTcuMjEwOTM3LS4xNjc5Ny4zNDc2NTY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