s

자바스크립트를 이용해 모니터 해상도 구하기

· 2013-04-05 (금) 01:31:50 · 4370 · 2
<script type="text/javascript">

document.write('가로: ', screen.width, '<br />', '세로: ', screen.height, '<br />');



document.write('<br /><br />'); // 줄바꿈



if ( (screen.width == 1024) && (screen.height == 768) ) {
document.write('평균적인 해상도이군요<br />');
}
else if ( (screen.width < 1024) && (screen.height < 768) ) {
document.write('저해상도이군요.<br />');
}
else if ( (screen.width > 1024) && (screen.height > 768) ) {
document.write('고해상도이군요.<br />');
}
else
document.write('비표준 해상도군요.<br />');

< /script>
|

댓글 2개

감사요~
감사합니다.
댓글을 작성하시려면 로그인이 필요합니다.

팁게시판

6,077건

디자인과 관련된 유용한 정보를 공유하세요. 질문은 상단의 QA에서 해주시기 바랍니다.

+
제목 글쓴이 날짜 조회
15-09-22 조회 2,543
15-06-10 조회 2,389
14-10-25 조회 3,472
14-10-22 조회 6,005
14-09-21 조회 2,933
14-09-16 조회 2,345
14-08-22 조회 7,662
14-08-13 조회 3,064
14-08-12 조회 2,567
14-08-12 조회 3,467
14-08-11 조회 3,852
14-06-12 조회 3,264
14-06-11 조회 2,082
14-05-09 조회 2,443
14-05-09 조회 3,282
14-05-09 조회 3,459
14-05-08 조회 2,812
13-10-30 조회 4,789
13-07-11 조회 2,673
13-03-28 조회 8,667
13-02-27 조회 4,150
13-02-14 조회 3,202
13-01-10 조회 1,936
12-12-31 조회 2,627
12-12-20 조회 3,823