AjaxTest.js

Ajax is javascript that communicates with the server by catching and processing requests, then returning data. var xmlhttp; function loadRevid(http://plantsvszombies.wikia.com/api.php?action=query&list=recentchanges&rclimit=10&rctype=edit&rcprop=user|timestamp|title|ids&format=jsonfm,myFunction) { if (window.XMLHttpRequest) { xmlhttp=new XMLHttpRequest; } else { xmlhttp=new ActiveXObject("Microsoft.XMLHTTP"); } xmlhttp.onreadystatechange=insert myFunction; xmlhttp.open("GET",http://plantsvszombies.wikia.com/api.php?action=query&list=recentchanges&rclimit=10&rctype=edit&rcprop=user|timestamp|title|ids&format=jsonfm,true); xmlhttp.send; } function myFunction { loadRevid("http://plantsvszombies.wikia.com/api.php?action=query&list=recentchanges&rclimit=10&rctype=edit&rcprop=user|timestamp|title|ids&format=jsonfm",function {  if (xmlhttp.readyState==4 && xmlhttp.status==200)    {    document.getElementById("myDiv").innerHTML=xmlhttp.responseText;    }  }); }