Computer >> คอมพิวเตอร์ >  >> การเขียนโปรแกรม >> CSS

จะสร้างไอคอนเมนูด้วย CSS ได้อย่างไร?


ในการสร้างไอคอนเมนูด้วย CSS โค้ดจะเป็นดังนี้ -

ตัวอย่าง

<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
div {
   width: 40px;
   height: 7px;
   background-color: blue;
   margin: 5px 2px;
}
</style>>
</head>
<body>
<h2>Sample Menu Icon</h2>
<div></div>
<div></div>
<div></div>
</body>
</html>

ผลลัพธ์

สิ่งนี้จะสร้างผลลัพธ์ต่อไปนี้ -

จะสร้างไอคอนเมนูด้วย CSS ได้อย่างไร?