Ideas CPT
// Register Custom Post Type
function fundraiser_ideas() {
$labels = array(
'name' => 'Ideas',
'singular_name' => 'Idea',
'menu_name' => 'Idea Pages',
'name_admin_bar' => 'Idea Pages',
'parent_item_colon' => 'Parent Page:',
'all_items' => 'All Pages',
'add_new_item' => 'Add New Page',
'add_new' => 'Add New',
'new_item' => 'New Page',
'edit_item' => 'Edit Page',
'update_item' => 'Update Page',
'view_item' => 'View Page',
'search_items' => 'Search Item',
'not_found' => 'Not found',
'not_found_in_trash' => 'Not found in Trash',
);
$args = array(
'label' => 'fundraiser',
'description' => 'Fundraiser Idea Pages',
'labels' => $labels,
'supports' => array( 'title', 'editor', 'excerpt', 'thumbnail', 'revisions', 'custom-fields', ),
'taxonomies' => array( 'fundraiser-ideas' ),
'hierarchical' => true,
'public' => true,
'show_ui' => true,
'show_in_menu' => true,
'menu_position' => 5,
'menu_icon' => 'dashicons-info',
'show_in_admin_bar' => true,
'show_in_nav_menus' => true,
'can_export' => true,
'has_archive' => false,
'exclude_from_search' => false,
'publicly_queryable' => true,
'query_var' => 'ideas',
'capability_type' => 'page',
);
register_post_type( 'fundraiser', $args );
}
// Hook into the 'init' action
add_action( 'init', 'fundraiser_ideas', 0 );