Vishal
Vishal

Reputation: 11

how to bend border's of a div

i have a div i want the border not to be flat but bended how to do it

Current div

div{
  height:100px;
  width:100px;
  background:#000;
}
<div></div>

Here the border are flat i want it bended

Upvotes: 0

Views: 794

Answers (4)

Bishoy Bisahi
Bishoy Bisahi

Reputation: 377

using border-radius

div {
  height: 100px;
  width: 100px;
  background: #000;
  border-radius: 25px;
}
<div></div>

Upvotes: 0

Sumit patel
Sumit patel

Reputation: 3903

Using border-radius And You can Change border-radius: px

div {
  height: 100px;
  width: 100px;
  background: #000;
  border-radius: 25px;
}
<div></div>

Live Demo

Upvotes: 0

Andrei Fedorov
Andrei Fedorov

Reputation: 3977

My version differs from the others, right? )

div{
  height:100px;
  width:100px;
  background:#000;
  
  border-radius: 50%/10%;
}
<div></div>

Upvotes: 0

Prasath V
Prasath V

Reputation: 1356

This might help to you...

Use border-radius

div{
  height:100px;
  width:100px;
  background:#000;
  border: 1px solid #000;
  border-radius:4px;
}
<div></div>

Upvotes: 1

Related Questions