Adding h1 markup to navbar-brand on front/homepage

This commit is contained in:
koenemann 2017-01-24 08:47:53 +01:00
parent 0e1d91dbb5
commit 7148f4f7b7
1 changed files with 11 additions and 4 deletions

View File

@ -45,10 +45,17 @@ $container = get_theme_mod( 'understrap_container_type' );
<!-- Your site title as branding in the menu -->
<?php if ( ! has_custom_logo() ) { ?>
<a class="navbar-brand" rel="home" href="<?php echo esc_url( home_url( '/' ) ); ?>"
title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>">
<?php bloginfo( 'name' ); ?>
</a>
<?php if ( is_front_page() && is_home() ) : ?>
<h1 class="navbar-brand mb-0"><?php bloginfo( 'name' ); ?></h1>
<?php else : ?>
<a class="navbar-brand" rel="home" href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>"><?php bloginfo( 'name' ); ?></a>
<?php endif; ?>
<?php } else {
the_custom_logo();