Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function your_prefix_register_post_type() {
- $args = array (
- 'label' => esc_html__( 'work', 'text-domain' ),
- 'labels' => array(
- 'menu_name' => esc_html__( 'work', 'text-domain' ),
- 'name_admin_bar' => esc_html__( 'work', 'text-domain' ),
- 'add_new' => esc_html__( 'Add new', 'text-domain' ),
- 'add_new_item' => esc_html__( 'Add new work', 'text-domain' ),
- 'new_item' => esc_html__( 'New work', 'text-domain' ),
- 'edit_item' => esc_html__( 'Edit work', 'text-domain' ),
- 'view_item' => esc_html__( 'View work', 'text-domain' ),
- 'update_item' => esc_html__( 'Update work', 'text-domain' ),
- 'all_items' => esc_html__( 'All work', 'text-domain' ),
- 'search_items' => esc_html__( 'Search work', 'text-domain' ),
- 'parent_item_colon' => esc_html__( 'Parent work', 'text-domain' ),
- 'not_found' => esc_html__( 'No work found', 'text-domain' ),
- 'not_found_in_trash' => esc_html__( 'No work found in Trash', 'text-domain' ),
- 'name' => esc_html__( 'work', 'text-domain' ),
- 'singular_name' => esc_html__( 'work', 'text-domain' ),
- ),
- 'public' => true,
- 'exclude_from_search' => false,
- 'publicly_queryable' => true,
- 'show_ui' => true,
- 'show_in_nav_menus' => true,
- 'show_in_menu' => true,
- 'show_in_admin_bar' => false,
- 'show_in_rest' => false,
- 'capability_type' => 'post',
- 'hierarchical' => false,
- 'has_archive' => true,
- 'query_var' => true,
- 'can_export' => true,
- 'rewrite_no_front' => false,
- 'supports' => array(
- 'title',
- 'editor',
- 'thumbnail',
- ),
- 'rewrite' => true,
- );
- register_post_type( 'work', $args );
- }
- add_action( 'init', 'your_prefix_register_post_type' );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement