|
|
|
@ -1,13 +1,13 @@
|
|
|
|
|
function dashboard () {
|
|
|
|
|
// var xhr = new XMLHttpRequest();
|
|
|
|
|
// xhr.open('POST', 'http://82.165.180.114/Scripted/index.php?action=getPlayersEmail', true);
|
|
|
|
|
// xhr.responseType = 'text';
|
|
|
|
|
// xhr.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
|
|
|
|
|
// var playersEmail = xhr.onload = function () {
|
|
|
|
|
// console.log(xhr.responseText + "DONE");
|
|
|
|
|
// return JSON.parse(xhr.responseText);
|
|
|
|
|
// };
|
|
|
|
|
// xhr.send(null);
|
|
|
|
|
var xhr = new XMLHttpRequest();
|
|
|
|
|
xhr.open('POST', 'http://82.165.180.114/Scripted/index.php?action=getPlayersEmail', true);
|
|
|
|
|
xhr.responseType = 'text';
|
|
|
|
|
xhr.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
|
|
|
|
|
var playersEmail = xhr.onload = function () {
|
|
|
|
|
console.log(xhr.responseText);
|
|
|
|
|
return JSON.parse(xhr.responseText);
|
|
|
|
|
};
|
|
|
|
|
xhr.send(null);
|
|
|
|
|
var xhr = new XMLHttpRequest();
|
|
|
|
|
xhr.open('POST', 'http://82.165.180.114/Scripted/index.php?action=getPlayersPseudo', true);
|
|
|
|
|
xhr.responseType = 'text';
|
|
|
|
|