function popup_informativo(Code){
	switch(Code){
		case 1:
		tb_show('<p class="Estilo1">Qui&eacute;nes somos</p>', concamin_base_path+'/formas/1/?KeepThis=true&TB_iframe=true&height=150&width=500');
		break;
		case 2:
		tb_show('<p class="Estilo1">C&aacute;maras</p>', concamin_base_path+'/formas/2/?KeepThis=true&TB_iframe=true&height=120&width=500');
		break;
		case 3:
		tb_show('<p class="Estilo1">Contacto</p>', concamin_base_path+'/formas/3/?KeepThis=true&TB_iframe=true&height=100&width=500');
		break;
		case 4:
		tb_show('<p class="Estilo1">Crear Tema en el Foro</p>', concamin_base_path+'/node/add/forum/1537?TB_iframe=true&height=500&width=600');
		break;
	}
}
function popup(nid,tipo2){
	nodal=nid;
	tipo=tipo2;
	tb_show('<p class="Estilo1">Reportar Contenido con el Administrador</p>', concamin_base_path+'/report/node/'+nid+'?KeepThis=true&TB_iframe=true&height=100&width=500');
	
	}
function popup_user_edit(a_user){
tipo=999;
	tb_show('<p class="Estilo1">Editar datos de la cuenta</p>', concamin_base_path+'/users33/'+a_user+'?KeepThis=true&TB_iframe=true&height=400&width=500');
	
	}
function popup_user_edit2(a_user){
tipo=999;
	tb_show('<p class="Estilo1">Editar datos personales</p>', concamin_base_path+'/users32/'+a_user+'?KeepThis=true&TB_iframe=true&height=400&width=500');
	
	}
function popup_recordar(){

	tb_show('<p class="Estilo1">Proporcione sus datos</p>', concamin_base_path+'/user/password?KeepThis=true&TB_iframe=true&height=400&width=500');
	
	}
function contribuir_user(a_user){

	tb_show('<p class="Estilo1">Contribuir con Informacion</p>', concamin_base_path+'/node/add/article?KeepThis=true&TB_iframe=true&height=400&width=650');
	
	}
function contact_user(u_uid){
	tb_show('<p class="Estilo1">Contactar con usuario</p>', concamin_base_path+'/report/contact/'+u_uid+'?KeepThis=true&TB_iframe=true&height=200&width=550');
	
	}
function ver_usera(u_nid){
	tb_show('<p class="Estilo1">Ver articulo de usuario</p>', concamin_base_path+'/watch/articles/'+u_nid+'?KeepThis=true&TB_iframe=true&height=400&width=650');
	
	}

function comentar(nid,tipo2){
	nodal=nid;
	tipo=tipo2;
	tb_show('<p class="Estilo1">Da tu comentario</p>', concamin_base_path+'/comenta/node/'+nid+'?KeepThis=true&TB_iframe=true&height=200&width=500');
	
	}
function comentar_special(nid,tipo2){
	nodal=nid;
	tipo=tipo2;
	tb_show('<p class="Estilo1">Da tu comentario</p>', concamin_base_path+'/comenta/node/'+nid+'?KeepThis=true&TB_iframe=true&height=200&width=500');
	
	}
function login(){
	tb_show('<p class="Estilo1">No estas autentificado, porfavor proporciona tu usuario y password</p>', concamin_base_path+'/loguser/node?TB_iframe=true&height=300&width=300');
	
	}
function popupAnswer(nid,tipo2,preg){
	nodal=nid;
	tipo=tipo2;
	tb_show('<p class="Estilo1">Responder pregunta</p>', concamin_base_path+'/report/node/'+preg+'?KeepThis=true&TB_iframe=true&height=200&width=500');
	
	}
function answerQuestion(preg,tipo2){
	nodal=preg;
	tipo=tipo2;
	tb_show('<p class="Estilo1">Responder pregunta</p>', concamin_base_path+'/answer/question/'+preg+'?KeepThis=true&TB_iframe=true&height=300&width=500');
	
	}
	function cerrar(){
		window.parent.TB_remove();
	}
function askQuestion(){
	tipo=99;
	preg=proceso_pertenece;

	tb_show('<p class="Estilo1">Realizar una pregunta</p>', concamin_base_path+'/make/question/'+preg+'?KeepThis=true&TB_iframe=true&height=300&width=500');
	
	}
