Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #1182716

    Hi, how can I change the background color of a specific item on the main menu?
    I already found this in the documentation for the complete background:

    To change the background color of the main menu items go to Enfold > Advanced Styling > Main Menu Links > Background Color. To make changes using CSS please use the below code:
    /* Main menu links */
    #top #header #avia-menu li.menu-item > a {
    background-color: gold;
    }

    How can I change it only for one specific menu item?

    #1182767

    Hey Juli,

    If you inspect the element in question then you will find an ID for each of your menu items (the li element), you can use that to target the background of the link.

    Best regards,
    Rikard

    #1182777

    Hey Rikard,

    thank you for your tip! I want to have a different background for the menu item „SEMINARE“. The id of this item seems to be 10115.
    Unfortunately there is no change at all if I put this with CSS:

    #top #header #avia-menu li id=”menu-item-10115″ > a {
    background-color: gold;
    }

    Could you please have a look? I send you a temporary login.
    Best regards,
    Juli

    #1182929

    Hi,

    Please try this CSS instead:

    #top #header #avia-menu #menu-item-10115 a {
      background-color: gold;
    }

    Best regards,
    Rikard

    #1182970

    Hi Rikard,
    I tried it but unfortunately there is no change.
    Best regards,
    Juli

    #1183051

    Hi,

    Maybe because you have a caching plugin active? This code works when I test it on your site:

    #menu-item-10115 a {
      background: gold; 
    }

    Best regards,
    Rikard

    #1183184

    Hi Rikard,
    I don’t know why it is not working – even if I refresh several times, clear my cache or deactivate the caching plugin altogether.
    Still no color in the background. Do you have any other idea?
    Best regards,
    Juli

    #1183435

    Hi,

    No I don’t have any other ideas, but if you give us login details to your site then we can do it for you?

    Best regards,
    Rikard

    #1183709

    Hi Rikard,
    I already posted the login information / temporary login details on February 9th. I put the in „private content“ again.
    Thank you for your support!
    Beste regards,
    Juli

    #1183876

    Hi,

    Thanks for that. I added the CSS to the top of your Quick CSS box and it’s now applying to your site.

    Best regards,
    Rikard

    #1183990

    Yey, it works – thank you very much, Rikard!!!

    #1184069

    Hi,

    I’m glad this was resolved. If you need additional help, please let us know here in the forums.

    Best regards,
    Jordan Shannon

Viewing 12 posts - 1 through 12 (of 12 total)
  • The topic ‘Background color of one menu-item’ is closed to new replies.