Questions tagged [custom-taxonomy]

Since WordPress 2.3, plugin and theme authors have had the ability to create custom taxonomies-- essentially specialized "categories"-- to help organize information.

1,275 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
7
votes
0answers
518 views

Custom Taxonomy Endpoint Pagination using paginate_links()

The Setup I have 2 taxonomies and 1 post type: Post Type: products Hierarchical Taxonomy: product_cat Nonhierarchical Taxonomy: product_type The product-category has a defined endpoint: ...
6
votes
2answers
1k views

Filtering a custom post type by custom taxonomy in archive template

I've seen this question posted in different forms before, but most of those solutions are centered around the admin interface, and I haven't found any answers that apply to the front end. I've got a ...
5
votes
1answer
291 views

Creating Custom Taxonomy without mapping to any post type

I just want to create a custom taxonomy for my plugin use but this should not be linked with any post-type and also I need to add the menu in my custom admin menu (which i have already created). I ...
4
votes
1answer
3k views

Ordering posts by custom taxonomy in admin area

EDIT @kaiser - this question is slightly different to the answer you posted in that I am talking about sorting by clicking the column title rather than adding a dropdown to filter by taxonomy term (...
4
votes
1answer
78 views

Is it possible to have a taxonomy archive that lists taxonomy terms?

For example, I have a post type called foo. I can view all posts of type foo at the following url: mysite.com/foo. I then attach a taxonomy called bar, in which the terms are foobar and foobaz. I ...
4
votes
1answer
899 views

Custom taxonomy on permalink

I have a long time problem and look forward for your help. I have a custom taxonomy of "city" (it is no hierarchical like tags). I just would like my URLs to look like this: /%city%/%category%/%...
4
votes
1answer
2k views

I want to load post content by categories using Ajax

I have question. I would like to load post content, custom post, depends on category. So first of all I would like to have drop down menu which will list all my categories then once user will select ...
3
votes
0answers
805 views

Add parent/child taxonomy to custom post type url

I have seen several cases of one taxonomy being added to a custom post type url, but I have modified that function to include a parent and a child taxonomy term. However, I am getting a 404 when I go ...
3
votes
0answers
202 views

Linking three taxonomies with ACF

I'm creating a product finder using a CPT called "Products", which is already used for displaying products separately on the site. The product finder is based on a answer and question idea, where the ...
3
votes
1answer
112 views

Remove “-2” from a Toolset Types URL with the same post name

I'm using Toolset Types to create a custom post type, and within that post type there is a taxonomy. I have created two posts with the same name, but in a different taxonomy. For the purposes of ...
3
votes
1answer
191 views

Page to display an archive of taxonomies

My website needs to have two custom post types and each of these has two custom taxonomies with several terms each. These terms also have to be hierarchical. My problem is, that I don't know how to ...
3
votes
1answer
343 views

Post tags saving as both tag name & tag ID on post update when tags are displayed as checkboxes

I've created a custom non-hierarchical taxonomy and changed it to display as check boxes instead of a tag cloud. However when I am in the post editor and select on of the available tags then update ...
3
votes
1answer
583 views

Custom taxonomy query for a custom post type

I have a custom post type called news with a custom taxonomy called news category. Right now I have a template called taxonomy-news_category-press.php where press is one of the news_categories. The ...
3
votes
1answer
762 views

has_term or in_category for Custom Post Types

I have property as a custom post type. I want to display a specific message if the property is in the sold category. To do that, I'm using the function below: if ( has_term('sold', 'category')) { ?&...
3
votes
0answers
100 views

get / list categories and counts filtered by custom taxonomy term

In my post 'post type' besides "categories" I've a custom taxonomy called "product-types". The category is actually more "manufactures" of the product types. I've a product-types page where I list ...
3
votes
0answers
2k views

Category base to url in custom post type/taxonomy

I'm building a recipe site that uses custom post types for recipes. So I searched for including the custom post type categories in the url and found a solution below by Milo. It rewrites the url and ...
3
votes
1answer
151 views

Custom Taxonomy and tax_query Issue?

I am working on Plugin development and my plugin name is plugindev.I have a custom post type called team.I have a custom taxonomy Team_Category which is being registered by this code /****************...
3
votes
0answers
50 views

How to show custom taxonomy in the permalink?

I used the Portfolio Post Type Plugin to create custom tax and post type. I would like to show the custom taxonomy on the portfolio projects. portfolio/customtaxonomy/project while now is ...
3
votes
0answers
434 views

Taxonomy page lead to 404 page on pagination

I read a lot of posts here with similar problems but nothing worked for me. I have a custom taxonomy (portfolio_category) for my custom post type. I created a taxonomy template (taxonomy-...
3
votes
0answers
934 views

Create Custom Post Type Archive Page with Sub Categories Navigation Sidebar

I have 8 custom post types (which are actually for 8 different blogs and used as "blog landing pages"). Each custom post type is also a Blog Category and each has several sub categories to it. For ...
3
votes
0answers
368 views

How to display term description in empty terms archive?

I list all terms from a taxonomy, even the empty ones, but I found out that at least in 2010/2011 themes I got a 404-like message, the default seems to only display the term description when at least ...
3
votes
1answer
1k views

Ajax post filter by taxonomy

I want to make a filter width more than one tanonomy width ajax and jquery, The demo i want to code is: http://gycweb.org/resources/ I have tried to code with this demo: http://dinhkk.com/demo/...
2
votes
0answers
40 views

get_queried_object error How to show post count by month in the taxonomy page

Can anyone help me please. i want to show custom post type count by month of taxonomy in archive page for current year. Example: January 24 February 43 March 5 April 6 and etc. This code is help ful ...
2
votes
0answers
51 views

WordPress Custom Post types and Taxonomy relationships best practices

Given that a Custom Post Type (CPT) has properties geared towards a UI on the front end and a taxonomy is a data object which allows for easy association of a post type and a set of terms (which can ...
2
votes
0answers
43 views

List custom post type by custom tax term as page title

I have a page called "Developments" and I want to list all the Project posts by the custom tax Project Type using the page title as the term. This doesn't work: <?php $title_slug = ...
2
votes
1answer
239 views

Bulk 301 redirect for custom post type

I've amended the URLs for my custom post type from: url.com/jobs/job-name to url.com/jobs/job-location/job-name Problem is, because this isn't a standard rewrite wordpress doesn't do the 301 ...
2
votes
0answers
63 views

Output the content of a term organised by each of the CPT?

I have four CPT and several shared Custom Taxonomies for all. I need to retrieve and output the content of a term (let's say "environmental-crisis" of the shared taxonomy "Crisis Type", and organise ...
2
votes
0answers
32 views

Keep taxonomy base name in post permalinks

I have a custom taxonomy (I'll call 'issues' in this example) registered as such: register_taxonomy('issues',array('post', 'pieces'), array( ... 'rewrite' => array( 'slug' => 'issues', ...
2
votes
3answers
264 views

Permalinks when filtering multiple custom post types by single taxonomy

I've been working with Custom Post Types and Custom Taxonomies for ages but one thing I can never get right are the rewrites when applying a shared taxonomy to multiple CPTs. For instance, I have ...
2
votes
0answers
1k views

Filter custom post type archive page with custom taxonomies (categories) with AJAX

I've created a custom post type (projects) with different custom taxonomies (projects' categories). I would like to create a categories' filter but with AJAX, so without reloading the page every ...
2
votes
0answers
97 views

How to display custom taxonomy in multiple columns?

I have a custom taxonomy (with terms that include all 50 states) that I'm displaying, along with the title of the posts in that term directly below. Simple, and it's working as expected. However, ...
2
votes
0answers
272 views

removing custom tax & CPT slug, adding taxonomy term in front of custom type

I am having difficulties setting up the following structure in Wordpress: site.com/custom-taxonomy-phase-term/ (taxonomy page but without the taxonomy slug) site.com/custom-taxonomy-phase-term/...
2
votes
0answers
262 views

Custom taxonomy sort by term meta in admin columns

I want sorting custom taxonomy admin table with terms by terms meta. This meta is sort index of terms. But I dont know how can do it. I use add_filter('manage_edit-{}_sortable_columns') but sorting ...
2
votes
1answer
1k views

How do I sort posts by custom taxonomy?

I am trying to sort posts by custom taxonomy. I have a custom post type which is course-cpt and I have created custom taxonomies within it, I need to sort the courses by course-level (which is the ...
2
votes
1answer
70 views

Custom Taxonomy Creates Unwanted Integer Terms on Post Save

After I select terms and then save my custom post type, new taxonomy terms are generated with integer values and selected every time. I don't know what the problem is, nor have I found any sort of the ...
2
votes
0answers
3k views

Add attribute / custom attribute to product in woocommerce

I have products from some API and want to insert these products. I was able to insert products and use already existing attributes ( or added by UI ). Adding new term (My Color) to the existing ...
2
votes
0answers
295 views

Order Wordpress Custom Taxonomy Pages & Pagination Not Working

I'm using this code to enable custom post types and taxonomies on my site (I've also included this below to save linking out) https://gist.github.com/kasparsd/2924900 The code works great for the ...
2
votes
0answers
72 views

Adding the taxonomy before the custom post type

I have a custom post type named landings which has a rewrite rule to change the slug to loans and a custom taxonomy provinces and I want the custom post type to have the slug of the province in the ...
2
votes
0answers
57 views

Storing data into custom taxonomies VS post custom fields (post meta)

I'm wondering what's more efficient when it comes to performing search for data. I am building a job board where I have an option to store information like: Company Name (Searchable) City (Searchable)...
2
votes
1answer
249 views

How to add custom taxonomy slug in CPT permalink?

This is the code i have until now to add a CPT articles and taxonomy articles-category. The code works, sort off. The pages are displaing correct (when i access them directly): articles/ articles/...
2
votes
1answer
240 views

How to do a query on custom taxonomies that is uncategorised?

I have a custom taxonomy and I wish to do a query for all custom posts who has no value assigned for that taxonomy (i.e. uncategorised). This is what I have so far: $uncatQuery = new WP_Query( ...
2
votes
1answer
456 views

custom taxonomy and custom post type url conflict

i am having one serious url issue. there is news custom post type. it's slug is news. News taxonomy slug: news_category News taxonomy url is: http://domain.com/news_category/press-release i want ...
2
votes
1answer
735 views

Get list of terms of current taxonomy archive for another taxonomy

I have a Custom Post Type named 'Real estate' which has (amongst others) two different taxonomies: 'Purpose' (hierarchical; terms used are 'Living', 'Working' and 'Holidays') and 'Location' (non-...
2
votes
0answers
935 views

Pretty URLs for Custom Post Type & Custom Taxonomy with Duplicate Slugs on WPML

I'm interested getting some help for a rather complex setup. I'm working on a publication and interested in creating a special subsection with a custom taxonomy. Think of this as an editorial ...
2
votes
0answers
2k views

Custom Post Type and Custom Taxonomy Permalinks

I'm currently working with a client's Wordpress blog that has a permalink structure set in the admin settings as "/speaks/%postname%/". This is so that all actual blog posts (post_type=>posts) have ...
2
votes
1answer
55 views

Get terms from posts submitted within a certain time

I am running a query which pulls out the most popular taxonomy terms (named "cause") from a custom post type (named "reasons") and I am ordering them by most popular. However, I need to limit the ...
2
votes
0answers
895 views

Can I change the slug of my archive page on a Custom post type?

I have a CPT with a slug that is the same of a page. This has been done on purpose as I hope I was able to control the slug of my archive page to be something like http://www.test.me/page http://www....
2
votes
2answers
157 views

How to list all record from one custom taxonomy start with only one letter i.e A

I want to list all records in one custom taxonomy start with only A or B. Below code is to list all record with all letters. Here is the code to list all record with one custom taxonomy with all ...
2
votes
0answers
934 views

Custom Posts Hierarchy? (State/City/Restaurant)

Question: What is the best way to create a hierarchy structure (also called parent/child relationships) between custom post types? For example, we currently have 3 post types: States, Cities, and ...
2
votes
1answer
237 views

How to sync tags between posts that are linked through Posts 2 Posts?

I am faced with a thorny problem and can't seem to find the solution in the wealth of community knowledge on the web. I have two custom posts types "Person" and "Activities". I use posts 2 posts (...

1 2 3 4 5 26