function sendRequest() { const xhr = new XMLHttpRequest(); xhr.addEventListener("load", e => { if (xhr.status === 200) { console.log("Wynik połączenia:"); console.log(xhr.response); alert(xhr.response) ; } }); xhr.addEventListener("error", e => { alert("Nie udało się nawiązać połączenia"); }); xhr.open("GET", "../../cgi-bin/TI_2025/lab07/ajax_hello.py", true); xhr.send(); }