Source Code:
(back to article)
Submit
Result:
Report an issue
<!DOCTYPE html> <html> <head> <title>Title of the document</title> <style> div.scroll { background-color: #8ebf42; height: 70px; width: 150px; overflow-y: scroll; } div.hidden { background-color: #8ebf42; height: 70px; width: 150px; overflow-y: hidden; } div.auto { background-color: #8ebf42; height: 70px; width: 150px; overflow-y: auto; } div.visible { background-color: #8ebf42; height: 70px; width: 150px; overflow-y: visible; } </style> </head> <body> <h2>Overflow-y property example</h2> <h3>overflow-y: scroll</h3> <div class="scroll"> Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book </div> <h3>overflow-y: hidden</h3> <div class="hidden"> Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. </div> <h3>overflow-y: auto</h3> <div class="auto"> Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. </div> <h3>overflow-y: visible</h3> <div class="visible"> Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. </div> </body> </html>