D

getHtmlInfo

function getHtmlInfo()
{
var obj = {
clientHeight : 0, 
clientWidth : 0,  
scrollHeight : 0, 
scrollWidth : 0,  
scrollLeft : 0,   
scrollTop : 0,    
offsetHeight : 0, 
offsetWidth : 0 ,
screenX:0,
screenY:0
};

if (document.documentElement){
obj.clientHeight = parseInt(document.documentElement.clientHeight);
obj.clientWidth = parseInt(document.documentElement.clientWidth);
obj.scrollHeight = parseInt(document.documentElement.scrollHeight);
obj.scrollWidth = parseInt(document.documentElement.scrollWidth);

if(navigator.userAgent.indexOf("Chrome")  != -1) {
obj.scrollLeft = parseInt(document.body.scrollLeft);
obj.scrollTop = parseInt(document.body.scrollTop);
} else {
obj.scrollLeft = parseInt(document.documentElement.scrollLeft);
obj.scrollTop = parseInt(document.documentElement.scrollTop);
}
if(navigator.appName=="Netscape"){
if(navigator.userAgent.indexOf("Chrome")  != -1) {
obj.offsetHeight = parseInt(document.body.scrollTop);
obj.offsetWidth = parseInt(document.body.scrollLeft);
} else {
obj.offsetHeight = parseInt(document.documentElement.clientHeight);
obj.offsetWidth = parseInt(document.documentElement.clientWidth);
}
if(navigator.appName.indexOf("Microsoft") != -1) {
obj.offsetHeight = parseInt(document.documentElement.offsetHeight);
obj.offsetWidth = parseInt(document.documentElement.offsetWidth);
}
//if(document.body.offsetHeight) obj.offsetHeight = parseInt(document.documentElement.offsetHeight);
//else obj.offsetHeight = parseInt(document.documentElement.clientHeight);
//if(document.body.offsetWidth) obj.offsetWidth = parseInt(document.documentElement.offsetWidth);
//else obj.offsetWidth = parseInt(document.documentElement.clientWidth);

obj.screenX = parseInt(screen.width);
//alert(screen.height);
obj.screenY = parseInt(screen.height);
//alert("HEIGHT : " + document.documentElement.clientHeight);
} else if (document.body){
obj.clientHeight = parseInt(document.body.clientHeight);
obj.clientWidth = parseInt(document.body.clientWidth);
obj.scrollHeight = parseInt(document.body.scrollHeight);
obj.scrollWidth = parseInt(document.body.scrollWidth);
obj.scrollLeft = parseInt(document.body.scrollLeft);
obj.scrollTop = parseInt(document.body.scrollTop);

obj.offsetHeight = parseInt(document.body.offsetHeight);
obj.offsetWidth = parseInt(document.body.offsetWidth);
obj.screenX = parseInt(screen.width);
obj.screenY = parseInt(screen.height);

}else{
//[Netscape stuff]
}

return obj;
}
|
댓글을 작성하시려면 로그인이 필요합니다.

프로그램

태그 필터 (최대 3개) 전체 개발자 소스 기타 mysql 팁자료실 javascript php linux flash 정규표현식 jquery node.js mobile 웹서버 os 프로그램 강좌 썸네일 이미지관련 도로명주소 그누보드5 기획자 견적서 계약서 기획서 마케팅 제안서 seo 통계 서식 통계자료 퍼블리셔 html css 반응형 웹접근성 퍼블리싱 표준화 반응형웹 홈페이지기초 부트스트랩 angularjs 포럼 스크린리더 센스리더 개발자톡 개발자팁 퍼블리셔톡 퍼블리셔팁 기획자톡 기획자팁 프로그램강좌 퍼블리싱강좌
+
제목 글쓴이 날짜 조회
13년 전 조회 603
13년 전 조회 656
13년 전 조회 903
13년 전 조회 823
13년 전 조회 606
13년 전 조회 1,451
13년 전 조회 789
13년 전 조회 5,972
13년 전 조회 1,145
13년 전 조회 768
13년 전 조회 1,796
13년 전 조회 620
13년 전 조회 1,550
13년 전 조회 3,021
13년 전 조회 626
13년 전 조회 638
13년 전 조회 740
13년 전 조회 655
13년 전 조회 561
13년 전 조회 807
13년 전 조회 554
13년 전 조회 1,095
13년 전 조회 1,069
13년 전 조회 848
13년 전 조회 599
13년 전 조회 763
13년 전 조회 1,530
13년 전 조회 579
13년 전 조회 2,564
13년 전 조회 2,284
13년 전 조회 2,171
13년 전 조회 1,478
13년 전 조회 769
13년 전 조회 3,924
13년 전 조회 1,778
13년 전 조회 2,197
13년 전 조회 614
13년 전 조회 578
13년 전 조회 1,702
13년 전 조회 704
13년 전 조회 1,925
13년 전 조회 1,612
13년 전 조회 1,398
13년 전 조회 1,329
13년 전 조회 4,735
13년 전 조회 3,149
13년 전 조회 1,515
13년 전 조회 604
13년 전 조회 1,249
13년 전 조회 1,722
13년 전 조회 1,454
13년 전 조회 1,248
13년 전 조회 908
13년 전 조회 571
13년 전 조회 974
13년 전 조회 826
13년 전 조회 657
13년 전 조회 654
13년 전 조회 1,108
13년 전 조회 546
13년 전 조회 503
13년 전 조회 599
13년 전 조회 511
13년 전 조회 1,140
13년 전 조회 836
13년 전 조회 2,351
13년 전 조회 598
13년 전 조회 867
13년 전 조회 1,617
13년 전 조회 790
13년 전 조회 737
13년 전 조회 681
13년 전 조회 801
13년 전 조회 1,193
13년 전 조회 758
13년 전 조회 786
13년 전 조회 1,111
13년 전 조회 910
13년 전 조회 1,529
13년 전 조회 1,011
13년 전 조회 526
13년 전 조회 1,069
13년 전 조회 4,383
13년 전 조회 673
13년 전 조회 1,175
13년 전 조회 2,815
13년 전 조회 1,398
13년 전 조회 1,764
13년 전 조회 1,396
13년 전 조회 2,064
13년 전 조회 1,461
13년 전 조회 1,052
13년 전 조회 525
13년 전 조회 1.3만
13년 전 조회 1,309
13년 전 조회 3,438
13년 전 조회 1,076
13년 전 조회 531
13년 전 조회 711
13년 전 조회 525
🐛 버그신고