overflow-x and overflow-y

suggest change

These two properties work like overflow and accept the same values. overflow-x affects the horizontal axis. overflow-y affects the vertical axis. If one axis is visible and the other is not, visible is computed to auto.

HTML

<div id="div-x">
    If this div is too small to display its contents, 
    the content to the left and right will be clipped.
</div>

<div id="div-y">
    If this div is too small to display its contents, 
    the content to the top and bottom will be clipped.
</div>

CSS

div {
    width: 200px;
    height: 200px;
}

#div-x {
    overflow-x: hidden;
}

#div-y {
    overflow-y: hidden;
}

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents