fixed #2721: enable XmlHttpRequest for web browsers.

Enable XmlHttpRequest for web browsers.