Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // removes the tags in meta below the title
- add_filter( 'astra_post_tags', 'remove_tags_callback' );
- function remove_tags_callback(){
- return ' ';
- }
- add_action('wp', 'tags_call_back');
- function tags_call_back(){
- if( is_single() ){
- add_action( 'astra_entry_bottom' , 'add_tags_callback');
- }
- }
- // display the tags with link at the respective action hook
- function add_tags_callback(){
- $output = '';
- /* translators: used between list items, there is a space after the comma */
- $tags_list = get_the_tag_list( '', __( ', ', 'astra' ) );
- if ( $tags_list ) {
- $output .= '<span class="tags-links">' . $tags_list . '</span>';
- }
- if( ! empty($tags_list)){
- echo 'Tags: ' . $output . '';
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement