Reputation: 2663
Any ideas as to how this is accomplished?
$(document).css('height', $(window).height())
$('body, html').height($(window).height())
alert('$(document).height(): ' + $(document).height() + "\n$('body').height(): " + $('body').height() + "\n$('html').height(): " + $('html').height() + '\n$(window).height(): ' + $(window).height())
Upvotes: 0
Views: 125
Reputation: 12410
Try this css:
body {
position: fixed;
top: 0;
left: 0;
bottom: 0;
right: 0;
}
Upvotes: 0
Reputation: 1987
To get get screen width and height.
alert ("screen W = " + screen.width );
alert ("screen H = " + screen.height );
Upvotes: 1