The below code returns the entire height, including the area we see when we scroll down.
$(window).height();
How to find the height of the visible portion of the screen?
The below code returns the entire height, including the area we see when we scroll down.
$(window).height();
How to find the height of the visible portion of the screen?
Try this:
var w = window.innerWidth;
var h = eindow.innerHeight;
or jQuery:
var w = $(document).width();
var h = $(document).height();