// retrieves the XMLHttpRequest object
function createXmlHttpRequestObject3()
{
  var xmlHttp;
  if(window.ActiveXObject)
  {
    try
    {      xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");    }
    catch (e)
    {      xmlHttp = false;    }
  }
  else
  {
    try 
    {      xmlHttp = new XMLHttpRequest();    }
    catch (e) 
    {      xmlHttp = false;    }
  }
  if (!xmlHttp)
    alert("Error creating the XMLHttpRequest object.");
  else 
    return xmlHttp;
}

function status_downloading3()
{}
function status_ready3()
{}


var start1;
var end1;
var doba_prov = 0;

get_fav();
		
function get_fav()
{
  if (xmlHttp.readyState == 4 || xmlHttp.readyState == 0)
  {
    xmlHttp.open("GET", "./fav_ico_load.php?"+kam_jit4, true);
    xmlHttp.onreadystatechange = function() {vypis_fav(); };

    xmlHttp.send(null);
  }
  else
    setTimeout("get_fav()", 1000);
    
}

function vypis_fav()
{
  start1 = new Date();
  
  if (xmlHttp.readyState == 4)
  {
    if (xmlHttp.status == 200)
    {
      calendar1 = xmlHttp.responseText;
      document.getElementById("div_favico").innerHTML = calendar1;

      status_ready3();
    }
    else
    {
      alert("There was a problem accessing the server: " + xmlHttp.statusText);
    }
  }
}


function handle_get_messages3()
{
  if (xmlHttp.readyState == 4)
  {
    if (xmlHttp.status == 200)
    {
      zprava = xmlHttp.responseText;
      if (zprava != '')
        alert(zprava);
      status_ready1();
    }
    else
    {      alert("There was a problem accessing the server: " + xmlHttp.statusText);    }
  }
}
