/*
	filename	:	_css.js
	author		:	Annapurna Swami.
	created		:	16-04-2007
	description	:	functions for formatting of pages.
*/

//	function for setting the height of container
function calculateFormImgBrdrCssProperties() { 

		var browsernm= navigator.appName;
		if(browsernm=="Microsoft Internet Explorer")
		{
			document.getElementById("formImg").style.top=50;		
			document.getElementById("copy").style.top=40;					
		}
		else
		{
			document.getElementById("formImg").style.top=50;
			document.getElementById("copy").style.top=48;			
		}

  // Retrieve region div heights
  var headerHeight = document.getElementById("g-c").offsetHeight;
  var formHeight = document.getElementById("formContent").offsetHeight+70+8;
  var copyHeight = document.getElementById("copy").offsetHeight ;
  
  var mainRegionHeight = copyHeight > formHeight ? copyHeight+85 : formHeight;
 
	document.getElementById("g").style.height=mainRegionHeight+10+72+'px';
			
}

function openWin(page) {
    var win_width = 518;
    var win_height = 500;
    var options = "scrollbars=yes,toolbar=no,menubar=no,location=no,width=" + win_width + ", height=" + win_height;
    var win = window.open(page, 'MyWin', options);
    if (window.focus) { win.focus() }
 
}


//	functions for setting the height of container
function calculateNonFormCssProperties() {
	
	document.getElementById("g").style.height=700+'px';
    
} 


function showLayer( layerToShow ) {
            
           var layerValue = layerToShow;
            var idArray = layerArray();

              for ( var i=0; i<idArray.length; i++ ) {
                  
                  var idTmp = idArray[i];
                  if ( layerValue == idTmp ) {
                      document.getElementById( idTmp ).style.visibility='visible';
                  } else {
                      document.getElementById( idTmp ).style.visibility='hidden';
                  }
              }   

}
function checkingcheckbox(){
var check1 ="";
var check2 ="";
  check1 = document.getElementById("check1").checked;
    check2 = document.getElementById("check2").checked;
  if(!(check1 || check2)){
         alert("please select at least one from the Student Debt Partner and Tax Debt Partner");
	}
}

function doProcessing() {
  document.getElementById('submitBtn').className = 'thide'; 	
  document.getElementById('processing').className = 'tshow';
}


function doProcessingform() {
  document.getElementById('submitBtn').className = 'thide';     
  document.getElementById('processing').className = 'tshow';
}
