Advertisement
Guest User

PeteNC1

a guest
Feb 18th, 2013
632
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.55 KB | None | 0 0
  1. // Add post types of "Talk" and "Event"
  2. function nc_custom_post_types() {
  3.     register_post_type( 'talk',
  4.         array(
  5.             'labels' => array(
  6.                 'name' => __( 'Talks' ),
  7.                 'singular_name' => __( 'Talk' )
  8.             ),
  9.         'public' => true,
  10.         'has_archive' => true,
  11.         'taxonomies' => array('talktype', 'category'),
  12.         )
  13.     );
  14.     register_post_type( 'event',
  15.         array(
  16.             'labels' => array(
  17.                 'name' => __( 'Events' ),
  18.                 'singular_name' => __( 'Event' )
  19.             ),
  20.         'public' => true,
  21.         'has_archive' => true,
  22.         )
  23.     );
  24. }
  25. add_action( 'init', 'nc_custom_post_types' );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement