function display_grupo(id)
{
	if(id == 1){
		document.getElementById("grupal").style.display = "block";
	}else if(id == 2){
		document.getElementById("grupal").style.display = "none";
	}
}
function alguna_actividad()
{
	var form = document.forms[0];
	var todos = document.getElementsByTagName('input');
	var x;
	var d = 0;
	for(x=0;x<todos.length;x++){
		if(todos[x].type=="radio" && todos[x].checked){
			d = d + 1;
		}
	}
	if(d == 0){
		alert("Debe seleccionar al menos una actividad.");return false;
	}
	return true;
}
function vacio(q)
{  
	for ( i = 0; i < q.length; i++ ) {  
		if ( q.charAt(i) != " " ) {  
			return true;  
		}  
	}  
	return false; 
}
function compruebaidea(form){
	var t1=form.nombre.value;
	if(vacio(t1) == false) {
		window.alert("Debe introducir su nombre.");
		form.nombre.focus(); form.nombre.select(); return false;
	}
	var t3=form.correo.value;
	if(vacio(t3) == false) {
		window.alert("Debe introducir un e-mail de contacto.");
		form.correo.focus(); form.correo.select(); return false;
	}
	var t4=form.idea.value;
	if(vacio(t4) == false) {
		window.alert("Debe introducir una idea.");
		form.idea.focus(); form.idea.select(); return false;
	}
	return true;
}
function comentariocomp(form){
	var t1=form.nombre.value;
	if(vacio(t1) == false) {
		window.alert("Debe introducir su nombre.");
		form.nombre.focus(); form.nombre.select(); return false;
	}
	var t3=form.correo.value;
	if(vacio(t3) == false) {
		window.alert("Debe introducir un e-mail de contacto.");
		form.correo.focus(); form.correo.select(); return false;
	}
	var t4=form.comentario.value;
	if(vacio(t4) == false) {
		window.alert("Debe introducir un comentario.");
		form.comentario.focus(); form.comentario.select(); return false;
	}
	return true;
}