CSS overflow-y ให้คุณตัดสินใจว่าจะทำอย่างไรกับขอบล่างบนของเนื้อหา คุณสามารถลองเรียกใช้รหัสต่อไปนี้เพื่อใช้คุณสมบัติ overflow-y -
ตัวอย่าง
<!DOCTYPE html>
<html>
<head>
<style>
div {
background-color: orange;
width: 250px;
height: 45px;
border: 2px solid blue;
overflow-x: hidden;
overflow-y: scroll;
}
</style>
</head>
<body>
<h1>Heading</h1>
<div>Overflow property used here. This is a demo text to show the working of CSS overflow-x and overflow-y.</div>
</body>
</html> ผลลัพธ์
