admin管理员组文章数量:1406018
is it possible to change the style of the "label" of the result of a get_the_term_list( get_the_ID() ?
$film_tags = get_the_term_list( get_the_ID(), 'film_tags', 'Tags: ', ', ', '' );
is there a way to have (in the results) the "Tags: " in bold?
thanks!
is it possible to change the style of the "label" of the result of a get_the_term_list( get_the_ID() ?
$film_tags = get_the_term_list( get_the_ID(), 'film_tags', 'Tags: ', ', ', '' );
is there a way to have (in the results) the "Tags: " in bold?
thanks!
Share Improve this question asked Nov 27, 2019 at 13:28 DandeDande 351 silver badge8 bronze badges1 Answer
Reset to default 0You can use HTML to mark it up however you'd like. You can use a <strong>
tag to make it bold:
$film_tags = get_the_term_list( get_the_ID(), 'film_tags', '<strong>Tags:</strong> ', ', ', '' );
Or add a class to style with CSS:
$film_tags = get_the_term_list( get_the_ID(), 'film_tags', '<span class="tags-label">Tags:</span> ', ', ', '' );
本文标签: termsgetthetermlist( gettheID() label formatting
版权声明:本文标题:terms - get_the_term_list( get_the_ID() label formatting? 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744962449a2634739.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论