SHARE
TWEET

Untitled

a guest Nov 13th, 2019 84 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. add_action( 'init', 'create_post_type_jobs', 0 );
  2.     function create_post_type_jobs() {
  3.         $labels = array(
  4.             'name'                  => _x( 'Jobs', 'Post Type General Name', 'aks_jobs' ),
  5.             'singular_name'         => _x( 'Job', 'Post Type Singular Name', 'aks_jobs' ),
  6.             'menu_name'             => __( 'Jobs', 'aks_jobs' ),
  7.             'name_admin_bar'        => __( 'Jobs', 'aks_jobs' ),
  8.             'archives'              => __( 'Job Archives', 'aks_jobs' ),
  9.             'attributes'            => __( 'Job Attributes', 'aks_jobs' ),
  10.             'parent_item_colon'     => __( 'Parent Item:', 'aks_jobs' ),
  11.             'all_items'             => __( 'All Items', 'aks_jobs' ),
  12.             'add_new_item'          => __( 'Add New Job', 'aks_jobs' ),
  13.             'add_new'               => __( 'Add New', 'aks_jobs' ),
  14.             'new_item'              => __( 'New Item', 'aks_jobs' ),
  15.             'edit_item'             => __( 'Edit Item', 'aks_jobs' ),
  16.             'update_item'           => __( 'Update Item', 'aks_jobs' ),
  17.             'view_item'             => __( 'View Item', 'aks_jobs' ),
  18.             'view_items'            => __( 'View Items', 'aks_jobs' ),
  19.             'search_items'          => __( 'Search Item', 'aks_jobs' ),
  20.             'not_found'             => __( 'Not found', 'aks_jobs' ),
  21.             'not_found_in_trash'    => __( 'Not found in Trash', 'aks_jobs' ),
  22.             'featured_image'        => __( 'Featured Image', 'aks_jobs' ),
  23.             'set_featured_image'    => __( 'Set featured image', 'aks_jobs' ),
  24.             'remove_featured_image' => __( 'Remove featured image', 'aks_jobs' ),
  25.             'use_featured_image'    => __( 'Use as featured image', 'aks_jobs' ),
  26.             'insert_into_item'      => __( 'Insert into item', 'aks_jobs' ),
  27.             'uploaded_to_this_item' => __( 'Uploaded to this item', 'aks_jobs' ),
  28.             'items_list'            => __( 'Items list', 'aks_jobs' ),
  29.             'items_list_navigation' => __( 'Items list navigation', 'aks_jobs' ),
  30.             'filter_items_list'     => __( 'Filter items list', 'aks_jobs' ),
  31.         );
  32.         $args = array(
  33.             'label'                 => __( 'Job', 'aks_jobs' ),
  34.             'description'           => __( 'Jobs', 'aks_jobs' ),
  35.             'labels'                => $labels,
  36.             'supports'              => array( 'title', 'editor' ),
  37.             'taxonomies'            => array( 'category', 'post_tag' ),
  38.             'hierarchical'          => false,
  39.             'public'                => true,
  40.             'show_ui'               => true,
  41.             'show_in_menu'          => true,
  42.             'menu_position'         => 5,
  43.             'menu_icon'             => 'dashicons-businessperson',
  44.             'show_in_admin_bar'     => true,
  45.             'show_in_nav_menus'     => true,
  46.             'can_export'            => true,
  47.             'has_archive'           => true,
  48.             'exclude_from_search'   => false,
  49.             'publicly_queryable'    => true,
  50.             'capability_type'       => 'post',
  51.             'rewrite'               => array('slug' => 'job'),
  52.         );
  53.         register_post_type( 'jobs', $args );
  54.     }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top