[Resolved] changing navigation background color with merged header

Home Forums Support changing navigation background color with merged header

Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #327351
    Susanne Friedrich

    Hi there,
    I have made a child theme and am using a merged header on the home page, but I cannot figure out how to make the background color of the main navigation semi transparent. I keep seeing inline styles that specify a color of #222222 for the navigation background color in line 20 of the inline styles sheet.
    I am trying to apply

    .home .main-navigation{
        background: rgba(0,0,0,0,0.4);
    }

    I have use GP for several projects and never come across this issue. It must be the header. Please help. Thanks

    GeneratePress 1.3.46
    GP Premium 1.3
    #327352
    Leo
    Staff
    Customer Support

    Hi there,

    Have you tried changing it in Customizer > Colors > Primary Navigation > Background?

    Can you provide a link to your site if this doesn’t work? Thanks!

    Let me know.

    #327360
    Susanne Friedrich

    Hi Leo, You are fast 🙂
    If I change the color in the customizer I still cannot override it in my stylesheet. Thats why I think it must have something to do with the header/merged header option.
    I am developing locally right now, so can’t show you.
    Any other ideas?

    #327362
    Leo
    Staff
    Customer Support

    Sorry why would you need to override it if you can just use the customizer option?

    I’m assuming your CSS is just getting overwritten right now but hard to tell without seeing the live site.

    #327363
    Susanne Friedrich

    because I want a semi-transparent color on the homepage over the image in my header. In the rest of the site it can be the default color. I will try to make it live soon

    #327365
    Leo
    Staff
    Customer Support

    Ahh I see. Could try adding !important:

    .home .main-navigation{
        background: rgba(0,0,0,0,0.4) !important;
    }
    #327369
    Susanne Friedrich

    nope that doesn’t work either. I will post the site on my server and let you know whn its up

    #327422
    Susanne Friedrich

    ok I have put a dev site here
    http://www.duclosculturalcurrents.com
    Can you take a look?
    Thanks

    #327430
    wekhter

    Your CSS has an extra “0” in it. Each number in the array stands for the parts of RGBA (red, green, blue, alpha) so there should be 4 numbers, but you have 5.

    Update it to this:

    .home .main-navigation{
        background: rgba(0,0,0,0.4) !important;
    }
    #327432
    Leo
    Staff
    Customer Support

    Ahh it’s invalid value.

    Try something like this: background: rgba(0,0,0,0.4);

    #327434
    Leo
    Staff
    Customer Support
    #327510
    Susanne Friedrich

    Thank you both! I had a feeling it was something like that. ok all better now. You guys rock. I hope I din’t waste your time

    #327512
    Leo
    Staff
    Customer Support

    You’re welcome 🙂 Absolutely not!

Viewing 13 posts - 1 through 13 (of 13 total)
  • You must be logged in to reply to this topic.