How to create rounded corners to an Element | How to create border-radius using CSS
To create rounded corners to an
element like an image for example or a <div> we have to use the border-radius property. Here is an example:
HTML
Code
<body>
<img src="myImage.jpg"
width="375" height="300" alt="MyImage" />
</body>
CSS Code
<style>
body{ background:#000;}
img{ margin-left:25%;
margin-top:10%;
border-radius:10px;
-webkit-border-radius: 10px;
-moz-border-radius: 10px;}
</style>
Comments
Post a Comment
Thanks for Visiting for any questions or suggestions please comment below
Cheers,