They never had anything to do with one another, it's just the module that Microsoft happened to dump it in.
Not completely true... The X in XHR stands for XML, as that's what it parses natively [1], whereas parsing JSON wasn't native until relatively recently. JavaScript had Java's syntax. Not sure about hamsters and ham...
1. http://msdn.microsoft.com/en-us/library/ms534370(VS.85).aspx
JavaScript's syntax is less like Java's than any other popular language that idiomatically uses curly-braces to delimit blocks.
Hamster starts with Ham, but they are as unrelated as two things can be that exist in the same broad category (flesh).
It's Pataphor: http://en.wikipedia.org/wiki/%27Pataphysics#Pataphor