Skip to content

Instantly share code, notes, and snippets.

@nm-scripts
Created May 6, 2020 16:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nm-scripts/44b5e4cd92853b888f441c0a69f65a9d to your computer and use it in GitHub Desktop.
Save nm-scripts/44b5e4cd92853b888f441c0a69f65a9d to your computer and use it in GitHub Desktop.
How we can get rounded corner effect using border radius without going through the laborious process of creating images and fitting them in every item corner to create the desired effect. https://www.agernic.com/css-tutorial/css-rounded-corners.html
<!DOCTYPE html>
<html> <head>
<title>CSS Text Bold - examples - example</title>
<style>
.corner-radius1
{
border-radius:12px;
padding:10px;
width:150px;
height:100px;
background-color: #FF9;
float: left;
}
.corner-radius2
{
border-radius:12px;
padding:10px;
width:150px;
height:100px;
border: thin solid #0C0;
float: left;
margin-left: 18px;
}
.corner-radius3
{
border-radius:12px;
padding:10px;
width:150px;
height:100px;
background-image: url(https://www.agernic.com/uploads/paper.gif);
float: left;
margin-left: 18px;
}
</style>
</head>
<body>
<h1>CSS rounded corners</h1>
<div class="corner-radius1">Here your text.</div>
<div class="corner-radius2">Here your text.</div>
<div class="corner-radius3">Here your text.</div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment