CSS Overflow



The css overflow property is used to how to handle the content when it runs its block level container.

The overflow property has the following values

Example

<!DOCTYPE html>  
    <html>  
    <head>  
    <style>  
    div.scroll {  
        background-color: pink;  
        width: 100px;  
        height: 100px;  
        overflow: scroll;  
    }  
      
    div.hidden {  
        background-color: purple;  
        width: 100px;  
        height: 170px;  
        overflow: hidden;  
    }  
    </style>  
    </head>  
    <body>  
    <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. </p>  
    <p>overflow:scroll</p>  
    <div class="scroll">Lorem Ipsum is simply dummy text of the printing and typesetting industry. </div>  
    <p>overflow:hidden</p>  
    <div class="hidden">Lorem Ipsum is simply dummy text of the printing and typesetting industry. </div>  
    </body>  
    </html>  
    
     
    


Click on the "Run This Code" button to see how it works.





CSS

Welcome CSS Syntax CSS Selectors CSS ADD css CSS Borders CSS Backgrounds CSS Colors CSS Padding CSS Margin CSS Fonts CSS Text CSS Outline CSS Box-Model CSS Height&Width CSS Icons CSS Links CSS Lists CSS Display CSS Tables CSS Position CSS Overflow CSS Align CSS Float CSS Inline-block CSS Opacity CSS Image-Gallery CSS Navigation Bar CSS Dropdowns CSS Cursors CSS Forms CSS Pseudo-classes CSS Pseudo-elements

CSS3 FEATURES

CSS Gradients CSS shadows CSS 2D Transforms CSS 3D Transforms CSS Animations CSS Media Queries CSS Flexbox CSS important CSS Units