I have successfully used jQuery to append content to a div on my website.
In addition, I have applied CSS to the div with the following styling:
#data {
height: 700px;
position: absolute;
left: 0;
right: 0;
overflow-y: auto;
vertical-align: bottom;
padding-left: 10px;
margin-bottom: 110px;
font-family: 'Open Sans', sans-serif;
color: black;
}
When the content of the div exceeds its height, it automatically scrolls to the bottom. Now, I am looking to add a checkbox that will control the scrolling behavior - scrolling when checked and stopping when unchecked.
I attempted to remove the overflow-y property from the CSS but it did not produce the desired result.
Does anyone have a suggestion on how to solve this issue?