/*
Kopiëren van deze javascript-code is alleen toegestaan met uitdrukkelijke 
toestemming van de programmeur of STIWOT.
Voor meer informatie: webmaster@stiwot.nl

Copying this javascript-code is only permitted with explicit
permission of the programmer or STIWOT
for more information: webmaster@stiwot.nl
*/
function resizeimagewindow() 
  {  
  var x1=window.screen.availWidth-50
  var y1=window.screen.availHeight-50
  var x2=document.images[0].width+4
  var y2=document.images[0].height+4
  if (x2 > x1 && y2 > y1)
    {
	// te breed en te lang
	window.resizeTo(x1, y1)
	document.body.style.overflowX = 'scroll'
	document.body.style.overflowY = 'scroll'
	}
  else
    {
	if (x2 > x1)
	  {
	  // te breed
	  window.resizeTo(x1, y2+67)
	  document.body.style.overflowX = 'scroll'
	  document.body.style.overflowY = 'hidden'
	  }
	else
	  {
	  if (y2 > y1 && x2 < 450)
	    {
		window.resizeTo(450, y1)
		document.body.style.overflowX = 'hidden'
        document.body.style.overflowY = 'scroll'
		}
	  else
	    {
		if (y2 > y1)
		  {
		  // te lang
		  window.resizeTo(x2+31, y1)
		  document.body.style.overflowX = 'hidden'
          document.body.style.overflowY = 'scroll'
		  }
		else
	      {
	      if (x2 < 450)
		    {
		    window.resizeTo(450, y2+45)
		    document.body.style.overflowX = 'hidden'
            document.body.style.overflowY = 'hidden'
		    }
		  else
		    {
	        window.resizeTo(x2+14, y2+45)
		    document.body.style.overflowX = 'hidden'
            document.body.style.overflowY = 'hidden'
		    }
		  }
		}
	  }
	}
  }

function popupimage(pagina)
  {
  var w = 500;
  var h = 500;    
  var topPos = 10;
  var leftPos = 10;
  window.open(pagina,'imagepopup','width=' + w + ',height=' + h + ',top=' + topPos + ',left=' + leftPos + ',scrollbars=yes');  
  }   
  
function loadpage()
  {
  framecheck()
  }
  
function contactform() 
{
	if (document.emailform.naam.value!=""&&document.emailform.email.value!=""&&document.emailform.bericht.value!="")
	return true;
	alert("U heeft niet alle velden ingevuld!");
	
	
	return false;
	}
