In WordPress, terms are itens set to a taxonomy, i.e. when you create new categories or tags you create new terms.

learn more… | top users | synonyms

0
votes
2answers
19 views

Sort the main query in subcategories/terms?

I've got a 'downloads' custom post, with his custom taxonomy. The taxonomy has 2 main terms. One of the 2, has 4 sub-terms. I'm currently using the wp templating system to get a standard wpquery of ...
0
votes
0answers
12 views

Taxonomy Term Variable within Foreach Loop

I have a foreach loop that cycles through all the terms of a specified taxonomy (product_cat in this case). I have the terms in a variable called $productTerm but I cannot get it work in one section ...
0
votes
0answers
7 views

No results for taxonomy archive page

So, I'm making a taxonomy template page for a plugin, but I'm not getting any results from my query. I'm loading the template with this. function projects_categories( $taxonomy_template ) { if( ...
0
votes
0answers
13 views

Redirect custom post type child term to first post

is it possible to do the following in a functions.php file? I have the following URL structure: hxxp://domain.com/custom-post-type-slug/parent-term-slug/child-term-slug/page-slug/ Directly under ...
0
votes
0answers
18 views

Taxonomy ID change after edit

Here is my problem. After editing a taxonomy - not custom one, just default Categories, ID of that term is changing. I have no idea why, it's not theme problem, it doesn't look like plugin either, ...
1
vote
1answer
55 views

Get posts from specific taxonomy term

