File: /home/slyfwmm/pianob/wp-content/themes/zk-monaco/inc/custom-post/posts.php
<?php
if(!function_exists('register_ef3_post_type')) return;
function cptui_register_my_cpts() {
/**
* Post Type: Portfolio.
*/
$labels = array(
"name" => __( "Portfolio", "zk-monaco" ),
"singular_name" => __( "Portfolio", "zk-monaco" ),
);
$args = array(
"label" => __( "Portfolio", "zk-monaco" ),
"labels" => $labels,
"description" => "",
"public" => true,
"show_ui" => true,
"show_in_rest" => false,
"has_archive" => false,
"show_in_menu" => true,
"show_in_nav_menus" => true,
"exclude_from_search" => false,
"capability_type" => "post",
"map_meta_cap" => true,
"hierarchical" => true,
"rewrite" => array( "slug" => "portfolio", "with_front" => true ),
"query_var" => true,
"supports" => array( "title", "editor", "thumbnail" ),
"taxonomies" => array( "portfolio_cat" ),
);
register_ef3_post_type( "portfolio", $args );
/**
* Post Type: Team.
*/
$labels = array(
"name" => __( "Team", "zk-monaco" ),
"singular_name" => __( "Team", "zk-monaco" ),
);
$args = array(
"label" => __( "Team", "zk-monaco" ),
"labels" => $labels,
"description" => "",
"public" => true,
"show_ui" => true,
"show_in_rest" => false,
"has_archive" => false,
"show_in_menu" => true,
"show_in_nav_menus" => true,
"exclude_from_search" => false,
"capability_type" => "post",
"map_meta_cap" => true,
"hierarchical" => true,
"rewrite" => array( "slug" => "team", "with_front" => true ),
"query_var" => true,
"supports" => array( "title", "editor", "thumbnail" ),
"taxonomies" => array( "team_cat" ),
);
register_ef3_post_type( "team", $args );
/**
* Post Type: Clients.
*/
$labels = array(
"name" => __( "Clients", "zk-monaco" ),
"singular_name" => __( "", "zk-monaco" ),
);
$args = array(
"label" => __( "Clients", "zk-monaco" ),
"labels" => $labels,
"description" => "",
"public" => true,
"show_ui" => true,
"show_in_rest" => false,
"has_archive" => false,
"show_in_menu" => true,
"show_in_nav_menus" => true,
"exclude_from_search" => false,
"capability_type" => "post",
"map_meta_cap" => true,
"hierarchical" => true,
"rewrite" => array( "slug" => "client", "with_front" => true ),
"query_var" => true,
"supports" => array( "title", "editor", "thumbnail" ),
);
register_ef3_post_type( "client", $args );
/**
* Post Type: Testimonials.
*/
$labels = array(
"name" => __( "Testimonials", "zk-monaco" ),
"singular_name" => __( "", "zk-monaco" ),
);
$args = array(
"label" => __( "Testimonials", "zk-monaco" ),
"labels" => $labels,
"description" => "",
"public" => true,
"show_ui" => true,
"show_in_rest" => false,
"rest_base" => "",
"has_archive" => false,
"show_in_menu" => true,
"show_in_nav_menus" => true,
"exclude_from_search" => false,
"capability_type" => "post",
"map_meta_cap" => true,
"hierarchical" => true,
"rewrite" => array( "slug" => "testimonial", "with_front" => true ),
"query_var" => true,
"supports" => array( "title", "editor", "thumbnail" ),
);
register_ef3_post_type( "testimonial", $args );
}
add_action( 'init', 'cptui_register_my_cpts' );