Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1367816

    Hi,

    Is it possible to have an custom icon in stead of thje standard underline on hovering a menu item?
    See example in link.

    Thanks in advance

    Jasper

    #1367878

    Hi Jasper,

    Please try to add this CSS code in Enfold > General Styling > Quick CSS:
    (just change the image URL and and background size as you see fit)

    #top #header .av-main-nav > li > a:hover {
        background-image: url(https://kriesi.at/themes/enfold-2017/wp-content/uploads/sites/66/2017/02/logosquare-layer-mini.jpg);
        background-size: 20px 20px;
        background-repeat: no-repeat;
        background-position: bottom center;
    }

    Best regards,
    Nikko

    #1367949

    HI Nikko,

    Thank you so much!

    Is it also possible to keep the button active or highlighted after click?

    #1367954

    Hi,

    Please use the code as following

    
    #top #header .av-main-nav > li > a:hover,
    #top #header .av-main-nav > li.current-menu-item > a {
        background-image: url(https://kriesi.at/themes/enfold-2017/wp-content/uploads/sites/66/2017/02/logosquare-layer-mini.jpg);
        background-size: 20px 20px;
        background-repeat: no-repeat;
        background-position: bottom center;
    }
    

    Best regards,
    Yigit

    #1368436

    Hi Yigit,

    Thank you so much!

    Added media querie beccause the image appeared behind the hamburger menu and removed the standard underline. Working like a charm.

    @media only screen and (min-width: 990px) {

    #top #header .av-main-nav > li > a:hover,
    #top #header .av-main-nav > li.current-menu-item > a {
    background-image: url(https://www.bahai-uitgeverij.nl/wp-content/uploads/2022/10/lintje.png);
    background-size: 20px 34px;
    background-repeat: no-repeat;
    background-position: bottom 8px center;
    }

    .avia-menu-fx {
    display:none!important;}

    }

    #1368439

    Hi,

    Great! Glad you figured it out and thanks for sharing your solution :)

    Let us know if you have any other questions and enjoy the rest of your day!

    Best regards,
    Yigit

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘Icon on hover in stead of underline’ is closed to new replies.