Hi Jack,
Thanks for replying so quickly. Im creating the custom post type using the following code in my theme’s functions.php:
function governor_documents_cpt() {
$labels = array(
'name' => 'Governor Documents',
'singular_name' => 'Governor Document',
'menu_name' => 'Governor Documents',
'name_admin_bar' => 'Governor Documents',
'archives' => 'Item Archives',
'attributes' => 'Item Attributes',
'parent_item_colon' => 'Parent Item:',
'all_items' => 'All Items',
'add_new_item' => 'Add New Item',
'add_new' => 'Add New',
'new_item' => 'New Item',
'edit_item' => 'Edit Item',
'update_item' => 'Update Item',
'view_item' => 'View Item',
'view_items' => 'View Items',
'search_items' => 'Search Item',
'not_found' => 'Not found',
'not_found_in_trash' => 'Not found in Trash',
'featured_image' => 'Featured Image',
'set_featured_image' => 'Set featured image',
'remove_featured_image' => 'Remove featured image',
'use_featured_image' => 'Use as featured image',
'insert_into_item' => 'Insert into item',
'uploaded_to_this_item' => 'Uploaded to this item',
'items_list' => 'Items list',
'items_list_navigation' => 'Items list navigation',
'filter_items_list' => 'Filter items list',
);
$capabilities = array(
'edit_post' => 'edit_governor_documents',
'read_post' => 'read_governor_documents',
'delete_post' => 'delete_governor_documents',
'delete_private_posts' => 'delete_governor_documents',
'delete_published_posts' => 'delete_governor_documents',
'delete_others_posts' => 'delete_governor_documents',
'edit_posts' => 'edit_governor_documents',
'edit_others_posts' => 'edit_other_governor_documents',
'publish_posts' => 'publish_governor_documents',
'read_private_posts' => 'read_governor_documents',
'create_posts' => 'create_governor_documents',
);
$args = array(
'label' => 'Governor Document',
'description' => 'Governor Documents',
'labels' => $labels,
'supports' => array( 'title'),
'hierarchical' => false,
'public' => true,
'show_ui' => true,
'show_in_menu' => true,
'menu_position' => 5,
'menu_icon' => 'dashicons-media-document',
'show_in_admin_bar' => true,
'show_in_nav_menus' => false,
'can_export' => true,
'has_archive' => true,
'exclude_from_search' => true,
'publicly_queryable' => false,
'capabilities' => $capabilities,
);
register_post_type( 'governor_documents', $args );
}
add_action( 'init', 'governor_documents_cpt', 0 );
Thanks,
Michael.