rem: var scrollHeight=-1,windowHeight=-1,bodyHeight=-1; var marginTop = parseInt(util.Dom.getStyle(document.body, 'marginTop'), 10); var marginBottom = parseInt(util.Dom.getStyle(document.body, 'marginBottom'), 10); 
add: var scrollHeight = (document.compatMode != 'CSS1Compat') ? document.body.scrollHeight : document.documentElement.scrollHeight; 
context:       getDocumentHeight: function() {         var scrollHeight=-1,windowHeight=-1,bodyHeight=-1;         var marginTop = parseInt(util.Dom.getStyle(document.body, 'marginTop'), 10);         var marginBottom = parseInt(util.Dom.getStyle(document.body, 'marginBottom'), 10);         var mode = document.compatMode;         if ( (mode || isIE) && !isOpera ) { // (IE, Gecko)            switch (mode) {               case 'CSS1Compat': // Standards mode                  scrollHeight = ((window.innerHeight && window.scrollMaxY) ?  window.innerHeight+window.scrollMaxY : -1);                  windowHeight = [document.documentElement.clientHeight,self.innerHeight||-1].sort(function(a, b){return(a-b);})[1];                  bodyHeight = document.body.offsetHeight + marginTop + marginBottom;                  break;               default: // Quirks                  scrollHeight = document.body.scrollHeight;                  bodyHeight = document.body.clientHeight;            }         } else { // Safari & Opera            scrollHeight = document.documentElement.scrollHeight;            windowHeight = self.innerHeight;            bodyHeight = document.documentElement.clientHeight;         }         var h = [scrollHeight,windowHeight,bodyHeight].sort(function(a, b){return(a-b);});         return h[2];      },
meta: 4707	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/4707/50c3492c4c3c825dbd3401e134a19ed46799c456/dom.js/clean/www/resources/yui/dom/dom.js