• I copied and pasted the source code section that deals with the primary navigation bar.

    The Customizer does not center the navigation bar above the logo.

    Based on the classes and the Id that I located from the source code, I used the below variations to try to center the navigation bar and change the color of the text,

    I intentionally used CSS to color the (.header-col.menu-col.menu-center) green so I could see it better.

    Here are the CSS variations I used:

    Version-1

    .header-col.menu-col.menu-center {
    margin: auto !important;
    width: 100%;
    text-align: center;
    border: 3px solid green;
    }

    Version-2

    .header-col.menu-col.menu-center {
    float: right;
    width: 100%;
    text-align: center;
    border: 3px solid green;
    }

    Version-3

    .header-col.menu-col.menu-center {
    float: right;
    width: 100%;
    text-align: center;
    border: 3px solid green;
    vertical-align: top;
    }

    .menu{
    color: black !important;

    }

    Version 4

    .header-col.menu-col.menu-center {
    float: right;
    width: 100%;
    text-align: center;
    border: 3px solid green;
    vertical-align: top;
    }

    #primary-menu
    {
    color: black !important;

    }

    Nothing works.

    In the process of my searching, I found the following php snippet that you provided some time ago in one of the threads because the menu controls for the menu text is NOT included in the customizer for the updated version of Sydney that I have.

    The only problem is the php snippet now controls the footer text as well.

    Here is the php code snippet

    —–>font size option for menu item<————-

    <?php
    add_action(‘wp_enqueue_scripts’, ‘sydney_child_menu_font_size’, 9999);
    function sydney_child_menu_font_size() {

    $custom_css = ”;
    $menu_size = get_theme_mod( ‘menu_size’, ’18’ );
    if ($menu_size) {
    $custom_css .= “#mainnav ul li a { font-size:” . intval($menu_size) . “px; }”.”\n”;
    }

    wp_add_inline_style( ‘sydney-style’, $custom_css );

    }
    ?>

    ====================================================================

    I hope you are willing to help me solve this problem.

    Thank you,

    Joshua Davis

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Hi Joshua,

    Try this CSS code:

    @media only screen and (min-width: 1025px) {
      .main-header .row {
        position: relative;
      }
      .main-header .header-col.menu-col.menu-center {
        flex-shrink: 0;
        float: none;
        position: absolute;
        top: 0;
        left: 0;
      }
    }
    

    Let me know how it works for you. Thanks!

Viewing 1 replies (of 1 total)
  • The topic ‘Primary navigation bar placement and Nav text color’ is closed to new replies.