Menu Issue after Installing a plugin
-
HI.
After creating a test plugin, called ‘especies’ and activated it, a menu page, called also ‘especies’ too stop working and now redirects to home (like a non exist page).
I have unninstalled the plugin, deleted and recreated the page and nothing…
<?php /** * Plugin Name: AKT Espécies * Description: Plugin para criação de Espécies Marinhas. * Version: 1.0 * Author: Me * License: GPL12 */ // Register the Custom Music Review Post Type function register_cpt_especies() { $labels = array( 'name' => _x( 'Espécies', 'especies' ), 'singular_name' => _x( 'Espécie', 'especies' ), 'add_new' => _x( 'Adicionar Nova', 'especies' ), 'add_new_item' => _x( 'Adicionar Nova Espécie', 'especies' ), 'edit_item' => _x( 'Editar Espécie', 'especies' ), 'new_item' => _x( 'Nova Espécie', 'especies' ), 'view_item' => _x( 'Ver Espécie', 'especies' ), 'search_items' => _x( 'Pesquisar Espécie', 'especies' ), 'not_found' => _x( 'Nenhuma Espécie Encontrada', 'especies' ), 'not_found_in_trash' => _x( 'Nenhuma Espécie Encontrada na Lixeira', 'especies' ), 'parent_item_colon' => _x( 'Espécie-Pai:', 'especies' ), 'menu_name' => _x( 'Espécies', 'especies' ), ); $args = array( 'labels' => $labels, 'hierarchical' => true, 'description' => 'Espécies Marinhas', 'supports' => array( 'title', 'editor', 'author', 'thumbnail', 'trackbacks', 'custom-fields', 'comments', 'revisions', 'page-attributes' ), 'taxonomies' => array( 'reinos' ), 'public' => true, 'show_ui' => true, 'show_in_menu' => true, 'menu_position' => 5, 'menu_icon' => 'dashicons-format-audio', '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( 'especies', $args ); } add_action( 'init', 'register_cpt_especies' ); function reinos_taxonomy() { register_taxonomy( 'reinos', 'especies', array( 'hierarchical' => true, 'label' => 'Reinos', 'query_var' => true, 'rewrite' => array( 'slug' => 'reino', 'with_front' => false ) ) ); } add_action( 'init', 'reinos_taxonomy'); ?>
Any clue?
Ty in advance
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Menu Issue after Installing a plugin’ is closed to new replies.