Post Tags in WordPress
-
Hey guys,
i have a simple problem.
I want use this code to print out the tags of a post:<?php $posttags = get_the_tags(); if ($posttags) { foreach($posttags as $tag) { echo $tag->name . ', '; } } ?>
The result is for example this “tag1, tag2, tag3,”
What can I do to make the last comma away.
Thank You.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Post Tags in WordPress’ is closed to new replies.