Ganz einfache Lösung eigentlich.
chatbox.js
Code:function meldung () { if(xmlHttp2.readyState == 4) { response = xmlHttp2.responseText; if (response.length > 20) window.alert(response); else { document.chatbox.message.value = ''; document.chatbox.message.focus(); } loadData(); } }