Border Radius (1 post)

Topic tags: border radius, firefox border radius, IE border radius
  • Profile picture of borellidesigns borellidesigns said 1 year, 10 months ago:

    So you want to round your borders, but you also want to make sure they are rounded in all browsers. Well, here’s the code to make it happen across all browsers!

    CSS 3.0:
    /* 5px radius on all 4 corners of the table */
    border-radius: 5px;
    /* 5px radius on top left and bottom right corners only */
    border-radius: 5px 0 5px 0;
    /* 5px radius on bottom left and top right corners only */
    border-radius: 0 5px 0 5px;
    /* 5px radius on the top left corner only */
    border-top-left-radius: 5px;
    /* 5px radius on the bottom left corner only */
    border-bottom-left-radius: 5px;
    /* 5px radius on the top right corner only */
    border-top-right-radius: 5px;
    /* 5px radius on the bottom right corner only */
    border-bottom-right-radius: 5px;

    Webkit Browsers:
    /* Just add -webkit- in front of the CSS 3 styles */
    -webkit-border-top-right-radius: 5px;

    KHTML Border Radius:
    /* Just add -khtml- in front of the CSS 3 styles */
    -khtml-border-radius: 5px;

    Firefox:
    Firefox Border Raduis:
    /* 5px radius on all 4 corners of the table */
    -moz-border-radius: 5px;
    /* 5px radius on top left and bottom right corners only */
    -moz-border-radius: 5px 0 5px 0;
    /* 5px radius on bottom left and top right corners only */
    -moz-border-radius: 0 5px 0 5px;
    /* 5px radius on the top left corner only */
    -moz-border-radius-topleft: 5px;
    /* 5px radius on the bottom left corner only */
    -moz-border-radius-bottomleft: 5px;
    /* 5px radius on the top right corner only */
    -moz-border-radius-topright: 5px;
    /* 5px radius on the bottom right corner only */
    -moz-border-radius-bottomright: 5px;