Reputation: 49
The most recent Underscores theme seems to post the Page Title first then the Site Title afterwards. How can I change this to have the Site Title first?
Upvotes: 0
Views: 747
Reputation: 371
Open your header.php theme file
Add:
<title><?php bloginfo('name'); ?> <?php if ( is_single() ) { ?> » Blog Archive <?php } ?> <?php wp_title(); ?></title>
You can remove »
which looks like: » ( It's upto you )
Underscores theme is using add_theme_support() in order to support title tag as introduced in the wordpress version 4.1 and as they also mentioned in the functions.php
/*
* Let WordPress manage the document title.
* By adding theme support, we declare that this theme does not use a
* hard-coded <title> tag in the document head, and expect WordPress to
* provide it for us.
*/
add_theme_support( 'title-tag' );
Upvotes: 1