Notice: This thread is over two years old; the information may be outdated. Please consider creating a new thread if you require free support. If you have an active SiteOrigin Premium license, you can email our premium support desk at [email protected].
Hi,
I want to Remove “Tag Archives:” and display only tag name
Is this possible?
Thanks for help
Hi Sascha
Quick question: On which page is this visible? Let me know
http://www.picturesmile.de/tag/panorama/
Hi Sascha
The Tag Archives: part of the heading tag there is no way to remove that part only without removing the entire title.
To change this you’ll need to create a child theme. If you need help with the style.css of your child theme here is an example that will work right away:
/* Theme Name: Vantage Child Author: SiteOrigin Template: vantage Version: 1.0.0 */ @import url("../vantage/style.css");Then within your child theme create a functions.php file and insert the following:
<?php function vantage_get_archive_title(){ $title = ''; if ( is_category() ) { $title = sprintf( __( 'My Category Archives: %s', 'vantage' ), '<span>' . single_cat_title( '', false ) . '</span>' ); } elseif ( is_tag() ) { $title = sprintf( __( 'Tag Archives: %s', 'vantage' ), '<span>' . single_tag_title( '', false ) . '</span>' ); } elseif ( is_author() ) { the_post(); $title = sprintf( __( 'Author Archives: %s', 'vantage' ), '<span class="vcard"><a class="url fn n" href="' . esc_url( get_author_posts_url( get_the_author_meta( "ID" ) ) ) . '" title="' . esc_attr( get_the_author() ) . '" rel="me">' . get_the_author() . '</a></span>' ); rewind_posts(); } elseif ( is_day() ) { $title = sprintf( __( 'Daily Archives: %s', 'vantage' ), '<span>' . get_the_date() . '</span>' ); } elseif ( is_month() ) { $title = sprintf( __( 'My Monthly Archives: %s', 'vantage' ), '<span>' . get_the_date( 'F Y' ) . '</span>' ); } elseif ( is_year() ) { $title = sprintf( __( 'Yearly Archives: %s', 'vantage' ), '<span>' . get_the_date( 'Y' ) . '</span>' ); } else { $title = __( 'Archives', 'vantage' ); } return apply_filters('vantage_archive_title', $title); }And edit the titles above as required.
Here is the child theme, all ready to go: https://siteorigin.com/wp-content/uploads/2014/09/vantage-child-archives-title.zip. Just install via Appearance > Themes > Add New: Upload Theme, then edit functions.php via Appearance > Editor.
NOTE:
when you install this or any child theme you’ll need to redo Appearance > Customize and Appearance > Menu settings as they will get lost.
To make it more clearer, you need to::
1. Create a child theme: https://codex.wordpress.org/Child_Themes.
2. Into that child theme goes a style.css which I’ve pasted the code for above.
3. Into that child theme goes a functions.php file which I’ve pasted the code for above.
4. ZIP your child theme once complete and upload via Appearance > Themes > Add New.
5. Activate your child theme.
6. You will then lose your settings under Appearance > Customize. You need to redo those settings.
Hope that helps.
This is a private message.
Hi,
very very good. That’s going great.
The Childtheme I had already installed.
Huge THANK YOU
Perfect :-)
Always feel free to open a new thread whenever you require support
Cheers