这个问题,可以用javascript来实现最佳。

解决方案 »

  1.   

    使用 Javascript 来控制,最简单最方便。
      

  2.   

    <script>
    var IE = ((navigator.userAgent.indexOf("Opera") == -1) && (navigator.appName) == "Microsoft Internet Explorer")?true:false;
    var browser, earStr, startIndex, endIndex, edition;
    var userAgent = navigator.userAgent;
    if (IE) {
    browser = "Microsoft Internet Explorer";
    earStr = "MSIE";
    startIndex = userAgent.indexOf(earStr) + earStr.length;
    endIndex = userAgent.indexOf(";",startIndex);
    edition = userAgent.slice(startIndex,endIndex);
    }
    document.write("您的浏览器是:" + browser + "<br>版本是:" + edition + "<br>" + "分辨率是" + screen.width + "*" + screen.height);
    </script>
      

  3.   

    要完成此效果把如下代码加入到<body>区域中<script language="JavaScript1.2"><!--var correctwidth=800var correctheight=600if (screen.width!=correctwidth||screen.height!=correctheight)document.write("本站最佳分辨率: "+correctwidth+"*"+correctheight+". 你当前的分辨率是:"+screen.width+"*"+screen.height+"。设置合适的分辨率才能取得最佳的显示效果!")//--></script>