Advertisement
Advertisement
| 06.30.2008 at 12:34PM PDT, ID: 23528073 |
|
[x]
Attachment Details
|
||
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: |
function getPageSizeWithScroll(){
if (window.innerHeight != undefined && window.scrollMaxY != undefined) {// Firefox
yWithScroll = window.innerHeight + window.scrollMaxY;
xWithScroll = window.innerWidth + window.scrollMaxX;
}else if(window.innerHeight && document.body.scrollHeight > document.body.offsetHeight){
yWithScroll = (window.innerHeight >document.body.scrollHeight)?window.innerHeight:document.body.scrollHeight;
xWithScroll = (window.innerWidth >document.body.scrollWidth)?window.innerWidth:document.body.scrollWidth;
} else if (document.body.scrollHeight > document.body.offsetHeight){ // all but Explorer Mac
yWithScroll = document.body.scrollHeight;
xWithScroll = document.body.scrollWidth;
} else { // works in Explorer 6 Strict, Mozilla (not FF) and Safari
yWithScroll = document.body.offsetHeight;
xWithScroll = document.body.offsetWidth;
}
arrayPageSizeWithScroll = new Array(xWithScroll,yWithScroll);
return arrayPageSizeWithScroll;
}
|