function fValidarDatosVideo(intVideos){
	strTitulo = document.frmVideos.txtTitulo.value;
	if (strTitulo=="") {alert(fM("IntroduzcaTitulo"));return;}
	strDesc=document.frmVideos.txtDesc.value;
	if (strDesc=="") {alert(fM("IntroduzcaDescripcion"));return;}
    
    if (intVideos==1){
        intOpcion=document.frmVideos.cboOpcion.value;
        if (intOpcion=="" || intOpcion==0) {alert("Seleccione en que opción del menú desea meter el contenido");return;}
	    if (document.frmVideos.txtFoto.value=="" && document.frmVideos.hdnFoto.value=="") {alert(fM("IntroduzcaFoto"));return;}
    }
	
    if (document.frmVideos.txtDescarga.value=="") {alert("Introduzca el enlace del fichero");return;}
	
	document.frmVideos.submit();
}
//****************************************
function fAseguraBorrarVideo(intVideos){
	intCuantos=document.frmLista.Cuantos.value;
	i=0;
	sw=0;
	if (intCuantos=="1"){if (document.frmLista.video.checked){sw=1;}
	}else{
		while (i<intCuantos){
			if (document.frmLista.video[i].checked){sw=1;}
			i++;
		}
	}
	if (sw=="1"){
		if (intVideos==1){
            if (confirm(fM("SeguroBorrarVideos"))){document.frmLista.submit();}else{return;}
        }else{
            if (confirm(fM("SeguroBorrarFotos"))){document.frmLista.submit();}else{return;}
        }
	}else{alert(fM("SeleccioneVideo"));return;}
}
//****************************************
function fAsegurarBorrarUnVideo(intCodigo,strIdioma){if (confirm(fM("SeguroBorrarVideo"))){location.href='index.asp?pg=7&CodVideo='+intCodigo+'&CodIdioma='+strIdioma;}}

//****************************************
function fValidarOpcionesVideos (){
    intCuantas = document.frmOpciones.hdnCuantas.value;
    if (intCuantas==0){
        if(document.frmOpciones.txtOpcionES0.value=="" || document.frmOpciones.txtOpcionPT0.value==""){
            alert("Introduzca el nombre de la opcion en ambos idiomas");return;
        }
    }else{
        for (i=0;i<=intCuantas;i++){
            if(i==0){
                if((eval('document.frmOpciones.txtOpcionES'+i+'.value')=="" && eval('document.frmOpciones.txtOpcionPT'+i+'.value')!="") || (eval('document.frmOpciones.txtOpcionES'+i+'.value')!="" && eval('document.frmOpciones.txtOpcionPT'+i+'.value')=="")){
                    alert("Introduzca el nombre de la opcion en ambos idiomas");return;
                }
            }else{
                if(eval('document.frmOpciones.txtOpcionES'+i+'.value')=="" || eval('document.frmOpciones.txtOpcionPT'+i+'.value')==""){
                    alert("Introduzca el nombre de la opcion en ambos idiomas");return;
                }
            }
        }
    }
    document.frmOpciones.submit();
}