Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1188707
    Kilmanagh
    Participant

    Is there a way to get rid of the <h1 class=”visually-hidden”>”Name of Website”</h1> when using a graphic logo instead of an image? This is in the Icon Stack.
    I use an image instead of the logo. Even though it is invisible on the browser, the search engines pick it up and I get multiple <h1> tag warnings. It totally makes it impossible to have any <h1>’s on a page without being penalized.

    thank you

    #1188781
    Prasant Rai
    Moderator

    Hello There,

    Thanks for writing in! To assist you with this issue, we’ll first need you to provide us with your URL. This is to ensure that we can provide you with a tailored answer to your situation. Once you have provided us with your URL, we will be happy to assist you with everything.

    Thanks.

    #1189371
    Kilmanagh
    Participant
    This reply has been marked as private.
    #1189527
    Friech
    Moderator

    Hi There,

    Thanks for writing in! Because this requires a template change, I’d advise that you setup a child theme. This allows you to make code changes that won’t be overwritten when an X update is released. After your child theme is setup, please review how we recommend making template changes in Customization Best Practices.

    Then on your child theme navigate to this directory x-child\framework\views\global\. In there create a file named _brand.php and paste the code below on it.

    <?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 . '">';
    
    ?>
    
    <?php /*echo ( is_front_page() ) ? '<h1 class="visually-hidden">' . $site_name . '</h1>' : '';*/ ?>
    
    <a href="<?php echo home_url( '/' ); ?>" class="<?php x_brand_class(); ?>" title="<?php echo $site_description; ?>">
      <?php echo ( $logo == '' ) ? $site_name : $site_logo; ?>
    </a>

    Hope it helps, Cheers!

  • <script> jQuery(function($){ $("#no-reply-1188707 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>