Write rounded corners with CSS3 (super simple)

Source: Internet
Author: User

prefix :

-moz (e.g.-moz-border-radius) for Firefox
-webkit (for example:-webkit-border-radius) for Safari and Chrome.

CSS3 fillet (All)

Using CSS3, we can create rounded corners with a few lines of code.

This is the setting for a 5px normal border and a 15px border radius:

#roundCorderC {
font-family:arial;
border:5px solid #dedede;
-moz-border-radius:15px;
-webkit-border-radius:15px;
padding:15px 25px;
Height:inherit;
width:590px;
}

Browser support:

    • √firefox (3.05+ ...)
    • √google Chrome (1.0.154+ ...)
    • √google Chrome (2.0.156+ ...)
    • Xinternet Explorer (IE7, IE8)
    • Xopera 9.6
    • √safari (3.2.1+ windows)

CSS3 Fillet (individual)

Of course, the four corners of a div need not all rounded corners, and you can implement fillets individually.

#roundCornerI {
font-family:arial;
border:5px solid #dedede;
-moz-border-radius-topleft:15px;
-moz-border-radius-topright:0px;
-moz-border-radius-bottomright:15px;
-moz-border-radius-bottomleft:0px;
-webkit-border-top-left-radius:15px;
-webkit-border-top-right-radius:0px;
-webkit-border-bottom-left-radius:0px;
-webkit-border-bottom-right-radius:15px;
padding:15x 25px;
Height:inherit;
width:590px;
}

Browser support:

      • √firefox (3.05+ ...)
      • √google Chrome (1.0.154+ ...)
      • √google Chrome (2.0.156+ ...)
      • Xinternet Explorer (IE7, IE8)
      • Xopera 9.6
      • √safari (3.2.1+ windows)

Write rounded corners with CSS3 (super simple)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.