/*********************************
	Generic - Browser Sniff
**********************************/
function browserCheck() {
	var b = navigator.appName
	if (b=="Netscape") this.b = "ns"
	else if (b=="Microsoft Internet Explorer") this.b = "ie"
	else this.b = b
	this.version = navigator.appVersion
	this.v = parseInt(this.version)
	this.ns4 = (this.b=="ns" && this.v < 5)
	this.ns6 = (this.b=="ns" && this.v >= 5)
	this.ie = (this.b=="ie" && this.v>=4)
	this.ie4 = (this.version.indexOf('MSIE 4')>0)
	this.ie5 = (this.version.indexOf('MSIE 5')>0)
	this.min = (this.ns||this.iexp)
}
is = new browserCheck();

function is_netscape4(section){
	if(is.ns4){
		window.location.href = section +"_netscape4.shtml";
	}
}

/*********************************
	Homepage - Alternate Homepages
**********************************/
function randomizer(){
	var randnum2 
	var randnum = Math.random();
	randnum2 = ((randnum*10) % 4)

	switch(parseInt(randnum2)){
		case 0:
			window.location="home/index_hiring.shtml";
			break;
		case 1:
			window.location="home/index_team.shtml";
			break;
		case 2:
			window.location="home/index_organiz.shtml";
			break;
		case 3:
			window.location="home/index_employee.shtml";
			break;
	}
	
	/*/if ((randnum > 0) && (randnum < .25)){
	//	window.location="home/index_hiring.shtml";
	}
	else if ((randnum > .25) && (randnum < .50)){
		window.location="home/index_team.shtml";
	}
	else if ((randnum > .50) && (randnum < .75)){
		window.location="home/index_organiz.shtml";
	}
	else if ((randnum > .75) && (randnum < 1)){
		window.location="home/index_employee.shtml";
	}*/
	

}

/*********************************
	Solutions - Dynamic Drop Down
**********************************/
function showmore(span_id, content){
	
	if(is.ns4){
		return;
	}
	else{
		more = document.getElementById(span_id);
		more.innerHTML = content;
	}
}

/*********************************
	Solutions - Map Area
**********************************/
function On2(location, mapimg) {
	document[mapimg].src = "imagens/loc_on_" + location + ".gif";
}
function Off2(mapimg) {
	document[mapimg].src = "imagens/spacer2.gif";
}

function imprimir(banco, id){
	var largura = 640; 
	var altura = 480; 
	var topo = ((screen.height-altura)/2); 
	var esquerda = (screen.width-largura)/2;  
	window.open('imprimir_'+banco+'.php?cod='+id+'', "", "menubar=no,location=no,resizable=yes,scrollbars=yes,status=no,width="+largura+",height="+altura+",top="+topo+",left="+esquerda+"");
	
	return false;
}

function indicar(banco, id){
	var largura = 396; 
	var altura = 200; 
	var topo = ((screen.height-altura)/2); 
	var esquerda = (screen.width-largura)/2;  
	window.open('indicar.php?tipo='+banco+'&cod='+id+'', "", "menubar=no,location=no,resizable=yes,scrollbars=yes,status=no,width="+largura+",height="+altura+",top="+topo+",left="+esquerda+"");
	
	return false;
}

