0

Attempting to use:

<?php wp_list_categories( $args ); ?>

And this works fine to display a list of the default Wordpress category group used for posts(?) but I'm looking to pull a category group that is created by a plugin. Is there a parameter I can pass above that will pull a different group or can I specify by slug or similar? If slug is a possibility, how do you find the category group's slug? I think default category slug => blogging so I wonder where to find this slug?

Going off this codex https://codex.wordpress.org/Template_Tags/wp_list_categories

  • Your question is bit confusing. Whether you have registered custom taxonomy within your plugin or is it using same/default WordPress' 'Category' taxonomy? Also let me know what your have passed in $args so that I may correct you. – Prasad Nevase Sep 30 '15 at 5:19
  • I haven't passed any args. I didn't register the taxonomy myself because it comes in a plugin available to the community. Basically I wanted the same functionality as wp_list_categories but with the category setup by that plugin. I can go through the code if there is something there I need to see. – o_O Sep 30 '15 at 14:20
  • May I know which plugin you are using? I need to know the taxonomy that plugin is registering. – Prasad Nevase Sep 30 '15 at 15:39
  • wordpress.org/plugins/cpt-bootstrap-carousel It's the CPT Carousel – o_O Sep 30 '15 at 15:42
1

I just tried the plugin you mentioned. You need to use following code to get categories from that plugin:

wp_list_categories('title_li=Carousel%20Categories&orderby=name&taxonomy=carousel_category&hide_empty=0');

Notice the 'taxonomy' parameter in the querystring, it has the value of custom taxonomy registered by plugin. The default value is 'category' which is WordPress default category. For any other custom taxonomy you need to change it. I hope this helps.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.