| 1 |
<?php |
| 2 |
if(!function_exists('blockspare_get_cat_tax_tags')){ |
| 3 |
function blockspare_get_cat_tax_tags ($taxType,$post_id){ |
| 4 |
|
| 5 |
|
| 6 |
$categories_list = get_the_category_list(' ', '', $post_id); |
| 7 |
if ( $categories_list ) { |
| 8 |
/* translators: 1: list of categories. */ |
| 9 |
printf( esc_html__( '%1$s', 'blockspare' ), $categories_list ); // WPCS: XSS OK. |
| 10 |
} |
| 11 |
|
| 12 |
|
| 13 |
// if($taxType =='post_tag'){ |
| 14 |
// $tag_lists = get_the_tag_list(' ', '', $post_id); |
| 15 |
// if ( $tag_lists ) { |
| 16 |
// /* translators: 1: list of categories. */ |
| 17 |
// printf( esc_html__( '%1$s', 'blockspare' ), $tag_lists ); // WPCS: XSS OK. |
| 18 |
// } |
| 19 |
// } |
| 20 |
|
| 21 |
/* |
| 22 |
$terms = get_the_terms($post_id , $taxType ); |
| 23 |
if($terms){ |
| 24 |
foreach($terms as $trem){ ?> |
| 25 |
<a herf="" ><?php echo $trem->name; ?></a> |
| 26 |
<?php |
| 27 |
} |
| 28 |
} |
| 29 |
*/ |
| 30 |
|
| 31 |
} |
| 32 |
} |