Guest User

Untitled

a guest
Feb 17th, 2011
303
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // Register Projects
  2. add_action('init', 'register_projects');
  3.  
  4. function register_projects() {
  5.  
  6.     $labels = array(
  7.         'name' => _x('Projects', 'post type general name'),
  8.         'singular_name' => _x('Project', 'post type singular name'),
  9.         'add_new' => _x('Add New', 'project item'),
  10.         'add_new_item' => __('Add New Project'),
  11.         'edit_item' => __('Edit Project'),
  12.         'new_item' => __('New Project'),
  13.         'view_item' => __('View Project'),
  14.         'search_items' => __('Search Projects'),
  15.         'not_found' =>  __('Nothing found'),
  16.         'not_found_in_trash' => __('Nothing found in Trash'),
  17.         'parent_item_colon' => ''
  18.     );
  19.  
  20.     $args = array(
  21.         'labels' => $labels,
  22.         'public' => true,
  23.         'publicly_queryable' => true,
  24.         'show_ui' => true,
  25.         'query_var' => true,
  26.         'rewrite' => true,
  27.         'capability_type' => 'post',
  28.         'hierarchical' => false,
  29.         'menu_position' => null,
  30.         'supports' => array('title','editor','thumbnail')
  31.       );
  32.  
  33.     register_post_type( 'projects' , $args );
  34. }
RAW Paste Data