Created
April 10, 2013 03:14
-
-
Save arelthia/5351466 to your computer and use it in GitHub Desktop.
//list terms in a given taxonomy [ppshowtax='' orderby='name' 'style=' ' show_count = '' pad_counts = ' ' hierarchical = ' ' hide_empty= ' ' title_li='View Lessons' title_li='']
//list terms in a given taxonomy [ppshowtax='' orderby='name' 'style=' ' show_count = '' pad_counts = ' ' hierarchical = ' ' hide_empty= ' ' title_li='View Lessons' titl…
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//list terms in a given taxonomy [ppshowtax='' orderby='name' 'style=' ' show_count = '' pad_counts = ' ' hierarchical = ' ' hide_empty= ' ' title_li='View Lessons' title_li=''] | |
function pp_show_taxs($atts){ | |
extract( shortcode_atts( array( | |
'taxonomy' => 'category', | |
'orderby' => 'name', | |
'style' => 'list', | |
'show_count' => 0, // 1 for yes, 0 for no | |
'pad_counts' => 0, // 1 for yes, 0 for no | |
'hierarchical' => 1, // 1 for yes, 0 for no | |
'hide_empty' => 0, | |
'title_li' => ' ' | |
), $atts ) ); | |
$html = wp_list_categories( $atts ); | |
return $html; | |
} | |
add_shortcode( 'ppshowtax', 'pp_show_taxs'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment