Kod
function createXMLHttpRequest() {
   try { return new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) {}
   try { return new ActiveXObject("Microsoft.XMLHTTP"); } catch (e) {}
   try { return new XMLHttpRequest(); } catch (e) {}
   alert("Brak obsługi XMLHttpRequest");
   return null;
}

function $(id) {
   return document.getElementById(id);
}

window.onload = function() {
  var xhr = createXMLHttpRequest();
xhr.onreadystatechange = function() {
   if (xhr.status==200) {
     $("sandbox").innerHTML = "Pobrano z serwera...<hr/>";
     $("sandbox").innerHTML += xhr.responseText;
   } else {
     alert("Komunikat został zwrócony z kodem błędu.");
   }
}
}
xhr.open("GET", "message.html", true);
xhr.send(null);
}


Mimo wszystko nie spełnia swojego zadania. Czy ktoś wie co tutaj jest źle ?