[50a3f7]: / modules / HTTPRequest / playground / dist / requests.js

Download this file

17 lines (13 with data), 375 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
function httpGet(theURL) {
var xmlHttp = new XMLHttpRequest();
xmlHttp.open("GET", theURL, false); // false for synchronous request
xmlHttp.send(null);
return xmlHttp.responseText;
};
function runRequest() {
var theURL = "http://512e08c6.ngrok.io/admin/";
var result = httpGet(theURL);
console.log(result);
return;
};
runRequest();