Csscss (NAME|PRO|[,VAL|FN]) 1.9* Access or set the style properties of the matching element.
- A parameter for access
- Two parameters for setting
Jquery.csshooks adds a hook directly to JQuery to override the method used to set or get a particular CSS property, either to standardize the CSS property name or to create a custom property.
- It is intended to standardize CSS property names or to create custom properties.
- For example, some versions of WebKit-based browsers require the-webkit-border-radius property to set the element's Border-radius, whereas earlier versions of Firefox use the-moz-border-radius attribute. A CSS hook can standardize these prefixed attributes so that the. css () accepts a single, standard attribute name (Border-radius, or syntax with DOM attributes, Borderradius)
Position offset ([coordinates]) Gets or sets the relative offset of the matching element in the current browser window
- No parameter for Get
- There is {left: ' + ', top: ' 100 '} parameter is set
Position () Gets or sets the offset of the matching element relative to the parent element.
- No parameter for Get
- There is {left: ' + ', top: ' 100 '} parameter is set
- The returned object contains two integer properties: Top and left. To calculate the results accurately, use pixel units on the padding, border, and fill properties. This method is valid only for visible elements.
ScrollTop ([Val]) Gets or sets the offset of the matching element at the top of the scroll bar
ScrollLeft ([Val]) Gets or sets the offset of the matching element to the left of the scroll bar.
Size
Height ([val|fn]) Gets or sets the height value (px) currently calculated for the first matching element
- After JQuery 1.2 can be used to get window and document the high
Width ([VAL|FN]) Gets or sets the value (PX) of the current calculation for the first matching element
- After JQuery 1.2 can be used to obtain the width of window and document
Innerheight () Gets or sets the inner area height of the first matching element, including padding, excluding borders
- This method is valid for both visible and hidden elements
Innerwidth () Gets or sets the inner area width (including padding, excluding borders) of the first matching element
- This method is valid for both visible and hidden elements
Outerheight ([options]) Gets or sets the outer height of the first matching element (including padding and borders by default)
- This method is valid for both visible and hidden elements
Outerwidth ([options]) Gets or sets the outer width of the first matching element (including padding and borders by default)
- This method is valid for both visible and hidden elements
Front-End Learning jquery Chapter 05--Basic Operations (CSS)