고

해상도에따라 다른페이지로 접속

· 2005-09-04 (일) 14:28:38 · 3226 · 2
<html>
<HEAD>
<TITLE> </TITLE>
<SCRIPT LANGUAGE="JavaScript">

function redirectPage() {
var url640x480 = "1.html";
var url800x600 = "2.html";
var url1024x768 = "3.html";
var url1280x1024 = "4.html";
if ((screen.width == 640) && (screen.height == 480))
window.location.href= url640x480;
else if ((screen.width == 800) && (screen.height == 600))
window.location.href= url800x600;
else if ((screen.width == 1024) && (screen.height == 768))
window.location.href= url1024x768;
else window.location.href= url1280x1024;
}
// End -->
</script>
</HEAD>
<body onLoad="redirectPage()">
</body>
</html>


사용자 해상도가 640*480이면 1.html
800*600이면 2.html
1024*768이면 3.html
1280*1024이거나 이 외 해상도는 4.html 로 접속하게 됩니다.
여러가지로 응용이 되겠죠?

익스플로러&불여우에서 잘 됩니다.<div class='small'>[이 게시물은 관리자님에 의해 2011-10-31 17:16:08 PHP & HTML에서 이동 됨]</div>
|

댓글 2개

2005-11-02 (수) 00:36:41
^^
2006-03-20 (월) 13:59:58
index에 추가하면 좋겠네요. 꼭 활용하게 될듯... 감사합니다.^^
댓글을 작성하시려면 로그인이 필요합니다.

프로그램

8,188건
+
제목 글쓴이 날짜 조회
06-05-31 조회 4,134
06-05-31 조회 4,360
06-05-30 조회 3,392
06-05-26 조회 4,492
06-05-26 조회 4,778
06-05-15 조회 4,512
06-05-14 조회 5,745
06-05-12 조회 3,181
06-05-11 조회 4,593
06-05-11 조회 2,735
06-05-11 조회 2,846
06-05-11 조회 2,564
06-05-11 조회 2,833
06-05-11 조회 2,422
06-05-11 조회 2,962
06-05-10 조회 3,451
06-05-09 조회 8,126
06-05-09 조회 3,348
06-05-09 조회 3,447
06-05-07 조회 3,927
06-05-07 조회 3,020
06-05-07 조회 3,649
06-04-29 조회 3,672
06-04-28 조회 4,568
06-04-25 조회 3,477
06-04-25 조회 3,764
06-04-25 조회 3,566
06-04-22 조회 3,194
06-04-13 조회 4,516
06-04-13 조회 4,378
06-04-09 조회 3,348
06-03-30 조회 4,773
06-03-24 조회 3,606
06-03-21 조회 3,597
06-03-15 조회 4,618
06-03-11 조회 3,226
06-03-03 조회 3,471
06-02-22 조회 3,276
06-01-27 조회 3,441
06-01-05 조회 3,521
05-12-30 조회 3,371
05-12-29 조회 3,866
bbbking
05-10-22 조회 5,320
05-08-19 조회 5,527
05-08-16 조회 3,559
05-07-13 조회 4,743
05-07-11 조회 3,892
05-07-01 조회 3,494
05-07-01 조회 3,102
05-07-01 조회 3,566
bbbking
05-06-30 조회 6,277
bbbking
05-06-16 조회 6,849
05-04-04 조회 6,383
05-03-13 조회 3,273
05-03-13 조회 2,342
05-03-13 조회 2,502
04-12-16 조회 5,803
04-11-29 조회 4,173
04-11-28 조회 3,974
04-11-28 조회 3,166
04-11-28 조회 3,819
04-11-28 조회 3,588
04-11-24 조회 3,022
04-11-12 조회 3,015
04-08-24 조회 5,299
04-08-10 조회 4,497
04-08-10 조회 5,093