Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Border is cutting off when using border-radius?

I have an image which has a 5px border around it and I wanted to round the corners of both the image and the border, but in webkit the image remained rectangular whereas the corners of the border were rounded. As a result, the image overlapped the border and created what looks like a gap between the lines of the border at each corner.

I'd like it to look like this http://jsfiddle.net/rmi14/HWDtx/19/, but on webkit, the white background is rectangular and ends up overlapping some of the light blue border and cutting it off.

like image 718
RMi Flores Avatar asked Sep 13 '12 10:09

RMi Flores


1 Answers

You have to use the overflow property for your div as it is showed in this fiddle

Regards.

like image 120
Aymeric Avatar answered Sep 25 '22 02:09

Aymeric