You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
833 B
25 lines
833 B
4 years ago
|
var HttpClient = function() {
|
||
|
this.get = function(aUrl, aCallback) {
|
||
|
var anHttpRequest = new XMLHttpRequest();
|
||
|
anHttpRequest.onreadystatechange = function() {
|
||
|
if (anHttpRequest.readyState == 4 && anHttpRequest.status == 200)
|
||
|
aCallback(anHttpRequest.responseText);
|
||
|
}
|
||
|
|
||
|
anHttpRequest.open( "GET", aUrl, true );
|
||
|
anHttpRequest.send( null );
|
||
|
}
|
||
|
}
|
||
|
|
||
|
function kayit() {
|
||
|
var values = {};
|
||
|
var x = document.getElementById("form");
|
||
|
var inputs = x.elements;
|
||
|
var nick = inputs[0].value;
|
||
|
var mail = "mail" + inputs[1].value;
|
||
|
var query = "/" + nick + "/" + mail + "/";
|
||
|
var client = new HttpClient();
|
||
|
client.get('http://146.185.155.241:9998' + query, function(response) {
|
||
|
document.getElementById("uyari").innerHTML = response;
|
||
|
});
|
||
|
}
|