What is the difference between $(document).height() and $(window).height()

前端 未结 5 1521
我寻月下人不归
我寻月下人不归 2021-02-13 23:05

(Hope it is not a duplicate because I didn\'t find it when searching and googling)

I am trying to find how to detect in some fixed-height div (\'#div\') when the scroll-

5条回答
  •  情书的邮戳
    2021-02-13 23:39

    The height of the document is not necessarily the same as the height of the window. If you have a simple document with just a DIV and a little bit of text, the doc height will be miniscule compared to the height of the window.

提交回复
热议问题