Articles of custom taxonomy

How to restrict search on a certain page to only return results against custom taxonomies?

On a specific page, I would like the search to be performed only against the terms from two custom taxonomies. Not the content or title. That is, the user is directly searching taxonomy terms. What I’m trying to do is completely rewrite the query for searches, but it doesn’t seem to work. function search_filter_get_posts($query) { […]

How to get list of only custom taxonomies?

I am looking for a way to get all custom taxonomies but I could not find any way yet. Is there any good way to get lsit of all custom taxonomies? I tried to use get_taxonomies(); function but that return just default taxonomies not custom. Thanks

Get list of taxonomies associated with users

I’ve seen Justin Tadlock’s post on creating taxonomies for users, so I know that it’s possible to do that. But how do you get a list of all of the taxonomies associated with users? For posts and CPTs you can use get_object_taxonomies( $post_type );. What’s the equivalent for users?

Weekdays as terms – How to order taxonomy terms by ID in admin panel?

I created a custom taxonomy using following code. add_action( ‘init’, ‘schedule_day_tax_func’ ); function schedule_day_tax_func() { register_taxonomy( ‘schedule_day_taxonomy’, ‘schedule’, array( ‘hierarchical’ => true, ‘label’ => ‘Day’, ‘query_var’ => true, ‘orderby’ => ‘ID’, ) ); } after I added some terms from the admin panel, the TERMS displayed in alphabetical order in admin panel. I want those […]

Save values generated via API as taxonomy terms

I’m using the IMDB Connecter plugin to grab meta data for movies and I’m wondering if I can save some of the information it generates as terms in a custom taxonomy that already exists. What I want to do is to be able to save the “Director” and “Actors” information generated by the plugin as […]

forward/redirect taxonomy archive of term to a page with same name

I have a page called “cars” with child pages for each individual car eg (site.com/cars/ferrari) I have created a taxonomy called ‘vehicle’ where each term has a car that matches the child page. (site.com/vehicle/ferrari) When I tag posts and custom post types with this taxonomy, I would like the link to forward to the car […]

Order Taxonomy Term by date created

Trying to get the order of my custom query to display by Date created. Is this even possible with this query? Can you do a custom order? thanks for the help <?php $faq_cat_terms = get_terms( ‘faq-cat’ ); foreach ( $faq_cat_terms as $faq_cat ) { $faq_cat_query = new WP_Query( array( ‘orderby’ => ‘date’, ‘post_type’ => ‘faq’, […]

How to get only child terms from a custom taxonomy of current post type?

Having a custom post type ‘pubs’ with custom taxonomy ‘types’ in which admin enter parent terms and their child terms. Using this code to get all the terms of current post type: $object_terms = wp_get_object_terms($post->ID, ‘types’, array(‘fields’ => ‘all’)); if ($object_terms) { echo ” . ” . ” ; $res = ”; foreach ($object_terms as […]

How to get posts by category and by choosing a taxonomy term?

I’m new to WordPress and I’ve managed to build most of a full custom theme for wordpress on my own. But the tricky stuff is starting to show its tail, and I’ve spent the last days stuck on Taxonomies. I just managed to put a code for registering a custom Taxonomy to sort my articles […]

Storing content into a custom taxonomy

Currently I have created a custom taxonomy with the name “genre” and I am wondering how I can include it into the array for posting with the content from the string provided in the example. $my_post = array( ‘post_title’ => wp_strip_all_tags( trim( $post_title ) ), ‘post_content’ => $my_post, ‘post_status’ => ‘publish’, ‘post_author’ => 2, ‘post_category’ […]