js读取屏幕分辨率

来源:互联网 发布:嵌入式软件规模 编辑:程序博客网 时间:2024/05/05 05:58

语法设置:

function test(){

        var width=screen.width;
        var height = screen.height;
        alert("width : "+width) ;
        alert("height : "+height) ;
        }