var guias=0;
numer=0;
function guia(numer,inser){
	guias=numer;
	special();
	
	
}
function special(){
	document.getElementById("list_informacion").className = 'on';
	document.getElementById('titulo-seccion').innerHTML='Informacion';
		document.getElementById("list_colaboracion").className = 'off';
		document.getElementById("list_ofertas").className = 'off';
		document.getElementById("list_guias").className = 'off';
		document.getElementById("Pre").innerHTML = '<div class="clearfix"><input name="radiobutton" type="radio" value="radiobutton" onclick="JavaScript:tabla2(20);" /> &nbsp;Articulos &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <input name="radiobutton" type="radio" value="radiobutton" onclick="JavaScript:tabla2(21);" />&nbsp;Noticias &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  <input name="radiobutton" type="radio" value="radiobutton" onclick="JavaScript:tabla2(22);" checked="checked"  />  Guias</div>';
	tabla2_special(23);
	
	
	
}

function select_this_special(trim){
	if (http.status == 200) 
           {
			   setTimeout("select_this(272,8);",10000);

           } 
}
	
function getValue(radioGroupName) {
        radios = document.getElementsByName(radioGroupName);
        for (i = 0; i < radios.length; i++) {
            if (radios[i].checked) return radios[i].value;
        }
    }
var tipo=1;
var nodal=1;

function select_this(Node,Process){
	
	if (document.getElementById('Activo')){
	var new_id=document.getElementById('Activo').getAttribute('nodo');
	document.getElementById('Activo').id='nada'+new_id;
	}
	
	document.getElementById('nada'+Node).id='Activo';
	
	var miAleatorio=parseInt(Math.random()*99999999);
	if (Process==1)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso3/bring_node/"+Node+"/" + miAleatorio, true);  
	}
	if (Process==2)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso1/bring_node/"+Node+"/" + miAleatorio, true);	
	}
	if (Process==3)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso4/bring_node/"+Node+"/" + miAleatorio, true); 	
	}
	if (Process==4)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso5/bring_node/"+Node+"/" + miAleatorio, true); 	
	}
	if (Process==5)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso6/bring_node/"+Node+"/" + miAleatorio, true); 	
	}
	if (Process==6)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso7/bring_node/"+Node+"/" + miAleatorio, true); 	
	}
	if (Process==7)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso8/bring_node/"+Node+"/" + miAleatorio, true); 	
	}
	if (Process==8)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso9/bring_node/"+Node+"/" + miAleatorio, true); 	
	}

	http.onreadystatechange = useHttpResponse3; 
    http.send(null);

	}
	
	function select_guia_u(Node){
	tipo=199;

	Process=8;
	var miAleatorio=parseInt(Math.random()*99999999);

	if (Process==8)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso9/bring_node_4u/"+Node+"/" + miAleatorio, true); 	
	}

	http.onreadystatechange = useHttpResponse3; 
    http.send(null);

	}
	
function select_this_u(Node){
	tipo=199;

	

	Process=6;
	var miAleatorio=parseInt(Math.random()*99999999);

	if (Process==6)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso7/bring_node_4u/"+Node+"/" + miAleatorio, true); 	
	}

	http.onreadystatechange = useHttpResponse3; 
    http.send(null);

	}

function select_this_user(Node,Process){
	
	if (document.getElementById('Activo')){
	var new_id=document.getElementById('Activo').getAttribute('nodo');
	document.getElementById('Activo').id='nada'+new_id;
	}
	
	document.getElementById('nada'+Node).id='Activo';
	
	var miAleatorio=parseInt(Math.random()*99999999);
	if (Process==1)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso3/bring_node/"+Node+"/" + miAleatorio, true);  
	}
	if (Process==2)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso1/bring_node/"+Node+"/" + miAleatorio, true);	
	}
	if (Process==3)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso4/bring_node/"+Node+"/" + miAleatorio, true); 	
	}
	if (Process==4)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso5/bring_node/"+Node+"/" + miAleatorio, true); 	
	}
	if (Process==5)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso6/bring_node/"+Node+"/" + miAleatorio, true); 	
	}
	if (Process==6)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso7/bring_node/"+Node+"/" + miAleatorio, true); 	
	}
	if (Process==7)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso8/bring_node/"+Node+"/" + miAleatorio, true); 	
	}
	if (Process==8)
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso9/bring_node/"+Node+"/" + miAleatorio, true); 	
	}

	http.onreadystatechange = useHttpResponse10; 
    http.send(null);

	}

	
function llamame(pesado){
	$(pesado).click(function(){
	var t = this.title || this.name || null;
	var nid= this.title;
	var a = concamin_base_path+"/report/node?KeepThis=true&TB_iframe=true&height=400&width=600";
	var g = this.rel || false;
	tb_show(t,a,g);
	this.blur();
	if($.browser.msie) $("select, object").hide();
	return false;
	});
	llamame(pesado);
}

