function ShowSee(thelinks,theLayer){

	if(thelinks == false)	thelinks	= 'loginLinks';
	if(theLayer == false)	theLayer	= 'loginFields';

    var loginLinksLayer  = thelinks;
    var loginFieldsLayer = theLayer;

    if (document.getElementById(loginLinksLayer).style.display == "block") {
        document.getElementById(loginLinksLayer).style.display = "none";
        document.getElementById(loginFieldsLayer).style.display = "block";
    } else {
        document.getElementById(loginLinksLayer).style.display = "block";
        document.getElementById(loginFieldsLayer).style.display = "none";
    }
}

function openpage(pagina,nombreventana,width,height) {
	 if(width == false)	width		= 500;
	 if(height == false)	height	= 350;

	myWin=open(pagina,nombreventana,'width='+ width +',height='+ height +',top=150,left=300,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=no,titlebar=no');
}

function createRequestObject(){
      var peticion;
      var browser = navigator.appName;
            if(browser == "Microsoft Internet Explorer"){
                  peticion = new ActiveXObject("Microsoft.XMLHTTP");
            }else{
                  peticion = new XMLHttpRequest();
}
return peticion;
}
 
 
var http = new Array();
function ObtDatos(url,DirWeb){
      var act = new Date();
      http[act] = createRequestObject();
      http[act].open('get', url);
      http[act].onreadystatechange = function() {
      if (http[act].readyState == 4) {
            if (http[act].status == 200 || http[act].status == 304) {
  		var texto
		texto = http[act].responseText
					var DivDestino = document.getElementById("DivDestino");
                    DivDestino.innerHTML = "<div id='error'>"+texto+"</div>";
					if(texto == 'Entrando...') {
							DirWeb += "/galeria/";
							location.href = DirWeb; 
					}

}
}
}
http[act].send(null);
}

