How to remove Tags: text from the_tags?

Use something like <?php the_tags(”, ‘, ‘, ‘<br />’); ?> From WordPress codex for the_tags(): <?php the_tags( $before, $sep, $after ); ?> Parameters $before (string) Text to display before the actual tags are displayed. Defaults to Tags: $sep (string) Text or character to display between each tag link. The default is a comma (,) between … Read more

Query all posts with specific tag

It’s a lot easier to create a new WP_Query than it is to try clearing or overwriting the original. If $post_tag is a tag slug, you could simply use: <?php $the_query = new WP_Query( ‘tag=’.$post_tag ); if ( $the_query->have_posts() ) { echo ‘<ul>’; while ( $the_query->have_posts() ) { $the_query->the_post(); echo ‘<li>’ . get_the_title() . ‘</li>’; … Read more

How do I change the output of get_the_tag_list()?

So, from the get_the_tag_list() Codex entry: $before (string) (optional) Leading text. Default: ‘Tags: ‘ $sep (string) (optional) String to separate tags. Default: ‘, ‘ $after (string) (optional) Trailing text. Default: None Since you’re using this example: get_the_tag_list(‘<ul><li>’,'</li><li>’,'</li></ul>’); …edited to save space… Modify it as such: get_the_tag_list( ‘<ul><li><span>’, ‘</span></li><li><span>’, ‘</span></li></ul>’ ); …should get you what you’re … Read more

Remove a particular tag name from the tagcloud

First: Don’t touch the core files, they will be overwritten during the next update. There is already an argument for exclusions available: exclude. It expects a term id. Sample: wp_tag_cloud( array ( ‘exclude’ => 54 ) ); Sometimes you don’t know the ID, but you can get it if you know the slug: $args = … Read more

How to display the_tags() as plain text

I’m glad you figured it out, but below is a quick semantic alteration (swapping your use of $tag singular and $tags plural will help it read closer to what it is doing; functionally it is no different). I also added cases for inside and outside the Loop, and a conditional so you don’t end up … Read more

Best way to show map of tagged posts?

I would suggest rolling your own. Create a metabox that allows posts to store lats and longs on posts. Then create a page that finds all the posts with the tags that you want that can grab the lats and longs from each post meta data. Using that post meta data create a json variable … Read more

How to use the Tag description as the title attribute?

Use get_the_terms() and create a custom array: function wpse_31396_terms_with_desc( $post_id = NULL, $taxonomy = ‘post_tag’ ) { NULL === $post_id && $post_id = get_the_ID(); if ( empty ( $post_id ) ) { return ”; } $terms = get_the_terms( $post_id, $taxonomy ); if ( empty ( $terms ) ) { return ”; } $list = array … Read more

not functioning

I see several things that may be contributing to your issue. First, you’re using a custom page template to display the blog posts index, instead of using home.php as specified by the Template Hierarchy. That might be a problem, because the <!–more–> tag doesn’t work on singular pages, and since you’re doing funky things with … Read more

How can you tie into the tag metabox?

Here’s a workaround specific for the post tags meta box. We can register a custom metabox callback for the post_tag taxonomy with: add_filter( ‘register_taxonomy_args’, function( $args, $taxonomy ) { // Replace the original (post_tag) metabox callback with our wrapper if( ‘post_tag’ === $taxonomy ) $args[‘meta_box_cb’] = ‘wpse_post_tags_meta_box’; return $args; }, 10, 2 ); where our … Read more