javascript - readyState does not get past 1 -
javascript - readyState does not get past 1 -
trying set info xml through javascripts open() function. website not past readystate 1, below the javascript code
function additem() { var name = document.getelementbyid('iname').value; var cost = document.getelementbyid('iprice').value; var quantity = document.getelementbyid('iquantity').value; var description = document.getelementbyid('idescription').value; xhrobject.open("get", "listing.php", true); xhrobject.onreadystatechange = function() { if (xhrobject.readystate == 4 && xhrobject.status == 200) { document.getelementbyid('information').innerhtml = xhrobject.responsetext; xhrobject.send(null); } } }
i not know if error php, quite big post in if required.
javascript php ajax
Comments
Post a Comment