Online Training for Asp.net MVC Web Designing Development, MS SQL, Digital Marketing

Overflow Property in CSS, CSS Tutorial


What is overflow property?

CSS overflow property indicates what will happen if content overflows any defined container size , means contents needs more space to fit

How to write CSS overflow
div {
width: 200px;
height: 50px;
background-color: #eee;
overflow: scroll;
}

Different Values of Overflow Property
scroll When property value is scroll, then a scrollbar is added, so you can scroll to see the full content
auto When property value is scroll, then a scrollbar will appear to see the full content
visible This is Default value. It will push content outside the container (html element)
hidden Content outside the container will not be invisible

CSS Overflow property example

div {
overflow: auto;
}

div {
overflow: scroll;
}

div {
overflow: visible;
}

div {
overflow: hidden;
}


Comment
Name Email Website
Subscribe
 
Overflow Property in CSS, CSS Tutorial

Group Training