Get the tags in text format
-
Hello,
I am trying to grab just the tags used in a post. I tried searching but the keyword ‘tag’ actually pulls out other tags, instead of the function that can grab the tags of a post.I am trying to do something like this:
<?php $posttags = get_tags(); ?>
When I use the_tags(), it prints out the data but I want to store just the tags in a variable like:
<?php $tags = “tag1,tag2”; ?>
Thanks in advance for your help.
- The topic ‘Get the tags in text format’ is closed to new replies.