onclick=alert("你的顯示分辯率為:"+screen.width+"×"+screen.height)
先做好幾個(gè)頁(yè)面,比如一個(gè)htm1.htm是800*600,一個(gè)是htm2.htm是1024*768的
然后在你的入口頁(yè)面 index.htm 中判斷:
<html>
<head>
<script language=javascript>
<!--
function mHref() {
if (screen.width == 1024) location.href = "htm2.htm";
else if (screen.width == 800) location.href = "htm1.htm";
else return(false);
}
//-->
</script>
</head>
<body onload="mHref();">
</body>
</html>
********************************
聯(lián)系客服