1

i am trying to send a GET request to an HTTPS server using xmlhttp. i am trying the following code:

            var getUrl = "https://example.com";
            var xhr = new XMLHttpRequest();
            xhr.open("GET",getUrl, false);
            xhr.send();

the request does not reach the server and i am unable to get a response. what may be the issue?

EDIT: basically my javascript code is in a phonegap application, which has a Same-Origin-Policy.

Gaurav Sood
  • 680
  • 4
  • 17
  • 38

0 Answers0