How to Filter Posts by Custom Taxonomy in WordPress Dashboard

Recently I made a Website which has property custom post type and client ask for add filter in a backend. So today I will share that code with you that ‘How to Filter Posts by Custom Taxonomy in WordPress Dashboard’.

Suppose if you have lots of posts on your WordPress site, you mainly used the Category and Tag filters at the top of the post page. These filters are great because they very quickly allow you to limit the kind of posts that are displayed, and let you find the one you are looking for. If you use any custom post types or custom taxonomies, then you have noticed that these options are not available. So I’m going to show you how to add new filters for your custom taxonomies to any custom post type.

filter-posts-by-custom-taxonomy

The process is pretty simple, It will not require lots of code, WordPress does most of the work for you. What we are going to do is setup a function that creates a drop down select menu based off the terms in the taxonomies we provide. So if we set the function to display a filter for the taxonomy, it will retrieve a list of all of the terms in that taxonomy (which are not empty), and then display each of those terms as an option in the drop down menu. If we provide multiple taxonomies, through an array, then the function will create a drop down for each set of taxonomy terms.

Above code filter custom property type post with property-status Taxonomy.