Set onreadystatechange before send()
Clean up a bit
Add example