• Resolved thermolis

    (@thermolis)


    Hello,

    I need help to change the menu bar color.

    I tried to modify the style.css file but I got no success.

    Many thanks,
    Thermolis

Viewing 5 replies - 1 through 5 (of 5 total)
  • The line of css that set your background-color is

    <div class=”navigation section no-padding bg-dark”>
    in the style.css class it’s located at line 195.

    The bg-dark class sets the color.

    you can create another class like bg-blue [.bg-blue{background-color:#00f}] and change the line of code to

    <div class=”navigation section no-padding bg-blue”>

    I wouldn’t change the bg-dark class it’s probably used though out your whole theme.

    Thread Starter thermolis

    (@thermolis)

    Many thanks.

    I located the line 195 in style.css but I found the following code: “.section.bg-dark { background: #1D1D1D; }”. If I change the color there I get a change in menu bar and footer, but I do not see how to add the code you suggest.

    Sorry, I’ve a really poor coding knowledge.

    Thank you for your support.

    Thermolis

    Maybe I am making it to difficult. If you want you can change the bg-dark to the color of your choice. It will effect the entire theme though not just the menu. Anywhere the bg-dark color is being used it will be reset to the color you selected. Example bg-dark { background: #ff0000; }” would change everthing to red.

    If you want to create a new style rule you will need to do it in the style.css file. You would simply define your color as a class .bg-<<mycolor>> where <<mycolor>> would be the color you want. example .bg-red{background-color:#f00;} if you prefer you can use predefined colors in html you can find a list here https://www.w3schools.com/html/html_colornames.asp.

    So you can define your color as .bg-red{background-color:red;}.

    The code where the class is defined is located in the header.php file at line 62. You will should see the line <div class=”navigation section no-padding bg-dark”> you can just change the bg-dark to the class name you defined. Example <div class=”navigation section no-padding bg-red”>

    You should be doing this in a child theme not the theme itself.

    Thread Starter thermolis

    (@thermolis)

    done. Works perfectly!

    Many thanks

    SableSol

    (@sablesol)

    Hi,

    I really need help, please. I’ve been reading all these threads and I still can’t get my menu bar changed to a different color other than black. I don’t want any black on my page other than font color. I have tried everything that has been posted and nothing works. I’m using the Hemingway theme. Please help! sablesol.com

    thanks

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Change Menu Bar color’ is closed to new replies.