function show(theTable) { document.getElementById(theTable).style.display = 'block'; }
function hide(theTable) { document.getElementById(theTable).style.display = 'none'; }

function nada(total){	// oculta totes les capes
	var i;
	for (i=1;i<=total;i++) { 
	    hide('txt'+i);
	}
}

function punto(elemento,total){	// mostra la capa amb nš = elemento i oculta la resta
	var i;
	for (i=1;i<=total;i++) { 
	    if(i == elemento){
			show('submenu' + i);
		}else{
			hide('submenu' + i);
		}
	}
}