Site logo

Archived topic

can't get rounded corners (border-radius) to take any effect inside of posts?

3 replies · Started by Carlo on May 11, 2021

Viewing posts 1–4 of 4

i am currently trying to style my post images with a bit of shadow/border/rounded corners.

currently I've gotten the shadow and borders to take effect with some css but for the life of me I cant get the rounded corners to work.

this is the css I'm currently using:

.wp-block-image img,
.featured-image img,
.post-image img {
border-radius : 4px;
border:1px solid #ccc;
box-shadow: 0px 4px 8px 0px #ccc;
}

the border-radius takes effect in the category pages, but won't work on any of my blog posts? I cant work it out.
any help would be great
thanks

Hi there,

try this CSS:

.wp-block-image img,
.featured-image img,
.post-image img {
    border-radius: 4px !important;
    border: 1px solid #ccc;
    box-shadow: 0px 4px 8px 0px #ccc;
    overflow: hidden;
}

Thanks David,
worked perfectly! thanks so much.

Glad to be of help.

This archived topic is closed to new replies.