Created
          September 3, 2024 20:13 
        
      - 
      
- 
        Save SitesByYogi/9a7c3bcebef8b51f8b8a03d3366a3457 to your computer and use it in GitHub Desktop. 
    add custom post type
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | <?php | |
| // Register the custom post type 'todo' | |
| function todo_register_post_type() { | |
| register_post_type('todo', array( | |
| 'labels' => array( | |
| 'name' => __('Content Creation Center'), | |
| 'singular_name' => __('Content'), | |
| 'add_new' => __('Add New Content'), | |
| 'add_new_item' => __('Add New Content'), | |
| 'edit_item' => __('Edit Item'), | |
| 'new_item' => __('New Content'), | |
| 'view_item' => __('View Content'), | |
| 'search_items' => __('Search Content List'), | |
| 'not_found' => __('No Items found'), | |
| 'not_found_in_trash' => __('No Planned Content found in Trash'), | |
| 'all_items' => __('All Planned Content'), | |
| ), | |
| 'public' => false, | |
| 'show_ui' => true, // Display in admin dashboard | |
| 'supports' => array('title'), | |
| 'menu_icon' => 'dashicons-list-view', | |
| )); | |
| } | |
| add_action('init', 'todo_register_post_type'); | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment