Skip to content

Instantly share code, notes, and snippets.

@juarezpaf
Created July 15, 2011 05:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save juarezpaf/1084137 to your computer and use it in GitHub Desktop.
Save juarezpaf/1084137 to your computer and use it in GitHub Desktop.
add_action( 'init', 'register_cpt_habilidade' );
function register_cpt_habilidade() {
$labels = array(
'name' => _x( 'Habilidades', 'habilidade' ),
'singular_name' => _x( 'habilidade', 'habilidade' ),
'add_new' => _x( 'Adicionar nova', 'habilidade' ),
'add_new_item' => _x( 'Adicionar nova habilidade', 'habilidade' ),
'edit_item' => _x( 'Alterar habilidade', 'habilidade' ),
'new_item' => _x( 'Nova habilidade', 'habilidade' ),
'view_item' => _x( 'Ver habilidade', 'habilidade' ),
'search_items' => _x( 'Buscar Habilidades', 'habilidade' ),
'not_found' => _x( 'Nenhuma habilidade encontrada', 'habilidade' ),
'not_found_in_trash' => _x( 'Nenhuma habilidade encontrada na lixeira', 'habilidade' ),
'parent_item_colon' => _x( 'Habilidade:', 'habilidade' ),
'menu_name' => _x( 'Habilidades', 'habilidade' ),
);
$args = array(
'labels' => $labels,
'hierarchical' => false,
'description' => 'Informe sua habilidade',
'supports' => array( 'title', 'editor' ),
'taxonomies' => array( 'ferramentas' ),
'public' => true,
'show_ui' => true,
'show_in_menu' => true,
'menu_position' => 5,
'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( 'habilidade', $args );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment