如何使用CSS来舍入我的div标签区域的角落? [英] How to use only CSS to round my div tag area's corners?
问题描述
我使用div标签来定义我的网页中的区域。
我如何使用只有 CSS
您将使用border-radius属性。但是,这只支持CSS3,没有浏览器实现。如果你只需要在几个浏览器中工作,你可以使用-webkit-border-radius和-moz-border-radius分别在Safari和Firefox中工作。
如果您不反对使用图片。这里提供的制作圆角边框的方法。
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 only CSS to round the corners?
You would use the border-radius property. However, this is only supported in CSS3, which no browser implements yet. If you only need it to work in a couple browsers you could use -webkit-border-radius and -moz-border-radius which would let it work in Safari and Firefox respectively.
If you are not opposed to using images. Here's s method I came up with for making rounded borders.
这篇关于如何使用CSS来舍入我的div标签区域的角落?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!