Reputation: 339
index.html
<td>
<div id="wrapper">
words go her alot of them
</div>
</td>
style.css
#wrapper {
height: 100%;
width: 200px;
overflow: auto;
}
I am currently unable to get the scroll bar to appear, this is what I get:
Upvotes: 1
Views: 2093
Reputation: 63
You would need to add a height to the td
tag;
Example:
height="250px"
or change your height in your #wrapper.
Upvotes: 1
Reputation: 56433
You could use the overflow
property:
#wrapper {
height: 100%;
width: 200px;
overflow: scroll;
}
The overflow
property specifies what happens if content overflows an element's box.
This property specifies whether to clip content or to add scrollbars when an element's content is too big to fit in a specified area.
Note: The overflow property only works for block elements with a specified height.
Further reading - W3Schools
Further reading - MDN
Upvotes: 3
Reputation: 109
Try setting overflow to scroll:
#wrapper {
overflow: scroll;
}
Upvotes: 1