function getXMLHTTPRequest(){
var xmlhttp=false;
try {
xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
} catch (e) {
try {
xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
} catch (E) {
xmlhttp = false;
}
}

if (!xmlhttp && typeof XMLHttpRequest!='undefined') {
xmlhttp = new XMLHttpRequest();
}
return xmlhttp;
}
var http = getXMLHTTPRequest();


function crearMenu(Menu){
						$("#Pre").hide("Slow");
						setTimeout("presionado("+Menu+")",500);
						 }
function presionado(d){
	
	switch(proceso_pertenece){
		case "1331":
		  background="yellow";
		  esquina="amarillo";
		break;
		case "1332":
		  background="pink";
		  esquina="rosa";
		break;
		case "1333":
		  background="orange";
		  esquina="naranja";
		break;
		case "1334":
		  background="green";
		  esquina="verde";
		break;
		case "1335":
		  background="sblue";
		  esquina="acielo";
		break;
		case "1336":
		  background="beige";
		  esquina="beige";
		break;
		default:
		  background="purple";
		  esquina="morado";
		break;
	}

	if(d==1){
		document.getElementById("filtro-busqueda").style.display = 'block';
		document.getElementById('titulo-seccion').innerHTML='Apoyos Privados';
		document.getElementById('pasos1').innerHTML ='<img alt="" src="../images/varios/bg_nrobot_mleft.jpg"/><img alt="" src="../images/varios/esq_gris_azul.jpg"/><div style="width: 65px;" class="sn_elem bg_blue"><h3 class="pTop25"><a href="JavaScript:crearMenu(5);">Guías</a></h3></div><img alt="" src="../images/varios/esq_azul_gris.jpg"/><div style="width: 112px;" class="sn_elem bg_gray"><h3 class="pTop15"><a href="JavaScript:crearMenu(6)">Apoyos <br/> de Gobierno</a></h3></div><img alt="" src="../images/varios/esq_gris_'+esquina+'.jpg"/><div style="width: 85px;" class="sn_elem bg_'+background+'"><h3 class="pTop15"><a href="JavaScript:crearMenu(1);">Apoyos <br/> Privados</a></h3></div><img alt="" src="../images/varios/esq_'+esquina+'_gris.jpg"/><div style="width: 112px;" class="sn_elem bg_gray"><h3 class="pTop25"><a href="JavaScript:crearMenu(2);">Información</a></h3></div><img alt="" src="../images/varios/esq_gris_azul.jpg"/><div style="width: 100px;" class="sn_elem bg_blue"><h3 class="pTop25"><a href="JavaScript:crearMenu(3)">Colaboración</a></h3></div>';
		
		        document.getElementById("Pre").innerHTML ='<p><input id="Oculta" name="radiobutton" type="radio" value="radiobutton" onclick="JavaScript:tabla2(1);" checked="checked" />Financiamiento&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input id="radio" name="radiobutton" type="radio" value="radiobutton" onclick="JavaScript:tabla2(2);" />Educaci&oacute;n / Capacitaci&oacute;n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input id="radio2" name="radiobutton" type="radio" value="radiobutton" />Servicios&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;';
				tabla2(1);
				$("#Pre").show("Fast");
	}
	if (d==2){
		document.getElementById("filtro-busqueda").style.display = 'block';
		document.getElementById('titulo-seccion').innerHTML='Informacion';
		document.getElementById("Pre").innerHTML = '<div class="clearfix"><div class="clearfix"><input type="radio" checked="checked" onclick="JavaScript:tabla2(20);" value="radiobutton" name="radiobutton"/>  Articulos                <input type="radio" onclick="JavaScript:tabla2(21);" value="radiobutton" name="radiobutton"/> Noticias</div></div>';
		document.getElementById("pasos1").innerHTML='<img src="../images/varios/bg_nrobot_mleft.jpg" alt=""/><img src="../images/varios/esq_gris_azul.jpg" alt=""/><div class="sn_elem bg_blue" style="width: 65px;"><h3 class="pTop25"><a href="JavaScript:crearMenu(5);">Guías</a></h3></div><img src="../images/varios/esq_azul_gris.jpg" alt=""/><div class="sn_elem bg_gray" style="width: 112px;"><h3 class="pTop15"><a href="JavaScript:crearMenu(6)">Apoyos <br/> de Gobierno</a></h3></div><img src="../images/varios/esq_gris_azul.jpg" alt=""/><div class="sn_elem bg_blue" style="width: 85px;"><h3 class="pTop15"><a href="JavaScript:crearMenu(1);">Apoyos <br/> Privados</a></h3></div><img src="../images/varios/esq_azul_'+esquina+'.jpg" alt=""/><div class="sn_elem bg_'+background+'" style="width: 112px;"><h3 class="pTop25"><a href="JavaScript:crearMenu(2);">Información</a></h3></div><img src="../images/varios/esq_'+esquina+'_azul.jpg" alt=""/><div class="sn_elem bg_blue" style="width: 100px;"><h3 class="pTop25"><a href="JavaScript:crearMenu(3)">Colaboración</a></h3></div>';
		
			tabla2(20);
			$("#Pre").show("Fast");
		
		
		
	}
	if (d==3){
		document.getElementById("filtro-busqueda").style.display = 'block';
		document.getElementById('titulo-seccion').innerHTML='Colaboracion';
		document.getElementById("Pre").innerHTML = '<div class="clearfix"><input name="radiobutton" type="radio" value="radiobutton" onclick="JavaScript:tabla2(10);" checked="checked" /> &nbsp;Preguntas y respuestas &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <input name="radiobutton" type="radio" id="guia" value="radiobutton" onclick="JavaScript:tabla2(12);" />&nbsp;Colaboradores &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </div>';
		document.getElementById("pasos1").innerHTML='<img alt="" src="../images/varios/bg_nrobot_mleft.jpg"/><img alt="" src="../images/varios/esq_gris_azul.jpg"/><div style="width: 65px;" class="sn_elem bg_blue"><h3 class="pTop25"><a href="JavaScript:crearMenu(5);">Guías</a></h3></div><img alt="" src="../images/varios/esq_azul_gris.jpg"/><div style="width: 112px;" class="sn_elem bg_gray"><h3 class="pTop15"><a href="JavaScript:crearMenu(6)">Apoyos <br/> de Gobierno</a></h3></div><img alt="" src="../images/varios/esq_gris_azul.jpg"/><div style="width: 85px;" class="sn_elem bg_blue"><h3 class="pTop15"><a href="JavaScript:crearMenu(1);">Apoyos <br/> Privados</a></h3></div><img alt="" src="../images/varios/esq_azul_gris.jpg"/><div style="width: 112px;" class="sn_elem bg_gray"><h3 class="pTop25"><a href="JavaScript:crearMenu(2);">Información</a></h3></div><img alt="" src="../images/varios/esq_gris_'+esquina+'.jpg"/><div style="width: 100px;" class="sn_elem bg_'+background+'"><h3 class="pTop25"><a href="JavaScript:crearMenu(3)">Colaboración</a></h3></div><img alt="" src="../images/varios/esq_'+esquina+'_azul.jpg"/>';
		tabla2(10);
		$("#Pre").show("Fast");
	}
	if (d==4){
		var miAleatorio=parseInt(Math.random()*99999999);
		http.open("GET", concamin_base_path+"/dbcustom/ajax/getuser/check_login/" + miAleatorio, true); 	
		http.onreadystatechange = useHttpResponse6;
    	http.send(null);
$("#Pre").show("Fast");
		
	}
	if (d==5){
			$("#Pre").hide("Slow");
		document.getElementById('titulo-seccion').innerHTML='Guías';
		document.getElementById("Pre").innerHTML = '<div class="clearfix"></div>';
		document.getElementById("pasos1").innerHTML = '<img src="../images/varios/bg_nrobot_mleft.jpg" alt="" /><img src="../images/varios/esq_gris_'+esquina+'.jpg" alt="" /><div class="sn_elem bg_'+background+'" style="width: 65px;"><h3 class="pTop25"><a href="JavaScript:crearMenu(5);">Guías</a></h3></div><img src="../images/varios/esq_'+esquina+'_gris.jpg" alt="" /><div class="sn_elem bg_gray" style="width: 112px;"><h3 class="pTop15"><a href="JavaScript:crearMenu(6)">Apoyos <br/> de Gobierno</a></h3></div><img src="../images/varios/esq_gris_azul.jpg" alt="" /><div class="sn_elem bg_blue" style="width: 85px;"><h3 class="pTop15"><a href="JavaScript:crearMenu(1);">Apoyos <br/> Privados</a></h3></div><img src="../images/varios/esq_azul_gris.jpg" alt="" /><div class="sn_elem bg_gray" style="width: 112px;"><h3 class="pTop25"><a href="JavaScript:crearMenu(2);">Información</a></h3></div><img src="../images/varios/esq_gris_azul.jpg" alt="" /><div class="sn_elem bg_blue" style="width: 100px;"><h3 class="pTop25"><a href="JavaScript:crearMenu(3)">Colaboración</a></h3></div>';
		document.getElementById("filtro-busqueda").style.display = 'none';
		tabla2(22);
	}
	if (d==6){
		document.getElementById("filtro-busqueda").style.display = 'block';
		document.getElementById('titulo-seccion').innerHTML='Apoyos de Gobierno';
		document.getElementById("Pre").innerHTML = '<div class="clearfix"></div>';
		document.getElementById("pasos1").innerHTML='<img src="../images/varios/bg_nrobot_mleft.jpg" alt=""/><img src="../images/varios/esq_gris_azul.jpg" alt=""/><div class="sn_elem bg_blue" style="width: 65px;"><h3 class="pTop25"><a href="JavaScript:crearMenu(5);">Guías</a></h3></div><img src="../images/varios/esq_azul_'+esquina+'.jpg" alt=""/><div class="sn_elem bg_'+background+'" style="width: 112px;"><h3 class="pTop15"><a href="JavaScript:crearMenu(6)">Apoyos <br/> de Gobierno</a></h3></div><img src="../images/varios/esq_'+esquina+'_azul.jpg" alt=""/><div class="sn_elem bg_blue" style="width: 85px;"><h3 class="pTop15"><a href="JavaScript:crearMenu(1);">Apoyos <br/> Privados</a></h3></div><img src="../images/varios/esq_azul_gris.jpg" alt=""/><div class="sn_elem bg_gray" style="width: 112px;"><h3 class="pTop25"><a href="JavaScript:crearMenu(2);">Información</a></h3></div><img src="../images/varios/esq_gris_azul.jpg" alt=""/><div class="sn_elem bg_blue" style="width: 100px;"><h3 class="pTop25"><a href="JavaScript:crearMenu(3)">Colaboración</a></h3></div>';
		tabla2(3);
	}
		 

		
				}


