Solution:
I think you’re facing a problem of same origin policy. It happens to me more than once using Ajax and you only realize this once you push your code on non-local servers. You can read more on the subject here. Hope this will help solve your problem.