Ask coding questions

← Back to all posts
Request
somethingcoding (0)

How to send XMLHttpRequest to repl webpage?

Answered by ch1ck3n (1622) [earned 5 cycles]
View Answer
Comments
hotnewtop
ch1ck3n (1622)
function httpGet(theUrl)
{
    var xmlHttp = new XMLHttpRequest();
    xmlHttp.open( "GET", theUrl, false ); // false for synchronous request
    xmlHttp.send( null );
    return xmlHttp.responseText;
}

so to get the repl url just run

httpGet("https://repl.it")

xxpertHacker (860)

Details please?

Any why do you need to use an XMLHTTPRequest?