Add a the_terms filter, and use a default ", " sep. props scribu. fixes #10600
git-svn-id: https://develop.svn.wordpress.org/trunk@11900 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
30bae2a1a7
commit
367fdfe7f3
@ -925,12 +925,13 @@ function get_the_term_list( $id = 0, $taxonomy, $before = '', $sep = '', $after
|
|||||||
* @param string $after Optional. After list.
|
* @param string $after Optional. After list.
|
||||||
* @return null|bool False on WordPress error. Returns null when displaying.
|
* @return null|bool False on WordPress error. Returns null when displaying.
|
||||||
*/
|
*/
|
||||||
function the_terms( $id, $taxonomy, $before = '', $sep = '', $after = '' ) {
|
function the_terms( $id, $taxonomy, $before = '', $sep = ', ', $after = '' ) {
|
||||||
$return = get_the_term_list( $id, $taxonomy, $before, $sep, $after );
|
$term_list = get_the_term_list( $id, $taxonomy, $before, $sep, $after );
|
||||||
if ( is_wp_error( $return ) )
|
|
||||||
|
if ( is_wp_error( $term_list ) )
|
||||||
return false;
|
return false;
|
||||||
else
|
|
||||||
echo $return;
|
echo apply_filters('the_terms', $term_list, $taxonomy, $before, $sep, $after);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user