diff --git a/google_sign-in.html b/google_sign-in.html new file mode 100644 index 0000000..a5564e4 --- /dev/null +++ b/google_sign-in.html @@ -0,0 +1,34 @@ + + + + + + + + +
+
+
+ + + \ No newline at end of file diff --git a/js/ajax-questions.js b/js/ajax-questions.js new file mode 100644 index 0000000..e6c75c7 --- /dev/null +++ b/js/ajax-questions.js @@ -0,0 +1,30 @@ + +var xhttp = new XMLHttpRequest(); +var question; +var team_name; +xhttp.open("GET", "url", true); +xhttp.setRequestHeader("Content-Type", "application/json"); +xhttp.onreadystatechange = function() { + if (this.readyState == 4 && this.status == 200) { + + var json = JSON.parse(this.responseText); + console.log(json); + question = json.question; + team_name = json.team_name; + console.log(question,team_name); + } +}; + +xhttp.send(); + +function sendres() { + var ans = JSON.stringify(document.getElementById("").innerHTML); + var res = new XMLHttpRequest(); + res.open("POST","url",true); + res.setRequestHeader("Content-Type", "application/json"); + res.onreadystatechange = function() { + if (this.readyState == 4 && this.status == 200) { + } + }; + res.send(ans); +} \ No newline at end of file