I’m trying to pull just the tag names as an array collection in order to write them out as a simple listing, without links, but the array that’s returned does not send the name as an indexible item.
array(2) {
[0]=> string(129) "<a href='#' class='tag-link-31' title='1 topic' style='font-size: 8pt;'>tag 1</a>"
[1]=> string(127) "<a href='#' class='tag-link-30' title='1 topic' style='font-size: 8pt;'>tag 2</a>"
}
Is there another method I can use to get the entire site’s tag collection with just the tag names? This is my current code, but because of the array indexes, I get the links as well.
$tagNames = wp_tag_cloud('format=array');
echo implode($tagNames,", ");
try :
and call it when you need like this
hope this helps.