Skip to content
Snippets Groups Projects
ajax.js 316 B
Newer Older
function send_simple_request(address) {
erichard's avatar
erichard committed
/*
    Return response to request send at address on the web-server
    :param address: String
    :return: (JSON) String
*/
    var xhr = new XMLHttpRequest();
    xhr.open("GET", address, false);
    xhr.send();
    console.log(xhr.status);
    return (xhr.responseText); 
}