I\'m doing a simple test on $(window).height() and I\'m getting a value of 2602 on a screen resolution of 1366 x 768.
jQuery(document).ready(function($){
It is my experience that $(document).height();
is typically what you want in most scenarios. The difference being if the page is bigger than the window (has scroll bars), you will get the full height of the entire scrollable document while $(window).height()
will only get you the height of the currently sized tab.
So if you want an element to take up the full size of the window + any scrollable area below the fold $(document).height
is the way to go.
There is definitely a use case for both though.