function flash(file, width, height)
{
    document.write("<object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0' width='" + width + "' height='" + height + "'> \n");
    document.write("<param name='movie' value='" + file + "'>\n");
    document.write("<param name='quality' value='high'> \n");
    document.write("<param name='wmode' value='transparent'> \n");
    document.write("<embed src='" + file + "' quality='high' wmode='transparent' pluginspage='http://www.macromedia.com/go/getflashplayer' type='application/x-shockwave-flash' width='" + width + "' height='" + height + "'></embed> ");
    document.write("</object>");
}

function ajax(url,variaveis,divconteudo) {
    var http = false;
    if(navigator.appName == "Microsoft Internet Explorer") {
      http = new ActiveXObject("Microsoft.XMLHTTP");
    } else {
      http = new XMLHttpRequest();
    }
    http.onreadystatechange=function stateChanged() { 
    if (http.readyState==4 || http.readyState=="complete"){ 
           document.getElementById(divconteudo).innerHTML=http.responseText
        }else
           document.getElementById(divconteudo).innerHTML="<center><img src='carrega.gif'></center>";
    };
    http.open("GET",url+'?'+variaveis,true);
    http.send(null);
}


function noticia(valor)
{
	
	if(document.getElementById(valor).style.display=='none')
	{
		document.getElementById(valor).style.display='inline';
	}
	else
	{
		document.getElementById(valor).style.display='none';
		
	}
}


function concertaDIVIE()
{
	document.getElementById('lightwindow_overlay').style.height = '100%';
	document.getElementById('lightwindow_overlay').style.display = '';
	document.getElementById('lightwindow_overlay').style.visibility ='';
	//alert('ok');
}

function mostraCursos(valor)
{
	if(document.getElementById(valor).style.display=='none')
	{
		document.getElementById(valor).style.display='';
	}
	else
	{
		document.getElementById(valor).style.display='none';
	}
}

function mostraRecados(valor)
{
	if(document.getElementById(valor).style.display=='none')
	{
		document.getElementById(valor).style.display='';
	}
	else
	{
		document.getElementById(valor).style.display='none';
		
	}
}

function mostraTrabalho(valor)
{
	if(document.getElementById(valor).style.display=='none')
	{
		document.getElementById(valor).style.display='';
	}
	else
	{
		document.getElementById(valor).style.display='none';
		
	}
}

function expandcontract(tbodyid,ClickIcon) {
if (document.getElementById(ClickIcon).innerHTML == "+"){
document.getElementById(tbodyid).style.display = "";
document.getElementById(ClickIcon).innerHTML = "-";
} else {
document.getElementById(tbodyid).style.display = "none";
document.getElementById(ClickIcon).innerHTML = "+";
}}

function limpaCamposRecado()
{
	document.getElementById('recado_recado').value='';
}

function fechaJanelaDetalhe() {
	document.getElementById('conteudo_curso').innerHTML = "";
}





