LE Community Content CPT
// Register Custom Post Type
function le_community_content_cpt() {
$labels = array(
'name' => _x( 'Community Content', 'Post Type General Name', 'eminence' ),
'singular_name' => _x( 'Community Content', 'Post Type Singular Name', 'eminence' ),
'menu_name' => __( 'Community Content', 'eminence' ),
'name_admin_bar' => __( 'Community Content', 'eminence' ),
'archives' => __( 'Community Content Archives', 'eminence' ),
'attributes' => __( 'Community Content Item Attributes', 'eminence' ),
'parent_item_colon' => __( 'Parent Community Content Item:', 'eminence' ),
'all_items' => __( 'All Community Content', 'eminence' ),
'add_new_item' => __( 'Add New Community Content Item', 'eminence' ),
'add_new' => __( 'Add New', 'eminence' ),
'new_item' => __( 'New Community Content Item', 'eminence' ),
'edit_item' => __( 'Edit Community Content Item', 'eminence' ),
'update_item' => __( 'Update Community Content Item', 'eminence' ),
'view_item' => __( 'View Community Content Item', 'eminence' ),
'view_items' => __( 'View Community Content', 'eminence' ),
'search_items' => __( 'Search Community Content Item', 'eminence' ),
'not_found' => __( 'Not found', 'eminence' ),
'not_found_in_trash' => __( 'Not found in Trash', 'eminence' ),
'featured_image' => __( 'Featured Image', 'eminence' ),
'set_featured_image' => __( 'Set featured image', 'eminence' ),
'remove_featured_image' => __( 'Remove featured image', 'eminence' ),
'use_featured_image' => __( 'Use as featured image', 'eminence' ),
'insert_into_item' => __( 'Insert into Community Content item', 'eminence' ),
'uploaded_to_this_item' => __( 'Uploaded to this Community Content item', 'eminence' ),
'items_list' => __( 'Community Content items list', 'eminence' ),
'items_list_navigation' => __( 'Community Content items list navigation', 'eminence' ),
'filter_items_list' => __( 'Filter Community Content items list', 'eminence' ),
);
$args = array(
'label' => __( 'Community Content', 'eminence' ),
'description' => __( 'The community content', 'eminence' ),
'labels' => $labels,
'supports' => array( 'title', 'editor' ),
'hierarchical' => false,
'public' => true,
'show_ui' => true,
'show_in_menu' => true,
'menu_position' => 5,
'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( 'community_content', $args );
}
add_action( 'init', 'le_community_content_cpt', 0 );