获取高度或者宽度使用
$("#content").height();
$("#content").innerHeight();//元素内部区域高度,忽略padding、border
$("#content").outerHeight();//忽略边框
$("#content").outerHeight(true);//包含边框高度
$("#content").width();
$("#content").innerWidth();//元素内部区域高度,忽略padding、border
$("#content").outerWidth();//忽略边框
$("#content").outerWidth(true);//包含边框高度
jquery 获取高度、宽度
最新推荐文章于 2023-07-07 15:52:25 发布