Last active
October 20, 2017 14:26
-
-
Save morenojavier/8bf5dbcb16ea87914d7e3608b7f599a0 to your computer and use it in GitHub Desktop.
Wordpress: Tags con separador para blog.
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
<?php | |
$tags = get_the_tags(); | |
if( $tags ) : | |
echo '<p class="taxonomy"><span class="tag-title">'.__('Tags: ', 'warp').'</span>'; | |
foreach( $tags as $tag ) { | |
$names[] = '<span class="'. $tag->slug .'"><a href="'. get_tag_link($tag->term_id) .'">'. $tag->name .'</a></span>'; | |
} | |
echo implode(' , ', $names ) .'</p>'; | |
endif; | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment