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

    Hi, I’m trying to add a border to the image inside a (2/5) layout element. I tried using a custom CSS class, so I can target just that image, but can’t get it to work. This is the code I’m using now:

    .kader1 {
    border: solid 2px red;
    }

    I added ‘kader1’ as custom css class to the image inside the layout element.

    Do you have any advice on how to get it to work?

    • This topic was modified 2 years, 1 month ago by rhae.
    #1369306

    Hi rhae,

    The code you gave seems correct as well as the instruction.
    Can you give us the link to the page mentioned? so that we could inspect it.

    Best regards,
    Nikko

    #1369366

    yes – but you had to know that the custom class set on image alb element goes to the top parent image container ( .avia-image-container ) of your image.
    sometimes this container is not the same dimension as the image itself ( f.e. on centering the image – you got some margins or paddings – then the border is not at the image itself. So if you like to have it on your img :

    .kader1 img {
      border: solid 2px red;
    }
    #1369397

    Hi,

    Thanks for helping out @guenni007 :-)

    Best regards,
    Rikard

    #1369470

    Thanks @guenni007, that worked like a charm :-) Solved.

    Best regards, Haiko.

    #1369475

    Hi rhae,

    We’re happy to hear that :)
    Thanks for using Enfold and have a great day!


    @Guenni007
    thanks for helping out :)

    Best regards,
    Nikko

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘How to add a border to an image inside a layout element’ is closed to new replies.