CSS Scrollbars Example




CSS Scrollbars Example

<!DOCTYPE HTML>
<html>
   <head>
      <title>Scrollbars Example</title>
   </head>
   <style type="text/css">
         .scroll{
            display:block;
            border: 1px solid green;
            padding:5px;
            margin-top:5px;
            width:300px;
            height:50px;
            overflow:scroll;
         }
         .auto{
            display:block;
            border: 1px solid green;
            padding:5px;
            margin-top:5px;
            width:300px;
            height:50px;
            overflow:auto;
         }
      </style>
      
   <body>
   
      <p>Example of scroll value:</p>
      <div class="scroll">
      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>
      <br />
      
      <p>Example of auto value:</p>
      
      <div class="auto">
      It is a long established fact that a reader will be distracted by 
      the readable content of a page when looking at its layout.
		Lorem Ipsum is simply dummy text of the printing and
      typesetting industry.
      </div>
      
   </body>
</html> 

Output