offset

UK[ˈɒfset] US[ˈɔ:fset]

vt. Offset; compensate; (for the purpose of comparison) to juxtapose (or Juxtapose); install a branch for (pipeline, etc.)

vi. form a branch, grow a branch; install a branch

n. start; set off; lithography; offset, compensate

adj. Branch; off-centre; offset; beginning

parent

English [ˈpeərənt] US [ˈperənt]

n.Father (or mother); ancestor; root, origin; protector

jquery offsetParent() method syntax

Function:The offsetParent() method returns the nearest ancestor positioned element. A positioned element is an element whose CSS position property is set to relative, absolute, or fixed. Position can be set through jQuery, or through the CSS position property.

Syntax:$(selector).offsetParent()

jquery offsetParent() method example

    

点击下面的按钮可以设置本段落的最近的父(祖先)元素的背景色。

Run instance »

Click the "Run instance" button to view the online instance