Skip to content

Instantly share code, notes, and snippets.

@bcole808
Created February 28, 2014 21:21
Show Gist options
  • Save bcole808/9280155 to your computer and use it in GitHub Desktop.
Save bcole808/9280155 to your computer and use it in GitHub Desktop.
This file prints out Wordpress tags in a comma separated list and shows how many times each tag is used.
<?php $tags = get_tags(array('orderby'=>'count', 'order'=> 'DESC')); ?>
<?php foreach($tags as $tag) {
echo $tag->name . ',' . $tag->slug . ',' .$tag->count;
echo '<br>';
} ?>
<?php exit; ?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment