
function nw_500(pagina) {

	window.open(pagina, 'ventana1','width=500, height=400','toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0');

}

function nw(pagina, ancho, alto) {

	window.open(pagina, 'ventana1','width='+ancho+', height='+alto,'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0');

}

function nw_2(pagina, ancho, alto) {

	window.open(pagina, 'SM2','menubar=yes,location=yes,resizable=yes,scrollbars=yes,status=yes');
	//window.open("http://www.cnn.com/", "CNN_WindowName", "menubar=yes,location=yes,resizable=yes,scrollbars=yes,status=yes");

}

function nw_3(pagina, ancho, alto) {

	window.open(pagina, 'SM2', 'width='+ancho+',height='+alto+',resizable,scrollbars=yes,status=0,toolbar=0');

}

function CampoEnBlanco(formulario, campo, cadena) {

	var f = document.forms[formulario][campo];

	if (f.value == cadena) {

		f.value = "";

	}

}


function RellenaCampo(formulario, campo, cadena) {

	var f = document.forms[formulario][campo];

	if (f.value == "") {

		f.value = cadena;

	}

}

function Expandir(id) {

	var oDiv = document.getElementById(id);

	if((oDiv != null) && (oDiv.style.display != "block")) {
	
		oDiv.style.display = "block";
		
	}
	else {
	
		oDiv.style.display = "none";
	
	}

}

function FondoA(elemento) {

		elemento.style.background = "#999999 url(img/fondos/menu.gif) no-repeat;";

}

function FondoB(elemento) {

		elemento.style.background = "#343434 url(img/fondos/menu.gif) no-repeat;";

}

function mano(a) { 
	if (navigator.appName=="Netscape") { 
		a.style.cursor='pointer'; 
	}
	else { 
		a.style.cursor='hand'; 
	} 
}

function bbcode(formulario, campo, cadena) {

	var f = document.forms[formulario][campo];

	f.value = f.value + cadena;
	f.focus();

}

function decrementa(formulario, campo_a, campo_b) {

	var f1 = document.forms[formulario][campo_a].value.length;
	var f2 = document.forms[formulario][campo_b];

	f2.value = 255 - f1;

}


