Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- add_action( 'init', 'register_cpt_agents' );
- function register_cpt_agents() {
- $labels = array(
- 'name' => _x( 'Agent Profiles', 'agents' ),
- 'singular_name' => _x( 'Agent Profile', 'agents' ),
- 'add_new' => _x( 'Add New', 'agents' ),
- 'add_new_item' => _x( 'Add New Agent Profile', 'agents' ),
- 'edit_item' => _x( 'Edit Agent Profile', 'agents' ),
- 'new_item' => _x( 'New Agent Profile', 'agents' ),
- 'view_item' => _x( 'View Agent Profile', 'agents' ),
- 'search_items' => _x( 'Search Agent Profiles', 'agents' ),
- 'not_found' => _x( 'No agent profiles found', 'agents' ),
- 'not_found_in_trash' => _x( 'No agent profiles found in Trash', 'agents' ),
- 'parent_item_colon' => _x( 'Parent Agent Profile:', 'agents' ),
- 'menu_name' => _x( 'Agent Profiles', 'agents' ),
- );
- $args = array(
- 'labels' => $labels,
- 'hierarchical' => false,
- 'supports' => array( 'title', 'author', 'editor', 'thumbnail' ),
- 'taxonomies' => array( 'page-category', 'regions', 'languages' ),
- 'public' => true,
- 'show_ui' => true,
- 'show_in_menu' => true,
- 'show_in_nav_menus' => true,
- 'publicly_queryable' => true,
- 'exclude_from_search' => false,
- 'has_archive' => true,
- 'query_var' => true,
- 'can_export' => true,
- 'rewrite' => true,
- 'capability_type' => 'post'
- );
- register_post_type( 'agents', $args );
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement