function abrir_ventana(urld) {
	var nPrcentScrW = 80;
	var nPrcentScrH = 70;
	var ancho = screen.width*nPrcentScrW/100;
	var alto = screen.height*nPrcentScrH/100;
	var posX = (screen.width-ancho)/2;
	var posY = (screen.height-alto)/2;
	var features = "width=" + ancho + ",height=" + alto + ",left=" + posX + ",top=" + posY + ",resizable=yes,status=yes,scrollbars=yes,titlebar=1,directories=1,location=yes,menubar=1,";
	window.open(urld,"",features);
}

function fecha(tipo) {
  var this_month = new Array(12);
  this_month[0]  = "Enero";
  this_month[1]  = "Febrero";
  this_month[2]  = "Marzo";
  this_month[3]  = "Abril";
  this_month[4]  = "Mayo";
  this_month[5]  = "Junio";
  this_month[6]  = "Julio";
  this_month[7]  = "Agosto";
  this_month[8]  = "Septiembre";
  this_month[9]  = "Octubre";
  this_month[10] = "Noviembre";
  this_month[11] = "Diciembre";

  var this_day_e = new Array(7);
  this_day_e[0]  = "Domingo";
  this_day_e[1]  = "Lunes";
  this_day_e[2]  = "Martes";
  this_day_e[3]  = "Mi&eacute;rcoles";
  this_day_e[4]  = "Jueves";
  this_day_e[5]  = "Viernes";
  this_day_e[6]  = "S&aacute;bado";

  var today = new Date();
  var day   = today.getDate();
  var month = today.getMonth();
  var year  = today.getYear();
  var dia = today.getDay();
    if (year < 1000) {
       year += 1900; }

if(tipo==1)
  document.write ("<span>" + this_day_e[dia] + ", " + day + " de " + this_month[month] + " de " + year + "</span>");
else
  document.write (day + " de " + this_month[month] + " de " + year);
}

function mySetHomePage(objk) {
	
	var agent = window.navigator.userAgent;
	var i = agent.indexOf("MSIE 7")+5;
	

	if (i>5)
	{
		objk.style.behavior="url(#default#homepage)";
		objk.setHomePage('http://diariodenoticias.laley.es');
	}
	else
	{
		alert("Su navegador no dispone de esta opción. ");
  	}
}