function flashMenu_DoFSCommand(c, n) {
  
  try
  {
    muda_conteudo(codpag[c], n);
  }
  catch(er)
  {
    return false;
  }
}

function tipo_conteudo(nome, html) {
  
  fraConteudo.document.body.innerHTML = '';
  document.getElementById('fraConteudo').height = 0;
  document.getElementById('paginasNomer').innerHTML = '<img src="images/pix.gif" width="1" height="1">';
  
  if (nome == 'Contato' || nome == 'Intranet') {
    document.getElementById('paginasNomer').innerHTML = html;
  } else {
    document.getElementById('fraConteudo').height = iframe_height
    fraConteudo.document.body.innerHTML = html;
    fraConteudo.scrollTo(0,0);
  }
  
}

function muda_conteudo(pag, nome) {
  
  document.getElementById('paginasTitulo').innerHTML = nome;
  tipo_conteudo(nome, 'Carregando...');
  
  try {
    http = createXMLHTTP();
    http.open("post", "index.php");
    http.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
    
    http.onreadystatechange = function() {
      if (http.readyState == 4 && http.status == 200) {
        if(http.responseText) {
          tipo_conteudo(nome, http.responseText);
        }
      }
      
    }
    
    http.send('&d='+ cod +'&i='+ pag +'&n='+ nome);
    
  } catch (eee) {
    
    tipo_conteudo(nome, 'Erro ao enviar...');
    
  }
  
}
