// JavaScript Document

function Contact(){
    Contact=document.getElementById('ctl00$Body$Contact');
    Contact.value="true";   
    aspnetForm.submit();
}

function ShowMail(){
            document.getElementById('MailPanel').style.display='block';
}
    
function HideMail(){
            document.getElementById('MailPanel').style.display='none';
}

function ShowSaveVkl(){
            document.getElementById('SaveVoorkeurslijstPanel').style.display='block';
}

function HideSaveVkl(){
            document.getElementById('SaveVoorkeurslijstPanel').style.display='none';
}

function ShowSaveVoorkeurslijst(){
            document.getElementById('SaveVoorkeurslijstPanel').style.display='block';
}
    
function HideSaveVoorkeurslijst(){
            document.getElementById('SaveVoorkeurslijstPanel').style.display='none';
}

function showVgl(){
            document.getElementById('ZoekresultatenOptiesSelectie').style.display='block';
}

function verwijderVoorkeurslijst(GUID){
    var answer = confirm ("Je staat op het punt om deze voorkeurslijst te verwijderen. Klik op ok om door te gaan")
    if (answer){
        document.forms['aspnetForm'].HIDDENACTIE.value = "delete=" + GUID;
        document.forms['aspnetForm'].submit();
    }
    else
    {
        document.forms['aspnetForm'].HIDDENACTIE.value="";
    }
}

function resize(){

//getting the browser innerHeight.
    var scnHei;
	if (self.innerHeight) // all except Explorer
	{
		scnHei = self.innerHeight;
	}
	else if (document.documentElement && document.documentElement.clientHeight)
		// Explorer 6 Strict Mode
	{
		scnHei = document.documentElement.clientHeight;
	}
	else if (document.body) // other Explorers
	{
		scnHei = document.body.clientHeight;
	};
	
//getting the contentHeight
    var pageHeight;
    if( window.innerHeight && window.scrollMaxY ){ 
        // Firefox
        pageHeight = window.innerHeight + window.scrollMaxY;
    }else if(document.body.scrollHeight > document.body.offsetHeight){
        // all but Explorer Mac
        pageHeight = document.body.scrollHeight;
    }else{
        // works in Explorer 6 Strict, Mozilla (not FF) and Safari
        pageHeight = document.body.offsetHeight + document.body.offsetTop; 
    };
	
	//alert(pageHeight + ' ' + scnHei);
	
	var body = document.getElementById('maincontainer');
	if(pageHeight > scnHei){
	    body.style.height = pageHeight;
	}else if(pageHeight < scnHei){
	    body.style.height = scnHei;
	}else{
	    body.style.height = '100%';
	};
};
