function fSelecionaCidades()
{
	var url; 
	var urlnew;
	var uf;

	uf = document.frmPesquisaCurriculos.cboEstado[document.frmPesquisaCurriculos.cboEstado.selectedIndex].value;

	if (uf == "0")
	{
		alert("Selecione um Estado!")
	}
	else
	{
		url = 'carrega_cidades.asp?uf='+ uf;
		document.frmPesquisaCurriculos.cboCidades.options.length = 0;
		iframeCidades.location = url;
	}
}
function fPopulaCidades()
{
	local = new Array();
	var maximo, i, campo;
	local = iframeCidades.a;
	campo = document.frmPesquisaCurriculos.cboCidades;
	local = iframeCidades.a;
	maximo = local.length;
	document.frmPesquisaCurriculos.cboCidades.options.length = 0;
	for (i=0;i<maximo;i++)
	{
		addItem(campo,local[i][1],local[i][0],false,campo.length);
	}
}
function addItem(obj,strText,strValue,blSel,intPos)
{ 
     var newOpt,i,ArTemp,selIndex; 
     selIndex = (blSel)?intPos:obj.selectedIndex; 
     newOpt = new Option(strText,strValue); 
     Len = obj.options.length+1 
     if (intPos > Len) return 
     obj.options.length = Len 
     if (intPos != Len) { 
          ArTemp = new Array(); 
          for(i=intPos;i<obj.options.length-1;i++) 
               ArTemp[i] = Array(obj.options[i].text,obj.options[i].value); 
          for(i=intPos+1;i<Len;i++) 
               obj.options[i] = new Option(ArTemp[i-1][0],ArTemp[i-1][1]); 
     } 
     obj.options[intPos] = newOpt; 
     if (selIndex > intPos) 
          obj.selectedIndex = selIndex+1; 
     else if (selIndex == intPos)  
          obj.selectedIndex = intPos; 
} 
function fAbreCurriculo(pagina, w, h)
{
	var wPosicaoX;
	var wPosicaoY;
	var wLargura;
	var wAltura;
	
	wLargura  = w;
	wAltura	  = h;
	wPosicaoX = ((screen.availWidth/2)  - (wLargura/2));
	wPosicaoY = ((screen.availHeight/2) - (wAltura/2) );
 
	window.open(pagina, "jnCurriculo", "width=" + wLargura + ", height=" + wAltura + ", top=" + wPosicaoY + ", left=" + wPosicaoX + ", scrollbars=yes ");
}