1
최대화 된 윈도우의 높이 = window.height()로 콘텐츠를 만들고 싶습니다. 창이 최대화되지 않은 경우 어떻게 최대화 된 창의 window.height()를 얻을 수 있습니까? screen.availheight를 사용할 때 Chrome의 하단에서 내 콘텐츠가 잘립니다.자바 스크립트 크기 조정 윈도우 크기에 상대적인 콘텐츠 크기
최대화 된 윈도우의 높이 = window.height()로 콘텐츠를 만들고 싶습니다. 창이 최대화되지 않은 경우 어떻게 최대화 된 창의 window.height()를 얻을 수 있습니까? screen.availheight를 사용할 때 Chrome의 하단에서 내 콘텐츠가 잘립니다.자바 스크립트 크기 조정 윈도우 크기에 상대적인 콘텐츠 크기
브라우저의 크기를 조정할 때 콘텐츠 창 크기를 조정하는 기능을 사용하여 ...
function resize() {
var ht;
var objDiv = document.getElementById("[YOUR DIV]");
if (typeof window.innerHeight != 'undefined') {
ht = window.innerHeight
} else if (typeof document.documentElement != 'undefined' && typeof document.documentElement.clientHeight != 'undefined' && document.documentElement.clientHeight != 0) {
ht = document.documentElement.clientHeight
}
objDiv.style.height = (ht - 100) + 'px';
return objDiv;
}
그리고이 어딘가에 전화를 ...
onresize="resize();