Get Registered Custom Post Type to get All Custom Taxonomies
Try this (tested) code below. I believe the issue was the passing of the $post_type parameter to get_object_taxonomies (i.e. you passed it in quotes as ‘$post_type’. If uncomment the two var_dump‘s you’ll see what information is outputted. <?php $postargs = array( ‘public’ => true, ‘_builtin’ => false ); $post_types = get_post_types( $postargs, ‘names’, ‘and’ ); … Read more