// Para conservar el stilo del menu al cambiar el tamanio de la fuente,
// y ya que tenemos cargado prototype (efectos home) 

window.onload = function(){
 if (index==1){
  var num=0;
	$S('#navList li').each(function(element){
 		num++;
		element.id="f"+num;
	});
			
	$S('#navList li').action({
		onmouseover: function(){
			Element.addClassName(this,'hover');
		},
		onmouseout: function(){
			Element.removeClassName(this,'hover')
		}
	});
  }
	
  showCookie();
  
  if (index==0){
	  if (jsActivo){
 		var docencia= document.getElementById("accesoDocencia");
 		var cultura= document.getElementById("accesoCultura");
 		var historia= document.getElementById("accesoHistoria");
 		var docenciaEffect = new fx.Height(docencia, {opacity: true, duration: 1000});
 		var culturaEffect = new fx.Height(cultura, {opacity: true, duration: 2000});
 		var historiaEffect = new fx.Height(historia, {opacity: true, duration: 3000});
 
 		docenciaEffect.custom(0,369);
 		culturaEffect.custom(0,369);
 		historiaEffect.custom(0,369);}
  
	var myUl = document.createElement('ul');
	myUl.id="helpNavigation";
	document.getElementById('container').appendChild(myUl); }
	 
  
	var myLi = document.createElement('li');
	var myLink = document.createElement('a');
	myLink.setAttribute('href','#');
	myLink.className='js';
	myLink.id="activeJs";

	myLink.appendChild(document.createTextNode( jsActivo?jsActivoOnString:jsActivoOffString));
	myLi.appendChild(myLink);
	document.getElementById('helpNavigation').appendChild(myLi);    
  
	$S('#helpNavigation .js').action({
		onclick: function(){
			tooglejs(); 
			 return false;
		},
		onkeypress: function(e){
			var key = e.charCode ? e.charCode : e.keyCode ? e.keyCode : 0;
			if(key != 9 ){tooglejs();  return false;}
		}
	});
	
	
	$S('#contacto a').action({
		onclick: function(){
			ventanaContacto(this.href); return false;
		},
		onkeypress: function(e){
			var key = e.charCode ? e.charCode : e.keyCode ? e.keyCode : 0;
			if(key != 9 ){ ventanaContacto(this.href); return false;}
		}
	});
}


