How to use only CSS to round my div tag area's corners?

后端 未结 6 1373
感情败类
感情败类 2021-02-01 10:24

I use div tags to define areas within my web pages. I set all the obvious things like background, size, padding, etc. But it is all very square.

How can I use

6条回答
  •  走了就别回头了
    2021-02-01 10:40

    Ask google about "css rounded corners no images" and you'll find many, many examples of how to do it.

    Personally, I like the methods based on manipulating margins to draw the curve line-by-line, despite the amount of noise they produce in the page source, because they're the most flexible and can draw any shape of edge. If you're only interested in actual rounded corners (i.e., using a 90-degree circular arc), there's a much more compact solution based on some trickery with a carefully-positioned bullet.

提交回复
热议问题