don't use xmlHttpRequest (commonly misnamed "AJAX"), since that's just for text (exactly your problem). instead, just put in an image element and set it's "src" attribute
bartvh | Join me, make your signature small! Einstein: "We can’t solve problems by using the same kind of thinking we used when we created them."