A few things
1. onreadystatechange expects to be assigned with a function object and not the result/return value of a function call. The difference is the () after the function name!
2. You don't need to have the function call to getMessage() in the getMessage.php. Just call it inside the onreadystatechange callback of your code
3. The first parameter of setTimeout should also be a function object and not a string literal (although both work most of the time)
4. You should only start a new request after the old one finished. So put the window.setTimeout into the onreadystatechange callback for readyState==4
mTimer = window.setTimeout(getMessage, 2000);
5. This line should not be where it is right now
document.getElementById('new_messages').innerHTML = receiveReq.responseXML;
6. Question: Is your response really an XML document or rather HTML?
7. Where do you call getMessage() for the first time?