WordPress.org

Ready to get started?Download WordPress

Forums

Display Widgets
Custom Taxonomies Not Available As Checkable Items (3 posts)

  1. Suzanne Ahjira
    Member
    Posted 1 year ago #

    Hi there, I have two custom taxonomies I've created in my functions.php file and neither of them appear in Display Widgets' list of selectable items. I thought maybe I was missing an arg, but I tweaked them without success. Is there a trick to getting custom taxonomies to show up? Here's an example of my code:

    add_action( 'init', 'create_image_type_taxonomies', 0 );
    function create_image_type_taxonomies() {
      register_taxonomy('image_type','post',array(
        'public' => true,
        'hierarchical' => false,
        'labels' => $labels,
        'show_ui' => true,
        'update_count_callback' => '_update_post_term_count',
        'query_var' => true,
        'show_admin_column' => true,
        'rewrite' => array( 'slug' => 'image-type' ),
      ));
    }

    http://wordpress.org/extend/plugins/display-widgets/

  2. qui_gon_jim
    Member
    Posted 7 months ago #

    Hi, I appear to be having the same problem when adding another taxonomy to posts. There is no option to select taxonomies within the widget (like there is for Categories +/-), therefore I am unable to get a widget to display on the taxonomy pages. Any ideas?

    register_taxonomy('topic','post',array(
            'hierarchical' => true,
            'labels' => array(
                'name' => 'Topics',
                'singular_name' => 'Topic',
                'search_items' =>  'Search Topics',
                'all_items' => 'All Topics',
                'parent_item' => 'Parent Topic',
                'parent_item_colon' => 'Topic Location',
                'edit_item' => 'Edit Topic',
                'update_item' => 'Update Topic',
                'add_new_item' => 'Add New Topic',
                'new_item_name' => 'New Topic Name',
                'menu_name' => 'Topics',
            ),
            'rewrite' => array(
                'slug' => 'news/topic',
                'with_front' => false,
                'hierarchical' => true
            ),
        ));
  3. sswells
    Member
    Plugin Author

    Posted 7 months ago #

    You'll need to deactivate and reactivate to clear the 7 day cache. It doesn't clear unless you add flush rewrite.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.