Hidden text as h1 on every page. How to fix?

Hello,

On our website every page contains the site title in the header that is in the form of an h1 tag.

https://kannakart.com/

< h1 class=“visually-hidden”>Kannakart< /h1>

How can I get rid of this? I’d like to have this display as an h1 just on the home page and then have it display as an h2 or h3 on every other page.

Thanks in advance.

Hi There,

Thanks for writing in! To resolve your issue, since your have your child theme active and ready, please follow the following steps below:
1] Using Notepad or TextEdit or Sublime Text or any text editor, please create a new file in your local machine.
2] Insert the following code into that new file

<?php

// =============================================================================
// VIEWS/GLOBAL/_BRAND.PHP
// -----------------------------------------------------------------------------
// Outputs the brand.
// =============================================================================

$site_name        = get_bloginfo( 'name' );
$site_description = get_bloginfo( 'description' );
$logo             = x_make_protocol_relative( x_get_option( 'x_logo' ) );
$site_logo        = '<img src="' . $logo . '" alt="' . $site_description . '">';

?>

<a href="<?php echo home_url( '/' ); ?>" class="<?php x_brand_class(); ?>" title="<?php echo $site_description; ?>">
  <?php echo ( $logo == '' ) ? $site_name : $site_logo; ?>
</a>

3] Save the file named as _brand.php
4] Upload this file to your server in the child theme’s folder wp-content/themes/pro-child/framework/legacy/cranium/headers/views/global

You will need to create the folders because this does not exist in your Pro child theme yet.

Please let us know how it goes.

1 Like