Diffrent Menu link color for diffrent pages

Hi Guys,

I need to change the color of the link text on my homepage's menu because I am using a transparent menu option and a dark image as background. All other pages are fine. Is there a way to do this. Ive been trying layouts option, color option and no luck.


Comments

  • Hi,

    this can be done with custom css. If you will send us link to example page, we tell you how this can be done.
  • Here it is.


    AS you can see there is no problem in the home page but then other pages with white backgrounds you cant see the link text.
  • Ok. So to change menu link color on inner pages, please use extra css:
    body:not(.home) #Top_bar .menu > li > a { color: #000 !important; }
  • Worked like a charm except 2 things
    1. Since i have another inner page with dark photo background i cant see the text link. Here is the link [Links visible only for registered users]
    2. the Hightlighted link text is black when it should be white.
    Can you help me out with this please? 
  • Hi,

    To change color & hover color please use below css with your page ID
    body.page-id-32 #Top_bar .menu > li > a {
        color: #ffffff !important;
    }

    body.page-id-32 #Top_bar .menu > li.hover > a {
        color: #000000 !important;
    }
    Thanks!
  • Thanks! It worked. I can now change menu color text on individual pages thats great, but with the top CSS i still have 2 little problems.

    1. Menu Link text on selected page is black when it should be white when selected

    2. Since all header menus on mobile devices have white backgrounds and text is also white the user can't see them.

    How can i have Black Text, white text on hover, and white text link when selected on mobile responsive menu?
  • 1. Are you sure that you used proper css for that page? Please provide the link to page where you changed menu items color with custom css so we can have a look on it.

    2. You can change menu background color on mobile then:
    #Top_bar #menu { background: #000 !important; }
  • 1. Yes. [Links visible only for registered users]

    2. Changed the Background but still having the problem with the page i previously changed the text to black. Now users cant see the menu because background is black and text is also black.
  • 1. We did checked that page and looks like everything is fine on this page. The css is:
    body.page-id-23 #Top_bar .menu > li > a {
        color: #000000 !important;
    }

    body.page-id-23 #Top_bar .menu > li.hover > a {
        color: #ffffff !important;
    }
    and it works exactly that way. Menu items are black (#000000) and are white (#FFFFFF) on hover.

    2. So what you want to to exactly? Change menu items color to white on mobile? If that's what you mean, use:
    @media only screen and (max-width: 767px) {
        #Top_bar #menu ul li a { color: #FFF !important; }
    }
Sign In or Register to comment.
This website uses cookies

We use cookies to personalise content and ads, to provide social media features and to analyse our traffic. We also share information about your use of our site with our social media, advertising and analytics partners who may combine it with other information that you’ve provided to them or that they’ve collected from your use of their services.

Cookies are small text files that can be used by websites to make a user's experience more efficient.

The law states that we can store cookies on your device if they are strictly necessary for the operation of this site. For all other types of cookies we need your permission. This means that cookies which are categorized as necessary, are processed based on GDPR Art. 6 (1) (f). All other cookies, meaning those from the categories preferences and marketing, are processed based on GDPR Art. 6 (1) (a) GDPR.

This site uses different types of cookies. Some cookies are placed by third party services that appear on our pages.

You can at any time change or withdraw your consent from the Cookie Declaration on our website.

Learn more about who we are, how you can contact us and how we process personal data in our Privacy Policy.

Please state your consent ID and date when you contact us regarding your consent.