/********************************************************************************************
 *
 * windimension.js
 *
 * funzioni javascript che hanno a che fare con le dimensioni delle varie finestre 
 *
 * version: 1.0 2006-09-18
 * author:  Massimo Viti <mviti@lamma.rete.toscana.it>, IBIMET Firenze Italy
 *
 ********************************************************************************************/



// rende la larghezza della pagina html(document width)
function getDocumentWidth() {
  var retWidth = 0;
	
  if (typeof(document.width) == 'number')
	retWidth = document.width; // DOM
  else if (document.body && document.body.clientWidth)
	retWidth = document.body.clientWidth; //IE Mozilla 
  else if (typeof(window.innerWidth) == 'number')
	retWidth = window.innerWidth; //opera Netscape 6 Netscape 4x Mozilla 
				
  return retWidth;
}

// rende l'altezza della pagina html(document width)
function getDocumentHeight() {
  var retHeight = 0;
	
  if (document.Height)
	retHeight = document.Height; // standard
  else if (document.body.clientHeight)
	retHeight = document.body.clientHeight; //IE Mozilla 
  else if (window.innerHeight) 
    retHeight = window.innerHeight; //opera Netscape 6 Netscape 4x Mozilla 
				
  return retHeight;
}
