My project works on Yii 1.1.12 (and included jQuery 1.7.2). Now I'm try to update to Yii 1.1.13 (and included jQuery 1.8.3). Suddenly discover than $(window).height()
now return the document height, not window.
I'm try Yii 1.1.12 and jQuery 1.8.3 - the same result: $(window).height() = $(document).height()
. But $(window).height() less, indeed.
Return to Yii 1.1.12 and jQuery 1.7.2 - and have good result. jQuery 1.8.3 without Yii works properly.
What does it mean? In which direction I must research for solving this problem?
Solution.
It turns out, I have some files with BOM. So, they corrupted <!DOCTYPE html>
declaration (on local Windows machine), and jQuery can't works properly with this document. Now I clean BOM from files and jQuery works fine.
This problem happens when your page is rendered in quirks mode. Reference: http://bugs.jquery.com/ticket/12388
Try changing your doctype to:
You said that jQuery 1.8.3 without Yii works properly. That might be because you are using a different doctype for your non-Yii page.