<!--

function criar_controle_flash(arquivo,largura,altura)
{
document.write('<OBJECT codeBase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" width="'+ largura +'" height="'+ altura +'" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000">');
document.write('<PARAM NAME="_cx" VALUE="9181">');
document.write('<PARAM NAME="_cy" VALUE="7223">');
document.write('<PARAM NAME="FlashVars" VALUE="">');
document.write('<PARAM NAME="Movie" VALUE="'+ arquivo +'">');
document.write('<PARAM NAME="Src" VALUE="'+ arquivo +'">');
document.write('<PARAM NAME="WMode" VALUE="transparent">');
document.write('<PARAM NAME="Play" VALUE="1">');
document.write('<PARAM NAME="Loop" VALUE="-1">');
document.write('<PARAM NAME="Quality" VALUE="High">');
document.write('<PARAM NAME="SAlign" VALUE="">');
document.write('<PARAM NAME="Menu" VALUE="-1">');
document.write('<PARAM NAME="Base" VALUE="">');
document.write('<PARAM NAME="AllowScriptAccess" VALUE="always">');
document.write('<PARAM NAME="Scale" VALUE="ShowAll">');
document.write('<PARAM NAME="DeviceFont" VALUE="0">');
document.write('<PARAM NAME="EmbedMovie" VALUE="0">');
document.write('<PARAM NAME="BGColor" VALUE="">');
document.write('<PARAM NAME="SWRemote" VALUE="">');
document.write('<PARAM NAME="MovieData" VALUE="">');
document.write('<PARAM NAME="SeamlessTabbing" VALUE="1">');
document.write('<PARAM NAME="Profile" VALUE="0">');
document.write('<PARAM NAME="ProfileAddress" VALUE="">');
document.write('<PARAM NAME="ProfilePort" VALUE="0">');
document.write('<embed type="application/x-shockwave-flash" wmode="transparent" pluginspage="http://www.macromedia.com/go/getflashplayer" src="'+ arquivo +'" quality="high" width="'+ largura +'" height="'+ altura +'"></embed>');
document.write('</object>');
}


////////////////////////////// AJAX /////////////////////////////////
function openAjax()
{ 
	var Ajax; 
	try
	{
		Ajax = new XMLHttpRequest(); // XMLHttpRequest para browsers mais populares, como: Firefox, Safari, dentre outros. 
	}
	catch(ee) 
	{ 
		try
		{
			Ajax = new ActiveXObject("Msxml2.XMLHTTP"); // Para o IE da MS 
		}
		catch(e)
		{ 
			try
			{
				Ajax = new ActiveXObject("Microsoft.XMLHTTP"); // Para o IE da MS 
			}
			catch(e)
			{
				Ajax = false; 
			} 
		} 
	} 
	return Ajax; 
} 

function carregaAjax(id, pagina, metodo)
{ 
	if(document.getElementById)  // Para os browsers complacentes com o DOM W3C.
	{ 
		var exibeResultado = document.getElementById(id); // div que exibirá o resultado. 
		var Ajax = openAjax(); // Inicia o Ajax. 
		
		Ajax.open(metodo, pagina, true); // fazendo a requisição 
		
		Ajax.onreadystatechange = function() 
		{ 
			if(Ajax.readyState == 1) // Quando estiver carregando, exibe: carregando...
			{ 
				exibeResultado.innerHTML = "<div style='width:80px; height:18px; background-color:#CC3300; padding-left:2px; padding-top:1px;'><font color='#FFFFFF'>Carregando...</font></div>"; 
			} 
			
			if(Ajax.readyState == 4) // Quando estiver tudo pronto. 
			{
				if(Ajax.status == 200)
				{ 
					var resultado = Ajax.responseText; // Coloca o retornado pelo Ajax nessa variável 
					resultado = resultado.replace(/\+/g," "); // Resolve o problema dos acentos (saiba mais aqui: http://www.plugsites.net/leandro/?p=4) 
					resultado = unescape(resultado); // Resolve o problema dos acentos 
					exibeResultado.innerHTML = resultado; 
				}
				else
				{ 
					exibeResultado.innerHTML = "<div align='center'><strong>Erro: Problemas com a conexão.</strong></div>"; 
				} 
			} 
		} 
	Ajax.send(null); // submete 
	} 
} 
/////////////////////////////////////////////////////////////////////

///////////////////// MOSTRA SB-MENUS ///////////////////////
/*function MENU_ABRE(camada) {
	
	var list = document.getElementById(camada);
	
	if ( list.style.display=='none' )
		mudar='block';
	else
		mudar='none';
	
	document.getElementById("menu_1").style.display='none';
	document.getElementById("menu_2").style.display='none';
	document.getElementById("menu_3").style.display='none';
	document.getElementById("menu_4").style.display='none';
	
	list.style.display = mudar;

}*/
/////////////////////////////////////////////////////////////

/////////////////////////////////////////////
// FUNÇÃO PARA LIMPAR O INPUT              //
function input_limpar( elm )
{
	if (!elm.base) 
		elm.base = elm.value
		
	if (elm.value == elm.base)
		elm.value = "";
	else if (elm.value == "") 
		elm.value = elm.base;
}
/////////////////////////////////////////////

/////////////////////////////////////////////
// FUNÇÃO PARA LIMPAR O INPUT DE SENHA     //
function muda_senha( elm, novo )
{
	elm.style.display = "none";
	document.getElementById(novo).style.display = "block";
	document.getElementById(novo).focus();
}
/////////////////////////////////////////////

/////////////////////////////////////////////
// FUNÇÃO PARA MUDAR ESTILO DE UM OBJETO   //
function muda_estilo( elm, novo )
{
	//alert(elm.style.display);
	elm.className = novo;
}
/////////////////////////////////////////////

-->