Bug 19283
| Summary: | Checking offsetHeight of an element in javascript affects overall height of the page? | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Michael <michaelks> |
| Component: | Layout and Rendering | Assignee: | Nobody <webkit-unassigned> |
| Status: | NEW | ||
| Severity: | Normal | CC: | mitz |
| Priority: | P2 | ||
| Version: | 528+ (Nightly build) | ||
| Hardware: | Mac | ||
| OS: | OS X 10.5 | ||
| URL: | http://m4cb0y.homeip.net/allegory/images/gallery1.php | ||
Michael
I'm not exactly sure what this bug is, but on the latest nightly build (#34153) the footer on my site jumps up when using the lightbox gallery on my site. I've pinpointed this to line 355 in the file lytebox.js: 'document.getElementById('caption').offsetHeight'. If I comment this out it doesn't happen anymore. This only happens with the new build of WebKit; Firefox, Opera, IE, and Safari 3.1.1 render it fine.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Michael
Screenshot: http://img137.imageshack.us/img137/2633/footerbugvp5.png (the yellow footer should be all the way at the bottom)
Michael
Oops, here's the URL: http://m4cb0y.homeip.net/allegory/gallery1.php
Michael
http://m4cb0y.homeip.net/allegory/images/gallery1.php *
I wonder how many more mistakes I can make.
mitz
I think this is related to the following behavior which is reproducible on the URL: if you resize the window along the vertical axis alone, being careful not to change its width, then the footer does not move down along with the bottom of the window.
Michael
Here is where I got the code for my footer, what you described seems to happen there as well: http://www.themaninblue.com/experiment/footerStickAlt/good_example_short.htm
It also happens on most other "sticky" CSS footers I can find: http://ryanfait.com/sticky-footer/ http://www.lwis.net/profile/CSS/sticky-footer.html
Michael
The offsetHeight problem seems to be fixed now, but there's still the same issue with those footers resizing.