Create an oval shape with HTML and CSS

Create an oval shape with HTML and CSS



Create class oval with a bit of css code bellow:

.oval {
  border-radius: 50%;
  height: 150px;
  width: 300px;
  background-color: #18C973;
}


Like the way to create a circle shape, but to create an oval we just change the height property to equal to 50% of the width.

In HTML code:



View more: Create a circle shape with HTML and CSS

csshtmloval cssoval html

© 2019 4codev

Created with love by Sil.