js get scroll position of page code example
Example 1: get current scroll height javascript
document.documentElement.scrollTop || document.body.scrollTop
Example 2: get current scroll height javascript
document.documentElement.scrollTop = document.body.scrollTop = 1000;