您好,欢迎访问一九零五行业门户网

关于jquery css的使用介绍_jquery

jquery 操作 cssaddclass() - 向被选元素添加一个或多个类 removeclass() - 从被选元素删除一个或多个类 toggleclass() - 对被选元素进行添加/删除类的切换操作 css() - 设置或返回被选元素的一个或多个样式属性。jquery css() 方法
〈1〉返回 css 属性
css(propertyname);
〈2〉设置 css 属性
css(propertyname,value);
〈2.1〉设置多个 css 属性
css({propertyname:value,propertyname:value,...});
jquery 尺寸 方法jquery 提供多个处理尺寸的重要方法:
width() 设置或返回元素的宽度(不包括内边距、边框或外边距)。 height() 设置或返回元素的高度(不包括内边距、边框或外边距)。 设置:$(#div1).width(500).height(500); more : $(window/document).width/height;
innerwidth() 返回元素的宽度(包括内边距)。 innerheight() 返回元素的高度(包括内边距)。 outerwidth() 返回元素的宽度(包括内边距、边框和外边距)。 outerheight() 返回元素的高度(包括内边距、边框和外边距)。
其它类似信息

推荐信息