• Resolved tecombs

    (@tecombs)


    Greetings:

    I have the typical horizontal navigation menu (HNM) at the bottom of my header, but need to know how to remove the button without making my HNM disappear.

    As it is now, the button is all but covered by my header graphic and HNM. You can barely see it, but we can’t have that.

    Would some kindly WP Guru provide the help that you do so well, please?

    TIA,
    Dave

Viewing 7 replies - 1 through 7 (of 7 total)
  • Please post the url to your site.

    Thread Starter tecombs

    (@tecombs)

    I appreciate your offer to help, however the site is still on my computer and has not been released into the wild yet. ??

    Here’s the code in question. If I knew how to apply css to the button, I’ve tried but haven’t figure it out yet, I’d put the button somewhere around -9999px to the left.

    The following resides in the header.php of an underscores theme.

    <nav id=”site-navigation” class=”main-navigation” role=”navigation”>
    <button class=”menu-toggle” aria-controls=”primary-menu” aria-expanded=”false”><?php esc_html_e( ‘Primary Menu’, ‘threestrikes’ ); ?></button>
    <?php wp_nav_menu( array( ‘theme_location’ => ‘primary’, ) ); ?>
    </nav><!– #site-navigation –>

    I even tried erasing it but my HNM disappeared also. Cain’t have that!

    Digico Paris

    (@digico-paris)

    @tecombs

    Hi, two quick ideas to fix your issue:

    1) layer depth in CSS doesn’t always work, try rather to use CSS “display:none;” on the class or id of the button or html element

    2) navigation menus are defined in functions of main theme, so if you want to add or change the way nav locations behave, it’s rather in your theme’s functions file or child one to do it the “clean” way

    Hope it helps,

    Thread Starter tecombs

    (@tecombs)

    Paris, your recommendation did the trick. I wrote to the id and poof, gone, gasphinkto, nada.

    Nice. It sure helps to another pair of eyes.

    Thanks.

    Digico Paris

    (@digico-paris)

    You’re welcome,

    After the CSS trick is fast, but bear in mind it’s better to do it well in php aka functions.php or so (plus css is not quite so so for SEO, because you might hide it with CSS but it remains in page code html render).

    Thread Starter tecombs

    (@tecombs)

    And therein lies the problem, huh?

    I’d sure like to know that code but do have the skills … yet.

    Thanks again nonetheless Paris. I’m not all that concerned about SEO just now, not with this site.

    Ciao.

    Thread Starter tecombs

    (@tecombs)

    I scooped up this kill routine from LearnWebCode. It stomps and kills thoroughly and completely just about any stubborn “whatever” that doesn’t respond to low level efforts.

    .your class-here {
    position: absolute;
    height: 0;
    width: 0;
    overflow: hidden;
    visibility: hidden;
    }

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Remove 'Primary Menu' button’ is closed to new replies.