Or, embed this snippet using GenerateWP WordPress Plugin.

Download

Clone

noticias

// Register Custom Post Type
function noticias_post_type() {

	$labels = array(
		'name'                  => _x( 'Noticias', 'Post Type General Name', 'noticias_domain' ),
		'singular_name'         => _x( 'Noticias', 'Post Type Singular Name', 'noticias_domain' ),
		'menu_name'             => __( 'Noticias', 'noticias_domain' ),
		'name_admin_bar'        => __( 'Noticias', 'noticias_domain' ),
		'archives'              => __( 'Archivo Noticias', 'noticias_domain' ),
		'attributes'            => __( 'Atributos', 'noticias_domain' ),
		'parent_item_colon'     => __( 'Noticias principal', 'noticias_domain' ),
		'all_items'             => __( 'Todas las noticias', 'noticias_domain' ),
		'add_new_item'          => __( 'Agregar nueva noticia', 'noticias_domain' ),
		'add_new'               => __( 'Agregar nuevo', 'noticias_domain' ),
		'new_item'              => __( 'Nueva Noticias', 'noticias_domain' ),
		'edit_item'             => __( 'Editar noticias', 'noticias_domain' ),
		'update_item'           => __( 'Actualizar noticia', 'noticias_domain' ),
		'view_item'             => __( 'Ver la noticia', 'noticias_domain' ),
		'view_items'            => __( 'Ver las noticias', 'noticias_domain' ),
		'search_items'          => __( 'Noticia de busqueda', 'noticias_domain' ),
		'not_found'             => __( 'No esta vigente extraviado', 'noticias_domain' ),
		'not_found_in_trash'    => __( 'No esta en la papelera', 'noticias_domain' ),
		'featured_image'        => __( 'imagen Principal', 'noticias_domain' ),
		'set_featured_image'    => __( 'Establecer como imagen destacada', 'noticias_domain' ),
		'remove_featured_image' => __( 'Eliminar imagen destacada', 'noticias_domain' ),
		'use_featured_image'    => __( 'Usar como imagen destacada', 'noticias_domain' ),
		'insert_into_item'      => __( 'Insertar en la noticia', 'noticias_domain' ),
		'uploaded_to_this_item' => __( 'Subido a esta Noticia', 'noticias_domain' ),
		'items_list'            => __( 'Lista de Noticias', 'noticias_domain' ),
		'items_list_navigation' => __( 'Ver la lista de noticias', 'noticias_domain' ),
		'filter_items_list'     => __( 'Lista de noticias por filtro', 'noticias_domain' ),
	);
	$rewrite = array(
		'slug'                  => 'noticias',
		'with_front'            => true,
		'pages'                 => true,
		'feeds'                 => true,
	);
	$args = array(
		'label'                 => __( 'Noticias', 'noticias_domain' ),
		'description'           => __( 'Sitio de Noticias del ambito de seguridad de Bolivia', 'noticias_domain' ),
		'labels'                => $labels,
		'supports'              => array( 'title', 'editor', 'thumbnail', 'comments', 'revisions', 'custom-fields' ),
		'taxonomies'            => array( 'category', 'post_tag' ),
		'hierarchical'          => false,
		'public'                => true,
		'show_ui'               => true,
		'show_in_menu'          => true,
		'menu_position'         => 5,
		'menu_icon'             => 'dashicons-microphone',
		'show_in_admin_bar'     => true,
		'show_in_nav_menus'     => true,
		'can_export'            => true,
		'has_archive'           => true,
		'exclude_from_search'   => false,
		'publicly_queryable'    => true,
		'rewrite'               => $rewrite,
		'capability_type'       => 'page',
		'show_in_rest'          => true,
	);
	register_post_type( 'noticias', $args );

}
add_action( 'init', 'noticias_post_type', 0 );