<!-- Copyright RuralesDara.com
var ns6=document.getElementById&&!document.all;

function iecompattest(){ return ((!window.opera && document.compatMode && document.compatMode!="BackCompat"))? document.documentElement : document.body }
function ietruebody() { return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body }
function ficha(id,ref,dominio) { abrir("http://www."+dominio+"/ficha/"+id+"/index.htm?ref="+ref); }
function ocio(id,ref) { abrir("http://www.ruralesdata.com/intranet/visores/sugerencia.php?id="+id+"&ref="+ref); }
function visita(id,ref) { abrir("http://www.ruralesdata.com/intranet/visores/visita.php?id="+id+"&ref="+ref); }
function mapa(id,ref) { abrir("ficha/"+id+"/situacion?ref="+ref); }

function abrir2(url) {
	ventana(url, 'imprimirguia', 770, 550, 1, 0);
}

function abrir3(url) {
	if (controlactiva) { controlactiva = false ; }
	else window.open(url);
}

function abrir4(url) {
	window.open(url);
}


function ventana( pageToLoad, winName, width, height, center, barras) {
xposition=0; yposition=0;
if ((parseInt(navigator.appVersion) >= 4 ) && (center)){
xposition = (screen.width - width) / 2;
yposition = (screen.height - height) / 2;
}
args = "width=" + width + "," 
+ "height=" + height + "," 
+ "location=0," 
+ "menubar=0,"
+ "resizable=0,"
+ "scrollbars="+barras+","
+ "status=0," 
+ "titlebar=1,"
+ "toolbar=0,"
+ "hotkeys=0,"
+ "screenx=" + xposition + "," //NN Only
+ "screeny=" + yposition + "," //NN Only
+ "left=" + xposition + "," //IE Only
+ "top=" + yposition; //IE Only

window.open( pageToLoad,winName,args );

}

var numsel = 0;

function seleccion(num){
	numsel = num;
	document.getElementById("divseleccion").innerHTML = ' &nbsp; ';
/*
	if (num>0 && num<1000)
		document.getElementById("divseleccion").innerHTML = '<a href="javascript:miseleccion()" target="_self">Ver alojamientos seleccionados  ('+numsel+')';
	else if (num == 0)
		document.getElementById("divseleccion").innerHTML = '<a href="javascript:alert(\'No tiene seleccionado ningún alojamiento\')" target="_self">Ver alojamientos seleccionados  ('+numsel+')';
	else if (num > 999)
		document.getElementById("divseleccion").innerHTML = ' &nbsp; ';
	else 
		document.getElementById("divseleccion").innerHTML = '<a href="/index.php" target="_self">Volver a todos los alojamientos</a>'; 
*/
}

function activa(id){
	controlactiva = true;
	if (document.getElementById("seleccion["+id+"]").value == 1){
		document.getElementById("seleccion["+id+"]").value = 0;
		document.getElementById("img"+id).src="/w/noselec.gif";
		numsel = numsel - 1;
	} else {
		document.getElementById("seleccion["+id+"]").value = 1;
		document.getElementById("img"+id).src="/w/siselec.gif";
		numsel = numsel + 1;
	}
	/*
	if (numsel==0)
		document.getElementById("divseleccion").innerHTML = '<a href="javascript:alert(\'No tiene seleccionado ningún alojamiento\')" target="_self">Mostrar sólo alojamientos seleccionados  ('+numsel+')';
	else
		document.getElementById("divseleccion").innerHTML = '<a href="index.php?miseleccion" target="_self">Mostrar sólo alojamientos seleccionados ('+numsel+')';		
	*/
}


function miseleccion (){
	document.formulario.action = "index.php?miseleccion";
	document.formulario.submit();	
}


//-->
