Rounded Corner

ជាមួយ​នឹង​ property border-radius យើង​អាច​ជ្រើសរើស​យក element ផ្សេង​ៗ​មក​កែច្នៃ​អោយ​មាន​ជ្រុង​រាង​មូល​បាន​តាម​សេចក្តី​ត្រូវការ​។

<!DOCTYPE html>
<html>
  <head>
  	<meta charset="UTF-8"/>
    <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
  	<title>Rounded Corner</title>
    <style>
      #rcorners1 {
  		border-radius: 25px;
  		background: #73AD21;
 		padding: 20px; 
  		width: 200px;
  		height: 150px;  
	  }

	  #rcorners2 {
  		border-radius: 25px;
  		border: 2px solid #73AD21;
  		padding: 20px; 
  		width: 200px;
  		height: 150px;  
	  }

	 #rcorners3 {
  		border-radius: 25px;
  		background: url(paper.gif);
  		background-position: left top;
  		background-repeat: repeat;
  		padding: 20px; 
  		width: 200px;
  		height: 150px;  
	  }
    </style>
  </head>
  
  <body>
	

The border-radius Property

Rounded corners for an element with a specified background color:

Rounded corners!

Rounded corners for an element with a border:

Rounded corners!

Rounded corners for an element with a background image:

Rounded corners!

</body> </html>

The border-radius Property

Rounded corners for an element with a specified background color:

Rounded corners!

Rounded corners for an element with a border:

Rounded corners!

Rounded corners for an element with a background image:

Rounded corners!


ក្នុង​ករណី​យើង​ចង់​កែច្នៃ​រចនា element ទាំងឡាយ​អោយ​មាន​ជ្រុង​មាន​រាង​មូល​ខុស​ៗ​គ្នា យើង​ត្រូវ​ធ្វើ​ដូច​ខាង​ក្រោម​នេះ៖

<!DOCTYPE html>
<html>
  <head>
  	<meta charset="UTF-8"/>
    <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
  	<title>Rounded Corner</title>
    <style>
      #rcorners1 {
  		border-radius: 15px 50px 30px 5px;
  		background: #73AD21;
  		padding: 20px; 
  		width: 200px;
  		height: 150px; 
	  }

	  #rcorners2 {
  		border-radius: 15px 50px 30px;
  		background: #73AD21;
  		padding: 20px; 
  		width: 200px;
  		height: 150px; 
	  }

	  #rcorners3 {
  		border-radius: 15px 50px;
  		background: #73AD21;
  		padding: 20px; 
  		width: 200px;
  		height: 150px; 
	  } 

	  #rcorners4 {
  		border-radius: 15px;
  		background: #73AD21;
  		padding: 20px; 
  		width: 200px;
  		height: 150px; 
	  } 
    </style>
  </head>
  
  <body>
	

The border-radius Property

Four values - border-radius: 15px 50px 30px 5px:

Three values - border-radius: 15px 50px 30px:

Two values - border-radius: 15px 50px:

One value - border-radius: 15px:

</body> </html>

The border-radius Property

Four values - border-radius: 15px 50px 30px 5px:

Three values - border-radius: 15px 50px 30px:

Two values - border-radius: 15px 50px:

One value - border-radius: 15px: