its a pool

its a poop
This commit is contained in:
Bel LaPointe
2020-07-22 19:03:15 -06:00
parent 43746485d4
commit 3b174e3d60
2 changed files with 28 additions and 2 deletions

View File

@@ -8,10 +8,34 @@
if (form[i].name)
items[form[i].name] = form[i].value
}
console.log(items)
var params = "?"
for(var k in items) {
params += k + "=" + items[k] + "&"
}
params = params.substr(0, params.length-1)
http("GET", "http://localhost:18114/who" + params, function(body, status) {
console.log(status, "body=",body)
}, null)
return false;
}
function http(method, remote, callback, body) {
var xmlhttp = new XMLHttpRequest();
xmlhttp.onreadystatechange = function() {
if (xmlhttp.readyState == XMLHttpRequest.DONE) {
console.log("KK", xmlhttp.readyState, xmlhttp.responseText, xmlhttp.status)
callback(xmlhttp.responseText, xmlhttp.status)
}
};
xmlhttp.open(method, remote, true);
if (typeof body == "undefined") {
body = null
}
xmlhttp.send(body);
}
function callback(responseBody, responseStatus) {
}
function draw(one) {
var id = one.id
var meta = one.meta