Wednesday, November 10, 2010

Creating round corners using only CSS 3.0

To create rounded corners using only CSS 3, first you need to specify the border of the element then the css for the specfic browser.
You can apply this class to an element to round its border.


.round-corners
{
    border:1px solid #CCC/* Simple Border */
    border-radius:5px/*For CSS 3 supported browsers*/
    -webkit-border-radius:5px/*For google chrome and apple safari browsers*/
    -moz-border-radius:5px/*For mozilla firefox browsers*/
}