javascript - Chrome Browser: Negative scroll on the top -


I tried this trick to stop negative scrolling on Chrome

  html {overflow : Hidden;} Body {Overflow: Auto;}  

I already have it:

  html, body {height: 100%; }  

But scroll through a document and scroll the window object with 0.

How can I stop negative scroll without affecting the document and the window object?

I also tried it

  $ (window) .on ('scroll', function (e) {if ($ (this) .scrollTop () & lt ; 0) {e .preventDefault (); e.stopPropagation ();}});  

You must also add:

  height : 100%; Width: 100%;  

to the body & amp; html


Comments

Popular posts from this blog

winforms - C# Form - Property Change -

java - Messages from .properties file do not display UTF-8 characters -

javascript - amcharts makechart not working -