I have nhl news website and I have taxonomy for each season (ex 2014-15) Taxonomy in functions: function wptp_register_taxonomy() { register_taxonomy( 'season', 'post', array( ...
0
votes
0answers
16 views

How do I hide certain custom taxonomy terms from meta box in Add New Post page?

I've created a custom taxonomy called 'podcasts' but I only want a certain subset of users to be able to create posts under a certain podcast term. E.g. List of podcast terms: Music Podcast Film ...
4
votes
2answers
95 views

How to get term link that crosses different custom post types?

In my WordPress project, I have several different custom post types and they all share a common taxonomy. I am in the final stage of the project and now is time to link all custom post types using a ...
0
votes
0answers
16 views

Taxonomy terms by post type and category?

I'm trying to return the terms of a taxonomy that is used by a custom post type in a specific category, I can return all the terms of the taxonomy but I want just the ones used by that post type and ...
0
votes
2answers
41 views

Saving custom term value to the database in new table

So I'm trying to save the value of a custom term to my database. The table is created as is the custom term. The code below outputs the text field onto my custom terms page but it just doesn't save ...
0
votes
0answers
17 views

How to get a single archive page to display my various custom post types respective terms?

Is there a way to make a single archive show the respective terms/categories of multiple custom post types ? So far i have been able to make use of a single archive.php to display my various custom ...
0
votes
1answer
28 views

Commas not displaying in implode

I'm trying to separate some taxonomy terms with a comma, but I can't see to get the commas to show correctly. Here's what I got: <?php $terms = get_the_terms($post->ID,'type'); foreach ( ...
0
votes
1answer
20 views

does wp_insert_term link the term to a certain post ID?

I'm using wp_insert_termto add a custom taxonomy like this: wp_insert_term( $_POST['city'], // the term 'property-city', // the taxonomy array( 'description'=> ...
0
votes
1answer
62 views

Exclude posts that only have the 'Uncategorized' category [duplicate]

I want to exclude posts that only have the Uncategorized category (i.e. category id 1), but if a post is (erroneously) categorised as "Uncategorized" but also has other categories, I want to include ...
0
votes
0answers
17 views

Child term duplicated after delete the parent of child

I'm sorry before. I want to add term with wp_insert_term function, I have created function like this: function tmd_set_default_app_term() { global $themename, $parent_term; ...
0
votes
0answers
29 views

Category list with subcategories and terms

I have a problem that I cant figure out myself. Maybe I'm going in a wrong way and thats's why it won't work. So I need a list of categories (custom post type "products"). I have some subcategories ...
1
vote
2answers
22 views

How can I find the taxonomy in edited_{taxonomy}?

How do I find out which taxonomy triggered the save? add_action ( 'edited_' . $taxonomy->name, 'save_taxonomy' ); function save_taxonomy( $term_id ) { $term = get_term( $term_id, $taxonomy ); ...
2
votes
1answer
44 views

what are terms and taxonomy and how they related to post and how these three are stored in database

I am newbie to wordpress. I want to understand terms and taxonomy in wordpress. My questions: 1. What are the terms and taxonomy in wordpress? 2. how terms and taxonomy relates to post and how post , ...
0
votes
2answers
29 views

Getting a taxonomy's thumbnail url

This is how I am currently trying: $taxonomies = array( 'product_cat' ); $args = array( 'orderby' => 'name', 'order' => 'ASC', 'hide_empty' => ...
0
votes
1answer
29 views

add links to list of post terms

How do I change the function below so that it outputs a list if links rather than a string? The resulting html I need is <a href="#">term</a> <a href="#">term</a> <a ...
0
votes
1answer
37 views

Multiple terms not working on taxonomy

I need multiple terms support my WordPress theme - $boards = get_user_meta($user_ID, '_Following Board ID'); $pboards = get_user_meta($user_ID, '_Board Parent ID'); $paged = (get_query_var('paged')) ...
2
votes
1answer
49 views

Reduce / optimize calling of wp_get_object_terms() when generating permalinks

My theme runs a loop that does not require post terms to show. However Wordpress core runs the wp_get_object_terms function on every iteration. This results in unnecessary DB queries such as: ...
0
votes
1answer
46 views

Get_terms stopped working after WP 4.2

I just noticed on my site that the custom taxonomy terms are no longer out putting. I am only guessing that it's happened since the 4.2 update. Here is the php: $terms = get_the_terms( $post->ID ...
0
votes
1answer
31 views

Custom term templates

So, I did some research online but could not find a solid answer, so here I am. I am in need to make a custom woocommerce category page for a specific category. For example, I have a category called ...
0
votes
1answer
64 views

Add a custom variable to query page object

Is there a way to add a custom variable to the queried object? if (is_page()) { $q = get_queried_object(); $term_id = $q->term_id; } Here's some background on my setup. I have a page ...
0
votes
0answers
54 views

Display taxonomy terms, child terms and posts in a template

In a site that I am building I am trying to create a template which will display all my "product" custom post types along with their parent and child taxonomies in some hierarchical structure which is ...
0
votes
0answers
60 views

What to do with shared terms splitting in Wordpress 4.2?

I read about a possible break compatibility change in Wordpress 4.2 called "shared term splitting". I download the plugin from jjeaton (https://github.com/jjeaton/wp-find-shared-terms) that show you ...
0
votes
0answers
42 views

Custom post type term names with ampersand in the term name

Every time I think I've got a handle on WordPress it finds a way to baffle me. Recently we've been having an issue with not being able to attach term names with an & (ampersand) character in the ...
0
votes
1answer
74 views

Get all taxonomies for all post types

I would like to get all the available taxonomy for each (custom) post type. My aim is to list for each post type, each taxonomy like category, tag and for each of these taxonomy to get all register ...
0
votes
1answer
317 views

Taxonomy search/filter with multiple taxonomies and multiple taxonomy terms

I am trying to build an advanced search form that allows users to select from two taxonomy based drop down menus. Each taxonomy drop down has taxonomy terms from which the user can select multiple ...
0
votes
1answer
47 views

wp_update_term not creating new unique slug

I want the slug to be recreated every time the term name is updated so it accurately reflects the name. wp_update_term(10, 'artists', array('name' => 'my new name')); The documentation ...
0
votes
0answers
54 views

Using term_group to order custom taxonomy

I have a few CPT's that use custom taxonomies. The idea is to group things on a page by the taxonomy. My problem is I would like to order the groups on the page similar to menu_order in my get_terms() ...
0
votes
0answers
55 views

How to pass taxonomy terms to WP_Query along with $args?

I created a cpt and custom taxonomy associated with it. Lets say custom taxonomy name is Sports. I added terms to it - football, basketball. Now, i want to fetch post titles tagged under football ...
1
vote
1answer
32 views

conditional statement based on terms

I was wondering if someone could help me out. I have created a custom query to retrieve in a custom single.php to retrieve posts which have the same custom taxonomy term and display them. here is the ...
0
votes
1answer
18 views

Missing term_id value

For some reason the get_term_by function does not return a value for term_id. It will return the name of the term but not a value for term_id. I'm trying to get the term_id of a category basically. ...
0
votes
1answer
53 views

Custom Post Status & Taxonomies

I have successfully registered my custom post types, custom post statuses and my custom taxonomies/terms. All is working fine but... It seems that both the 'categories' column within the custom post ...
0
votes
1answer
69 views

Add HTML to Term Description

I'm trying to add ( using wp_editor ) an HTML Term Description without a pluign. Whenever I try and spit out the data I get escaped HTML back: &lt;strong&gt;test&lt;/strong&gt; ...
0
votes
0answers
43 views

How to make a category an alias of another category?

The codex page for wp_insert_term states that you can Optionally marks it as an alias of an existing term. But I cannot find anywhere in the admin area where this is reported or can be set. I ...
-1
votes
1answer
98 views

How can I get parent term from a child term

I have a custom post type and a taxonomy, when adding a post if I select a child term and not the parent term then I cannot use get terms as the parent term wont be in the array as it wasn't selected ...
0
votes
1answer
20 views

CTP - check for value inside objects

I have registered a CTP which can add a new plant and user can tick which months it can be planted (february, march and april for example). Now, I need to display it on the page but with all months ...
0
votes
1answer
141 views

How to Get Current Custom Post Type Associated Taxonomy Term

I have a single.php file like below <?php get_header(); ?> <?php if ( have_posts() ) { while ( have_posts() ) { the_post(); echo '<div">'; ...
0
votes
1answer
59 views

Match and Merge Terms in Different Taxonomies

I have some author names held in two different taxonomies where the terms are formatted in two different but overlapping ways. There are about 400 terms in each taxonomy, associated with roughly 700 ...
0
votes
0answers
19 views

How to use one taxonomy for different needs?

I have a taxonomy called "Names" (like tags) where I store people names and for example, I have a custom post type called "Photography" where I want to tag people who appears in each photography and ...
0
votes
1answer
182 views

Get only one product category woocommerce

I have to get and show only one category name from a product. I have almost read everything and tried everything. <?php $term = get_the_terms( $post->ID, 'product_cat' ); foreach ($term as ...
0
votes
1answer
26 views

modify strip_tags function to use term slug instead of term name

I have a small function to get post categories from a custom taxonomy and modify their url, but now I have multi-word categories I need to modify it to use the category slug instead of just the ...
0
votes
1answer
74 views

Get list of CPT posts in *current* post's taxonomy term

I've seen dozens of similar but not quite the same questions - It seems easy enough to do a wp_query and get a listing of posts in a given CPT, and sort by a given taxonomy term. However, what i can't ...
0
votes
2answers
49 views

Custom Taxonomy Terms in Menu lead to which page?

Hello All I was wondering if someone could help me out. I have created a custom post type along with a custom taxonomy. In this custom taxonomy I have created custom terms through the wp dashboard. I ...
0
votes
1answer
147 views

Custom query - get_the_terms not work

I want to to show my customer works in a slide This is my query to show these works. I want to obtain the term of the taxonomy "idm_real_tax" for each custom type record. $query = new ...
0
votes
0answers
18 views

Should update a term, but new one is created instead

I have a piece of code that should update a term in a custom taxonomy, when custom post type's title or slug is updated. However, instead of updating a term, a new one is created. CPT: collection ...
0
votes
1answer
39 views

Find terms in a custom taxonomy based on the hirearchy

I have a hierarchical custom taxonomy were individual term names could be repeated in different level but not in a single hierarchical path. Let me explain this using an example News News > ...