function save_node(nid){
  	var miAleatorio=parseInt(Math.random()*99999999);	
	http.open("GET", concamin_base_path+"/dbcustom/ajax/save/"+nid+"/" + miAleatorio, true);
	http.onreadystatechange = $("#Save").hide("Slow");
	document.getElementById("topResultados").innerHTML = '<h2>Resultados</h2><a href="#" class="vertodosRes"></a>';
    http.send(null);
	
}
function erase_node(nid){
  	var miAleatorio=parseInt(Math.random()*99999999);	
	http.open("GET", concamin_base_path+"/dbcustom/ajax/erase/"+nid+"/" + miAleatorio, true);
	http.onreadystatechange = $("#Erase").hide("Slow");
	document.getElementById("topResultados").innerHTML = '<h2>Resultados</h2><a href="#" class="vertodosRes"></a>';
    http.send(null);
	
}
var parent=0;
var proceso=4;
function vote_node(nid,vote,paren){
 	

}

function ganadora()
{

    if(http.readyState==1){
    document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><h2><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1><a href="#" class="vertodosRes"></a>';
    }
   
    if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1><a href="#" class="vertodosRes"></a>';

       if (http.status == 200) 
           {
     		
            } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}


function tabla(Numb)
{

	var miAleatorio=parseInt(Math.random()*99999999);
    http.open("GET", concamin_base_path+"/dbcustom/ajax/paso2/"+Numb+"&ID=1&rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse; 
    http.send(null);
	
}

function tabla_special(Numb)
{

	var miAleatorio=parseInt(Math.random()*99999999);
    http.open("GET", concamin_base_path+"/dbcustom/ajax/paso2/"+Numb+"&ID=1&rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse_special; 
    http.send(null);
	
}


function get_articles()
{

	var miAleatorio=parseInt(Math.random()*99999999);
    http.open("GET", concamin_base_path+"/dbcustom/ajax/get_articles/list/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse8; 
    http.send(null);
	
}
function get_news()
{

	var miAleatorio=parseInt(Math.random()*99999999);
    http.open("GET", concamin_base_path+"/dbcustom/ajax/get_news/list/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse8; 
    http.send(null);
	
}
function get_guias()
{

	var miAleatorio=parseInt(Math.random()*99999999);
    http.open("GET", concamin_base_path+"/dbcustom/ajax/get_guias/list/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse8; 
    http.send(null);
	
}
function get_my_articles()
{

	var miAleatorio=parseInt(Math.random()*99999999);
    http.open("GET", concamin_base_path+"/dbcustom/ajax/get_my_articles/list/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse8; 
    http.send(null);
	
}

function get_questions()
{

	var miAleatorio=parseInt(Math.random()*99999999);
    http.open("GET", concamin_base_path+"/dbcustom/ajax/get_questions/list/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse8; 
    http.send(null);
	
}

function get_offers(Ofer)
{
if (Ofer==1){
	peticion='get_offer_fina';
}
if (Ofer==2){
		peticion='get_offer_edu';
}
if (Ofer==3){
		peticion='get_offer_gober';
}
	var miAleatorio=parseInt(Math.random()*99999999);
    http.open("GET", concamin_base_path+"/dbcustom/ajax/"+peticion+"/list/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse8; 
    http.send(null);
	
}


function next_page(NextPage){

    http.open("GET", NextPage, true);  
    http.onreadystatechange = useHttpResponse2;
    http.send(null);	
	}

function search_string(zOrder){
	var miAleatorio=parseInt(Math.random()*99999999);
	var go_search=document.getElementById("go_search").value;
	var words = getValue('search_type');
	var open_closed = getValue('question');
	if (!go_search)
	{
		go_search=1;
		
	}
	
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso5/13/"+proceso_pertenece+"/"+go_search+"/"+words+"/"+open_closed+"/"+zOrder+"/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse2; 
    http.send(null);
}

function search_art(zOrd){
	var miAleatorio=parseInt(Math.random()*99999999);
	var go_search=document.getElementById("go_search").value;
	var order = getValue('orden');

	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso7/13/"+proceso_pertenece+"/"+go_search+"/"+order+"/"+zOrd+"/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse2; 
    http.send(null);
}

function search_noti(){
	var miAleatorio=parseInt(Math.random()*99999999);
	var go_search=document.getElementById("go_search").value;
	var order = getValue('orden');

	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso8/13/"+proceso_pertenece+"/"+go_search+"/"+order+"/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse2; 
    http.send(null);
}

function order(){
	var miAleatorio=parseInt(Math.random()*99999999);
	var order = getValue('orden');

	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso7/14/"+proceso_pertenece+"/"+order+"/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse2; 
    http.send(null);
}
function orderz(zOrd){
	var miAleatorio=parseInt(Math.random()*99999999);


	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso7/0/"+proceso_pertenece+"/"+zOrd+"/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse2; 
    http.send(null);
}

function orderzz(zOrd){
	var miAleatorio=parseInt(Math.random()*99999999);


	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso8/0/"+proceso_pertenece+"/"+zOrd+"/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse2; 
    http.send(null);
}

function order2(){
	var miAleatorio=parseInt(Math.random()*99999999);
	var order = getValue('orden');

	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso8/14/"+proceso_pertenece+"/"+order+"/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse2; 
    http.send(null);
}

function search_user(){
	var miAleatorio=parseInt(Math.random()*99999999);
	var go_search=document.getElementById("user_search").value;
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso6/2/"+proceso_pertenece+"/"+go_search+"/rand=" + miAleatorio, true);  
    http.onreadystatechange = useHttpResponse2; 
    http.send(null);
}

function search_colab(colab){
	var miAleatorio=parseInt(Math.random()*99999999);
	if(colab==2){

	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso6/4/"+proceso_pertenece+"/rand=" + miAleatorio, true);  
	}
	else
	{
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso6/0/"+proceso_pertenece+"/rand=" + miAleatorio, true);  
	}
    http.onreadystatechange = useHttpResponse2; 
    http.send(null);
}

trash2=0;

function winner(trash,anid){
	trash2=trash;
	var miAleatorio=parseInt(Math.random()*99999999);
	
	http.open("GET", concamin_base_path+"/dbcustom/ajax/ganadora/"+anid+"/rand=" + miAleatorio, true);    http.onreadystatechange = useHttpResponse4; 
    http.send(null);
}
snid2=0;
sprocess2=0;
function stars(snid,sprocess,star)
{
	snid2=snid;
	sprocess2=sprocess;
	var miAleatorio=parseInt(Math.random()*99999999);

	http.open("GET", concamin_base_path+"nodevote/"+snid+"/add/?vote="+star+"/rand=" + miAleatorio, true);
	http.onreadystatechange = useHttpResponse5; 
    http.send(null);

}

function stars_special(snid,sprocess,star)
{
	snid2=snid;
	sprocess2=sprocess;
	var miAleatorio=parseInt(Math.random()*99999999);

	http.open("GET", concamin_base_path+"nodevote/"+snid+"/add/?vote="+star+"/rand=" + miAleatorio, true);
	http.onreadystatechange = useHttpResponseSpecial; 
    http.send(null);

}


function OrderSort(zOrder){
	Mosa=10;
	tablaA(10,zOrder);
}

function tablaA_special(Cred,zOrder) 
{

	var miAleatorio=parseInt(Math.random()*99999999);
	Monton=0;
	
	http.open("GET", concamin_base_path+"/dbcustom/ajax/paso9/"+Cred+"/"+proceso_pertenece+"/"+Monton+"/rand=" + miAleatorio, true);  
	
    http.onreadystatechange = useHttpResponse2_special; 
    http.send(null);
	
}

function tablaA(Cred,zOrder) 
{

if (zOrder==0){
	zOrder=0;
}
	var miAleatorio=parseInt(Math.random()*99999999);
if (Mosa==1){
	guias=0;
    var Monton=document.getElementById("Monto").value;
	var Tasa=document.getElementById("Tasa").value;
	var nEstado=document.getElementById("Estado").value;
	if (Monton==0){
		Monton=0;
	}
		if (Tasa==0){
		Tasa=1000000000000000000;
	}

    http.open("GET", concamin_base_path+"/dbcustom/ajax/paso3/"+Cred+"/"+proceso_pertenece+"/"+Monton+"/"+Tasa+"/"+zOrder+"/"+nEstado+"/" + miAleatorio, true);  

	}
if (Mosa==2)
{
	guias=0;
var Monton=document.getElementById("Monto").value;
var nEstados=document.getElementById("Estado").value;
http.open("GET", concamin_base_path+"/dbcustom/ajax/paso1/"+Cred+"/"+proceso_pertenece+"/"+Monton+"/"+zOrder+"/"+nEstados+"/rand=" + miAleatorio, true);  
}
if (Mosa==3)
{
	Monton=0;
guias=0;
http.open("GET", concamin_base_path+"/dbcustom/ajax/paso4/"+Cred+"/"+proceso_pertenece+"/"+Monton+"/"+state_choice+"/"+institution_choice+"/"+zOrder+"/"+"rand=" + miAleatorio, true);  
}
if (Mosa==10)
{
	guias=0;
	Monton=0;

http.open("GET", concamin_base_path+"/dbcustom/ajax/paso5/"+Cred+"/"+proceso_pertenece+"/"+Monton+"/"+zOrder+"/rand=" + miAleatorio, true);  
}
if (Mosa==12)
{
	guias=0;
	Monton=0;
http.open("GET", concamin_base_path+"/dbcustom/ajax/paso6/"+Cred+"/"+proceso_pertenece+"/"+Monton+"/rand=" + miAleatorio, true);  
}
if (Mosa==20)
{
	guias=0;
	Monton=0;
http.open("GET", concamin_base_path+"/dbcustom/ajax/paso7/"+Cred+"/"+proceso_pertenece+"/"+Monton+"/rand=" + miAleatorio, true);  
}
if (Mosa==21)
{
	guias=0;
	Monton=0;
http.open("GET", concamin_base_path+"/dbcustom/ajax/paso8/"+Cred+"/"+proceso_pertenece+"/"+Monton+"/rand=" + miAleatorio, true);  
}
if (Mosa==22)
{
	guias=0;
	Monton=0;
	
http.open("GET", concamin_base_path+"/dbcustom/ajax/paso9/"+Cred+"/"+proceso_pertenece+"/"+Monton+"/rand=" + miAleatorio, true);  
}
if (Mosa==23)
{

	Monton=0;
	
http.open("GET", concamin_base_path+"/dbcustom/ajax/paso9/"+Cred+"/"+proceso_pertenece+"/"+Monton+"/rand=" + miAleatorio, true);  
}
    http.onreadystatechange = useHttpResponse2; 
    http.send(null);
	
}
function tabla2(Mos){ 
Mosa=Mos;
				$("#Danilo").hide("Slow");
				setTimeout("tabla("+Mos+")",500);
				};

function tabla2_special(Mos){ 
Mosa=Mos;
				$("#Danilo").hide("Slow");
				setTimeout("tabla_special("+Mos+")",500);
				

				
				};


function index(zOrd){
				MiIndex=document.getElementById("Tipo").selectedIndex;
				Items=document.getElementById("Tipo").options[MiIndex].value;
				setTimeout("tablaA("+Items+","+zOrd+")",500);

}

function index2(zOrd){
				MiIndex=document.getElementById("Tema").selectedIndex;
				Items=document.getElementById("Tema").options[MiIndex].value;
				setTimeout("tablaA("+Items+","+zOrd+")",500);

}
var state_choice;
var institution_choice;
function index3(zOrd){
				
				MiIndex=document.getElementById("Oferta").selectedIndex;
				Items=document.getElementById("Oferta").options[MiIndex].value;
				
				MiIndex2=document.getElementById("Estado").selectedIndex;
				state_choice=document.getElementById("Estado").options[MiIndex2].value;
				
				setTimeout("tablaA("+Items+","+zOrd+")",500);

}
function useHttpResponse()
{

    if(http.readyState==1){
    document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    }
   
    if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1>';

       if (http.status == 200) 
           {
     
	 		var miTexto = http.responseText;
			
            document.getElementById("Danilo").innerHTML =miTexto;
             $("#Danilo").slideToggle("Slow"); 
			 tablaA(0);
            } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}

function useHttpResponse_special()
{

    if(http.readyState==1){
    document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    }
   
    if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1>';

       if (http.status == 200) 
           {
     
	 		var miTexto = http.responseText;
			
            document.getElementById("Danilo").innerHTML =miTexto;
             $("#Danilo").slideToggle("Slow"); 
			 
			 tablaA_special(0);
            } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}


function useHttpResponse2() 
{
 	if(http.readyState==1){
    document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    }
   
    if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1>';

       if (http.status == 200) 
           {
	 		
			var miTexto = http.responseXML.getElementsByTagName("elemento")[0].firstChild.data;
			
			var miDetalle = http.responseXML.getElementsByTagName("detalles")[0].firstChild.data;
            document.getElementById("Resultados").innerHTML =miTexto; 
			document.getElementById("Detalles").innerHTML =miDetalle; 
            $(Resultados).show("Slow");

			
            } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}

function useHttpResponse2_special() 
{
 	if(http.readyState==1){
    document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    }
   
    if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1>';

       if (http.status == 200) 
           {
     		
	 		var miTexto = http.responseXML.getElementsByTagName('elemento')[0].firstChild.data;
			var miDetalle = http.responseXML.getElementsByTagName('detalles')[0].firstChild.data;
            document.getElementById("Resultados").innerHTML =miTexto; 
			//document.getElementById("Detalles").innerHTML =miDetalle; 
            //$(Resultados).show("Slow");

			setTimeout("select_this("+guias+",8)",200);

            } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}


function useHttpResponse3() 
{
		if(http.readyState==1){
   		 document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    							}
   
   		 if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1></a>';

       if (http.status == 200) 
           {
     
	 		var miTexto = http.responseText;
			document.getElementById("Detalles").innerHTML =miTexto; 
			window.scroll(0,400);
            
            } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}

function useHttpResponse4() 
{
 	if(http.readyState==1){
    document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    }
   
    if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1>';

       if (http.status == 200) 
           {
			select_this(trash2,4);     		
           } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}


function useHttpResponse5() 
{
 	if(http.readyState==1){
    document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    }
   
    if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1>';

       if (http.status == 200) 
           {
			select_this(snid2,sprocess2);     		
           } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}

function useHttpResponseSpecial() 
{
 	if(http.readyState==1){
    document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    }
   
    if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1>';

       if (http.status == 200) 
           {
			select_this_u(snid2);     		
           } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}

function useHttpResponse6() 
{
 	if(http.readyState==1){
    document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    }
   
    if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1>';

       if (http.status == 200) 
           {
			var miStatus = http.responseText;
			if (miStatus=="LogedIn"){
				var miAleatorio=parseInt(Math.random()*99999999);
			http.open("GET", concamin_base_path+"/dbcustom/ajax/getuser/get_info/rand=" + miAleatorio, true);  
		    http.onreadystatechange = useHttpResponse7; 
		    http.send(null);
			}
			else {
				login();
			}
           } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}

function useHttpResponse7() 
{
 	if(http.readyState==1){
    document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    }
   
    if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1>';

       if (http.status == 200) 
           {
     		
	 		var miTexto = http.responseXML.getElementsByTagName('elemento')[0].firstChild.data;
			var miDetalle = http.responseXML.getElementsByTagName('detalles')[0].firstChild.data;
            document.getElementById("Resultados").innerHTML =miTexto; 
			document.getElementById("Detalles").innerHTML =miDetalle; 
            $(Resultados).show("Slow");

            } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}

function useHttpResponse8() 
{
 	if(http.readyState==1){
    document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    }
   
    if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1>';

       if (http.status == 200) 
           {
     		
	 		var miTexto = http.responseXML.getElementsByTagName('elemento')[0].firstChild.data;
			var miDetalle = http.responseXML.getElementsByTagName('detalles')[0].firstChild.data;
            document.getElementById("Resultados").innerHTML =miTexto; 
			document.getElementById("Detalles").innerHTML =miDetalle; 
            $(Resultados).show("Slow");

            } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}


function useHttpResponse10() 
{
		if(http.readyState==1){
   		 document.getElementById("topResultados").innerHTML = '<h1 class="titleit3"><img src="../images/varios/ajax-loader6.gif"/> Cargando...</h1>';
    							}
   
   		 if (http.readyState == 4) 
       {
		document.getElementById("topResultados").innerHTML = '<h1 class="titleit3">Resultados :</h1></a>';

       if (http.status == 200) 
           {
     
	 		var miTexto = http.responseText;
			document.getElementById("Detalles").innerHTML =miTexto; 
			window.scroll(0,400);
            
            } 
    
        else 
           {
            alert("Ha habido un problema al acceder al servidor: " + http.statusText);
           }
        }
}
function the_prueba(){
	alert("funciona!");
}

function dehabil(action){
	
	if (action==1){
		document.getElementById("Estado").selectedIndex=0;
		document.getElementById("Estado").disabled='disabled';
		index3();
	}
	else{
		document.getElementById("Estado").disabled='';
		
	}
	
}
