
function cambiar(id){
         var obj = document.getElementById(id);
         if(obj.style.display == 'block') obj.style.display = 'none';
         else obj.style.display = 'block';
}

function quitar(id){
         var obj = document.getElementById(id);
         obj.style.display = 'none';
}

function poner(id){
         var obj = document.getElementById(id);
         obj.style.display = 'block';
}

function mostrar(nombreCapa){
	document.getElementById(nombreCapa).style.visibility="visible";
}

function ocultar(nombreCapa){
	document.getElementById(nombreCapa).style.visibility="hidden";
}

if (document.images)
{
	image1on=new Image();
	image1on.src="img/buttons/btn_vol_off.gif";

	image1off=new Image();
	image1off.src="img/buttons/btn_vol_offover.gif";

	image1active=new Image();
	image1active.src="img/buttons/btn_vol_offclic.gif";


	image2on=new Image();
	image2on.src="img/buttons/btn_vol_on.gif";

	image2off=new Image();
	image2off.src="img/buttons/btn_vol_onover.gif";

	image2active=new Image();
	image2active.src="img/buttons/btn_vol_onclic.gif";

	image3on=new Image();
	image3on.src="img/buttons/btn_scr_on.gif";

	image3off=new Image();
	image3off.src="img/buttons/btn_scr_onover.gif";

	image3active=new Image();
	image3active.src="img/buttons/btn_scr_onclic.gif";

	//canales
	image_ch00on=new Image();
	image_ch00on.src="img/buttons/btn_tv_on.gif";

	image_ch00off=new Image();
	image_ch00off.src="img/buttons/btn_tv_over.gif";

	image_ch01on=new Image();
        image_ch01on.src="img/buttons/btn_tv_off.gif";  

        image_ch01off=new Image();
        image_ch01off.src="img/buttons/btn_tv_over.gif";

	image_ch02on=new Image();
        image_ch02on.src="img/buttons/btn_tv_off.gif";

        image_ch02off=new Image();
        image_ch02off.src="img/buttons/btn_tv_over.gif";

	image_ch03on=new Image();
        image_ch03on.src="img/buttons/btn_tv_off.gif";

        image_ch03off=new Image();
        image_ch03off.src="img/buttons/btn_tv_over.gif";

	image_ch04on=new Image();
        image_ch04on.src="img/buttons/btn_tv_off.gif";

        image_ch04off=new Image();
        image_ch04off.src="img/buttons/btn_tv_over.gif";

	image_ch05on=new Image();
        image_ch05on.src="img/buttons/btn_tv_off.gif";

        image_ch05off=new Image();
        image_ch05off.src="img/buttons/btn_tv_over.gif";

	image_ch06on=new Image();
        image_ch06on.src="img/buttons/btn_tv_off.gif";

        image_ch06off=new Image();
        image_ch06off.src="img/buttons/btn_tv_over.gif";

	image_ch07on=new Image();
        image_ch07on.src="img/buttons/btn_tv_off.gif";

        image_ch07off=new Image();
        image_ch07off.src="img/buttons/btn_tv_over.gif";

	image_ch08on=new Image();
        image_ch08on.src="img/buttons/btn_tv_off.gif";

        image_ch08off=new Image();
        image_ch08off.src="img/buttons/btn_tv_over.gif";

	image_ch09on=new Image();
        image_ch09on.src="img/buttons/btn_tv_off.gif";

        image_ch09off=new Image();
        image_ch09off.src="img/buttons/btn_tv_over.gif";

	image_ch10on=new Image();
        image_ch10on.src="img/buttons/btn_tv_off.gif";

        image_ch10off=new Image();
        image_ch10off.src="img/buttons/btn_tv_over.gif";
}
	
function imageon(image_name)
{
	if (document.images){
	  document[image_name].src = eval(image_name + "on.src");
	}
}

function imageoff(image_name)
{
	if (document.images){
	  document[image_name].src = eval(image_name + "off.src");
	}
}

function imageactive(image_name)
{
	if (document.images){
	  document[image_name].src = eval(image_name + "active.src");
	}
}

function enviavideo()
{
	var nom1 = document.getElementById('nom1').value;
        var corr1 = document.getElementById('corr1').value;
        var nom2 = document.getElementById('nom2').value;
        var corr2 = document.getElementById('corr2').value;

	if(nom1 == "" || corr1 == "" || nom2 == "" || corr2 == ""){
		alert("Por favor, rellene los campos marcados con asterisco");
		return false;
	}

        var e_coment = document.getElementById('e_coment').value;
        var id = document.getElementById('id_video').value;
        xajax_enviaremail(id,nom1,corr1,nom2,corr2,e_coment);
}
