Services
CPT to describe Services
if ( ! function_exists('services') ) { // Register Custom Post Type function services() { $labels = array( 'name' => _x( 'Services', 'Post Type General Name', 'dik' ), 'singular_name' => _x( 'Service', 'Post Type Singular Name', 'dik' ), 'menu_name' => __( 'Services', 'dik' ), 'name_admin_bar' => __( 'Services', 'dik' ), 'parent_item_colon' => __( 'Parent Service:', 'dik' ), 'all_items' => __( 'All Services', 'dik' ), 'add_new_item' => __( 'Add New Service', 'dik' ), 'add_new' => __( 'Add New', 'dik' ), 'new_item' => __( 'New Service', 'dik' ), 'edit_item' => __( 'Edit Service', 'dik' ), 'update_item' => __( 'Update Service', 'dik' ), 'view_item' => __( 'View Service', 'dik' ), 'search_items' => __( 'Search Service', 'dik' ), 'not_found' => __( 'Not found', 'dik' ), 'not_found_in_trash' => __( 'Not found in Trash', 'dik' ), ); $args = array( 'label' => __( 'services', 'dik' ), 'description' => __( 'Services proposés', 'dik' ), 'labels' => $labels, 'supports' => array( 'title', 'editor', 'excerpt', 'thumbnail', 'page-attributes', ), 'taxonomies' => array( 'category', 'post_tag' ), 'hierarchical' => false, 'public' => true, 'show_ui' => true, 'show_in_menu' => true, 'menu_position' => 20, 'menu_icon' => 'dashicons-businessman', 'show_in_admin_bar' => true, 'show_in_nav_menus' => true, 'can_export' => true, 'has_archive' => true, 'exclude_from_search' => false, 'publicly_queryable' => true, 'capability_type' => 'page', ); register_post_type( 'services', $args ); } // Hook into the 'init' action add_action( 'init', 'services', 0 ); }