Ticket #3117 (closed bug)
$(window).height() problem in opera 9.5
| Reported by: | michalhtm | Owned by: | flesler |
|---|---|---|---|
| Priority: | major | Milestone: | 1.3 |
| Component: | dimensions | Version: | 1.2.6 |
| Keywords: | Cc: | emartin24, michalhtm | |
| Blocking: | Blocked by: |
Description
There is problem in opera 9.5 if the page is longer (scrollbars showed)
$(window).height()
returns
$(document).height()
I think repair to it is using
document.getElementsByTagName('html')[0].clientHeight
(it shows correct value)
Attachments
Change History
comment:1 Changed 5 years ago by flesler
- Owner set to flesler
- Status changed from new to assigned
- Component changed from fx to dimensions
comment:2 Changed 5 years ago by emartin24
Just wanted to check on the status...I just ran into this issue and the suggested patch seems to resolve it.
comment:3 Changed 5 years ago by flesler
That's great. Brandon is busy, but if you provide a test case where I see this patch actually working as expected, I'll commit it myself.
comment:4 Changed 5 years ago by flesler
- Cc emartin24, michalhtm added
- need changed from Review to Test Case
- Milestone set to 1.3
comment:5 Changed 5 years ago by emartin24
I put a simple page up that shows the fix in action: http://www.ericmmartin.com/code/jquery/3117/
With Opera 9.5+
- Click before, click TEST. There is supposed to be a modal dialog, but because if the incorrect height value, it is not in the viewport. Click the overlay to close it, and see the incorrect height value being reported.
- Click after, click TEST. The dialog is now in the viewport and you will see the correct height being reported.
In any other browser, both pages behave the same way.
-Eric
comment:8 Changed 3 years ago by snover
- Status changed from assigned to pending
This ticket has been marked as missing a test case. In an effort to reduce the number of outstanding tickets in the bug tracker, it will be closed automatically in 30 days. In order to prevent this from happening, please provide a working test case. If a test case has already been provided and our records are wrong, please respond to the ticket so that it can be fixed. Thank you!
Please follow the bug reporting guidlines and use jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.


I had this problem on jQuery.ScrollTo.. and I think I fixed like this (next patch). Can you apply the past and re-test please ?