Modify ↓
Ticket #7496 (closed bug: worksforme)
Set Offset doesn't work correctly if page is scrolled
| Reported by: | dan@… | Owned by: | dan@… |
|---|---|---|---|
| Priority: | undecided | Milestone: | 1.5 |
| Component: | unfiled | Version: | 1.4.2 |
| Keywords: | Cc: | ||
| Blocking: | Blocked by: |
Description
Elements positioned with offset appear to be positioned to the viewport instead of to the document. So $(element).offset({left: 100, top: 100}) would position the element at top: 200 if the page was scrolled by 100 pixels.
Change History
Please follow the bug reporting guidlines and use jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.
Note: See
TracTickets for help on using
tickets.

Thanks for contributing to the jQuery project. I've created a jsFiddle for the use case you're describing but can't reproduce the problem. http://jsfiddle.net/boushley/hMCDb/1/ I'm testing this on Google Chrome on a Mac, if you could provide a reproducible test case that would be great.