How do I remove the link generated by the_tags?
This is what I use today: <?php the_tags( '', '', '' ); ?>
That results in the tags assigned to the post. But I want to remove the link. Any idea?
How do I remove the link generated by the_tags?
This is what I use today: <?php the_tags( '', '', '' ); ?>
That results in the tags assigned to the post. But I want to remove the link. Any idea?
You must be logged in to post a comment.
Use following code:
More details: http://wpeden.com/tipsntuts/getting-list-of-tags-for-a-post/
Get the tag list, and then strip the tags.
This is probably a better way of doing so.
Filter the links, by stripping/removing all HTML tags from all post tag links.
Then call
the_tags
,get_the_tag_list
orget_the_terms_list
to retrieve the post tags.Note: this removes the links from post tags everywhere when called from one of the above functions, so also in your feed.