• jQuery获取或设置元素的宽度和高度


    jQuery获取或设置元素的宽度和高度:
    可使用以下3种方法:
    1,jQuery width() 和 height() 方法;
    2,innerWidth() 和 innerHeight() 方法;
    3,outerWidth() 和 outerHeight()方法。
     
    jQuery width() 和 height() 方法,innerWidth() 和 innerHeight() 方法,outerWidth() 和 outerHeight() 方法的区别如下:
    一、jQuery width() 和 height() 方法
    width() 方法设置或返回元素的宽度(不包括内边距、边框或外边距)。
    height() 方法设置或返回元素的高度(不包括内边距、边框或外边距)。
     
    二、jQuery innerWidth() 和 innerHeight() 方法
    innerWidth() 方法设置或返回元素的宽度(包括内边距)。
    innerHeight() 方法设置或返回元素的高度(包括内边距)。
     
    三、jQuery outerWidth() 和 outerHeight() 方法
    outerWidth() 方法设置或返回元素的宽度(包括内边距和边框)。
    outerHeight() 方法设置或返回元素的高度(包括内边距和边框)。
  • 相关阅读:
    Postfix之mail.cf
    利用 Postfix 抵擋垃圾信
    安装webmin
    Win7 登入提示临时漫游档案
    squid 延伸
    禁止VMware用户在系统里删除网卡的操作的方法
    Squid Proxy Server 3.1
    使用RBL拦截垃圾邮件
    建置 POSTFIX 服务器
    Seednet 访问路径
  • 原文地址:https://www.cnblogs.com/cqj98k/p/10038765.html
Copyright © 2020-2023  润新知