js获取屏幕分辨率

<html>
<head>
  <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
  <title>显示器分辨率</title>
</head>

<body>
<script type='text/javascript'>
<!-- Begin
document.write('分辨率为:\n' + screen.width + '*' + screen.height + ' pixels');
 -->
</script>

</body>
</html>
原文地址:https://www.cnblogs.com/wowchky/p/2863126.html