Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [register-taxonomy]

The tag has no usage guidance.

1
vote
1answer
32 views

Why does a new taxonomy term get created when I assign an existing term to a post?

I've got a stumper... I've created a new taxonomy called Article Type. I created four values for it, as shown in this metabox: When I select the "Entertainment" term and update the post, something ...
0
votes
1answer
26 views

Register non hierarchical taxonomy and the show meta box in the post type

I am trying to show a meta box in my product post type, but I'm getting this warning error... Warning error... Warning: call_user_func() expects parameter 1 to be a valid callback, no array or ...
0
votes
1answer
17 views

Non editable custom taxonomy

I have reviewed Creating a non-removable taxonomy term but it has not answered my question. One of the built-in Taxonomy terms is the "post formats". This cannot be edited. What I would like to do is ...
1
vote
1answer
178 views

404 for a custom taxonomy?

Why do I get 404 for my custom taxonomy? add_action('init', 'custom_taxonomy_flush_rewrite'); function custom_taxonomy_flush_rewrite() { global $wp_rewrite; $wp_rewrite->flush_rules(); } ...
0
votes
1answer
28 views

How to get my register taxonomy

My taxonomy register_taxonomy( 'king_blog_category', 'king_blogs', array( "hierarchical" => true, "label" => "King ...
0
votes
0answers
15 views

Taxonomy redirect issue

After create custom post want to remove taxonomy slug from post url website name seersco.com/article but it show double article/article one for website and other taxonomy name. so want to remove ...
1
vote
2answers
508 views

Add multiple custom post types in functions.php, but only one custom post type show in dashboard

I am new to wordpress, and I am trying to add multiple custom post types in the functions.php. Adding one cpt is fine. but if I use the same function to add the second cpt (with just a change of the ...
0
votes
0answers
46 views

wordpress does not see the correct custom taxonomy hierarchy

I have created custom post type - 'portfolio' with custom taxonomy designating the category and subcategory. I have an example structure: - main_category: -- subcategory_1 -- subcategory_2 The ...
0
votes
0answers
21 views

Inserting terms just one time?

So i wanted to automatically insert certain amount of terms on specific taxonomy but i wanted to be inserted ONCE so if i deleted the terms it won't be inserted back. Here's my current codes: ...
0
votes
0answers
134 views

Custom Taxonomy Not Being Recognized by is_tax()

I created a taxonomy.php template that works fine for the default stuff, but I realized my theme has default'd to index.php when trying to load a custom taxonomy I created (IE: open website.com/age/...
0
votes
0answers
331 views

URL with Hierarchical Taxonomies and same slug for all terms and sub-terms

I have a 'house' cpt and a 'locations' hierarchical custom taxonomy. Permalinks are set to /%category%/%postname% The terms in the hierarchical taxonomy are like: usa >> new-york germany >> berlin ...
0
votes
2answers
107 views

Custom Taxonomy template not display

I am having problem when I want to display my taxonomy template. I have created one custom taxonomy 'Location' for my custom post type 'Project'. Moreover, I have created templates for it as : ...
0
votes
2answers
48 views

Is there a way to re-order the Custom Taxonomy drop-down on a Custom Post listing page?

I have used register_taxonomy() with 'show_admin_column' => true successfully to get a drop-down on my custom post type listing page. The drop-down displays the terms in ID order by default. ...
0
votes
1answer
108 views

How to create taxonomy without using register_taxonomy () function

I am working on a plugin where I have to create taxonomy. But due to my requirement with little bit complexity, I have to create taxonomy without register_taxonomy(). Can somebody give me hints ...
0
votes
0answers
28 views

Taxonomy Terms That Don't Exist Display Results

I am working on a custom post type with an archive at: https://www.bowlertransmissions.com/mmc/ If you click one of the results years, such as '2016' you will then get to a page with two buttons to ...
0
votes
1answer
1k views

Custom taxonomies not showing up in admin menu

I have defined a few custom taxonomies in my functions.php using the following code: <?php add_action( 'init', function() { $labels = array( 'name' => _x( 'Resource ...
1
vote
0answers
114 views

Custom Taxonomy isn't working from frontend post submitting

hi, i am working on a video sharing site project! I have Created a Template file where people can submit their post as video! Everything was working very good, but the custom Taxonomy ponstars isn't ...
0
votes
1answer
186 views

Custom register_taxonomy ins't showing custom Nav menu

i am using wordpress custom post and register_taxonomy bellow is my code . function epg_works_register() { $labels = array( 'name' => __('Works'), 'singular_name' => __('Works'), ...
0
votes
0answers
76 views

set_object_terms for custom taxonomy in custom post type - not working

All I want is to set a custom posts taxonomy. Here is the taxonomy "lostitem" I registered for the custom post type "verloren" function create_taxonomies(){ $labels = array( 'name' => _x('Lost ...
1
vote
1answer
31 views

Remove url rewrites for registered taxonomies

According to this having many url rewrites doesn't slow down website. But neverthless is it possible to disable generating those rewrites when I register taxonomies? Becase only for this one CTP I ...
0
votes
1answer
248 views

Custom Taxonomy index/archive hierarchy

I have built a custom taxonomy, say, cars. The URL looks like this: http://www.example.com/cars/elantra/ and this is working fine by using the file taxonomy-cars.php as the template. Now, I would ...
0
votes
1answer
458 views

Adding predefined terms to a taxonomy

I'm writing a plugin for adding a Custom Post called"Dog". The core of the plugin is strictly based on this one https://github.com/RescueThemes/Rescue-Animal-Custom-Posts I prefer to add predefined ...
1
vote
0answers
26 views

taxonomy tax-name archive

I am creating a taxonomy $labels = array( 'name' => $name->labels->name, //genre 'singular_name' => $name->labels->singular_name, //genre ...
1
vote
2answers
2k views

How can I fix those issues generated by the Themecheck plugin

I've got the following error messages on the themecheck plugin in my WordPress theme. REQUIRED: The theme uses the register_taxonomy() function, which is plugin-territory functionality. ...
0
votes
1answer
129 views

Templates files for custom post type with custom tags

There is a task: Create a new post type (video) with its own post tags and tag page - separate from normal post. What I've done: // Create a new post type register_post_type('video', array('...
0
votes
1answer
240 views

Insert terms for custom taxonomy on plugin activation, or each page load (init hook)

Consider a plugin which adds a custom Taxonomy and then fills the taxonomy with a large term hierarchy (tens of hierarchical terms, may become hundreds in specific installations). I understand that ...
1
vote
1answer
471 views

update_count_callback argument in register_taxonomy function not working

I registered a custom taxonomy for ATTACHMENTS. Everything is fine on the admin side : I can tag medias with my custom taxonomy's categories, they show up with my images, etc. I then build a template ...
0
votes
1answer
74 views

Separating a custom taxonomy from blog post-type

Whenever I invoke register_taxonomy in my site's custom plugin, all taxonomies are created as children of the blog post-type in WordPress by default. I just want them to be top-level items in ...
1
vote
1answer
272 views

Use register_taxonomy() in register_activation_hook()

I would like to use register_taxonomy() to define a hierarchy of geographical terms. It seems that the natural place to place it would be in a function called by register_activation_hook() seeing how ...
1
vote
0answers
133 views

Combine multiple custom user taxonomy in single url

I have created custom user taxonomy for user and its working good. Reference guide:- http://justintadlock.com/archives/2011/10/20/custom-user-taxonomies-in-wordpress Bellow is structure of taxonomy ...
0
votes
0answers
114 views

Sort Taxonomy List by Custom Values

I'm trying to make the order of taxonomies adjustable. I've already got the drag & drop working and can put those values to the database. I just don't know how to sort the taxonomy list by other ...
0
votes
0answers
336 views

add_action priority and taxonomy used in plugin

I try to register my taxonomy in my plugin and use it after. So far I have done: function custom_taxonomy() { $labels = array( ... ); $args = array( ... ); ...
1
vote
1answer
269 views

previous_post_link/next_post_link disappear when excluding by post_format

I am trying to exclude aside post formats from my next and previous links, but for some reason, using get_term_by is not returning me the term_id for the post_format taxonomy. I see this taxonomy ...
1
vote
1answer
2k views

What does query_var do in register_taxonomy

What happens if in register_taxonomy( $taxonomy, $object_type, $args ) I set query_var arguement to true? I read here this query_var (boolean or string) (optional) False to disable the ...
0
votes
1answer
949 views

Proper way to update the slug of a taxonomy using register_taxonomy? [duplicate]

What is the best way to update the slug of a custom taxonomy that is registered by a plugin? I want to know the minimal amount of parameters for this or if i need to go and copy paste all of the ...
1
vote
1answer
714 views

Change existing taxonomy settings when using custom taxonomy

For a plugin I have created a new custom taxonomy for attachments using the function register_taxonomy() and parameters like "show_admin_column". When this parameter is set to true, it shows the ...
0
votes
1answer
3k views

get_terms from registered taxonomies not working

In functions.php I can var_dump() taxonomies like: $taxonomies=get_taxonomies('','names'); echo '<pre>'; var_dump($taxonomies); which give me: array(7) { ["category"]=> string(8) "...
16
votes
1answer
11k views

How to modify a taxonomy that's already registered

Today I needed to change the arguments on a custom taxonomy that was already registered by a third party plugin. Specifically I wanted to set the show_admin_column argument to true and change the ...
2
votes
1answer
83 views

Post taxonomy from exif data

Whenever I post a post with a featured image, I want to extract the exif data from that image and attach it as a term for a taxonomy. I already got a plugin which can extract the relevant info, but I ...
0
votes
2answers
842 views

Register custom taxonomy from a Advenced custom field option page

I have a website with products (shoes), i have some shoes models registered as taxonomy on the function.php file like so: function add_custom_taxonomies() { register_taxonomy('mod-nike', '...
1
vote
2answers
2k views

Possible to register multiple custom taxonomies in one function?

I'm registering 7 custom taxonomies in my functions.php. Since each function uses the same labels and arguments and is attached to the same Custom Post Type, I'm wondering if it's possible to register ...
0
votes
1answer
2k views

Register Taxonomy - What is `query_var`?

The Codex doesn't really explain it very well, what is it used for and how do I use it exactly?
1
vote
3answers
731 views

Register Taxonomy earlier so it can be used in functions.php and admin-ajax.php

This is a follow up to this post, outlining why I can not use the get_terms function while in functions.php (actually calling via ajax/admin_ajax.php). I can grab the terms (custom tax) on any post, ...
5
votes
1answer
89 views

Registering custom taxonomy with unique name, a good practise?

Is it a good practise to register custom taxonomy with a unique name (the $taxonomy parameter), and then use the rewrite argument to set a custom slug? For example, I could create a taxonomy called ...
0
votes
1answer
51 views

Taxonomize taxonomy terms?

I want to register taxonomies that apply to taxonomy terms (in addition to posts). I believe this is possible because posts and terms are both WP objects. What steps are needed to achieve this? ...
0
votes
1answer
562 views

Showing custom post type categories in the menu

here is my custom post type and category: //Register nav register_nav_menus( array( 'main_nav' => 'Main navigation' ) ); //Custom post types add_action( 'init', 'create_post_type' ); function ...
17
votes
3answers
14k views

Can multiple custom post types share a custom taxonomy?

I'm considering rebuilding a drupal site in wordpress and am still wrapping my head around the differences between the systems - particularly cck/fields and custom content types and the different ways ...
0
votes
1answer
741 views

What are these undocumented arguments for register_taxonomy?

The Wordpress codex has an example of the register_taxonomy() function at http://codex.wordpress.org/Taxonomies that shows arguments that are not documented in http://codex.wordpress.org/...
1
vote
1answer
1k views

is_taxonomy is deprecated. What's the alternative?

Now that is_taxonomy($taxonomy) function deprecated how do I know if a taxonomy exist? What's the alternative? On a second note, the codex for wp_insert_term() says that if the taxonomy does not ...
0
votes
1answer
1k views

register_post_type and register taxonomy and htaccess

I installed a theme called "The Dawn". It supports the addition of new type of post and a taxonomy. Here's the code: register_post_type('portfolio', array( 'description' => 'TheDawn ...