Skip to main content

Bug Tracker

Side navigation

#12139 closed bug (fixed)

Opened July 25, 2012 03:40AM UTC

Closed October 26, 2012 04:41PM UTC

ie7 offsetParent bug

Reported by: sexnothing@gmail.com Owned by:
Priority: low Milestone: None
Component: offset Version: 1.8.0
Keywords: Cc:
Blocked by: Blocking:
Description

$("<div>").css({"position":"absolute"}).appendTo(document.body).offsetParent()[0].tagName in ie6 7

it return "HTML",not "BODY".

Attachments (0)
Change History (4)

Changed July 25, 2012 03:44AM UTC by anonymous comment:1

Changed August 14, 2012 11:04AM UTC by sindresorhus comment:2

component: unfiledoffset
priority: undecidedlow
status: newopen
version: 1.7.21.8.0

Confirmed.

Other browsers return 'body', which is the correct element to return.

Spec: http://www.w3.org/TR/cssom-view/#offset-attributes

Changed August 15, 2012 01:01AM UTC by sexnothing@gmail.com comment:3

Replying to [comment:2 sindresorhus]:

Confirmed. Other browsers return 'body', which is the correct element to return. Spec: http://www.w3.org/TR/cssom-view/#offset-attributes
in version 1.8.0,it don't fix this bug at ie7,it still return "HTML" not "BODY",i don't kown why

Changed October 26, 2012 04:41PM UTC by David Fox comment:4

resolution: → fixed
status: openclosed

Fixes #12139, make sure absolutely positioned elements have HTML as offsetParent, closes gh-1010

Changeset: 8121309694630d3cb29e5b8dc4ad81527a5bb494