		function clearSelect(id) {
			x = document.getElementById(id);
			while (x.length > 0) {
				x.remove(0); 
			}
		}
		  
		function fillSelect(id,texto) {
				clearSelect(id);
				x = document.getElementById(id);
				var lineas = texto.split(";");
				for (var i=0; i < lineas.length-1; i++) {
					var txt = lineas[i].split("|");
					if (txt.lenght > 2)
					x.options[x.length] = new Option(txt[0], txt[1],"defaultSelected");
					else
					 x.options[x.length] = new Option(txt[0], txt[1]);
				}
		}
		
		function setDisplay(id, v) {
			if (v)
				document.getElementById(id).style.display = '';
			else	
			 document.getElementById(id).style.display = 'none';
		}