I have a main page, call it Main.php. On this page, is a button that when clicked, sets a div\'s innerHTML (already on Main.php, called divResults) with the results from Re
try to wrap the javascript code from Result.php in a function and call it after inserting it like :
These Are The Results
and
if (xmlhttp.readyState==4)/* && xmlhttp.status==200) */ { document.getElementById("divResults").innerHTML=xmlhttp.responseText; if(result) result(); }