I have a web application that I'm building using, what I thought, is a simple Ajax
function. The app works great on four out of five computers here in the office, but one computer has a problem reaching the status of 200. And it's not really a browser specific issue either. He's tried the app on IE
, Chrome
, Firefox
, & Safari
and same issue on all four browsers.
This is something that we really have to figure out and correct on our end before the product goes into full production. After that we can't be running around correcting customers computers or trying to explain to the customer that it's their computer that's at fault.
So any ideas?
Notes:
- The
Ajax
function, queriedPHP
script, and database are all on the same server. - His computer is running Windows 7 on a Pavilion DV7 computer
Code:
// Pull the information from the database
get_variables = 'action=grabUnitInformation'+
'&identifier='+identifier;
var xmlhttp;
if (window.XMLHttpRequest){
// code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
}else{
// code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
xmlhttp.onreadystatechange=function(){
if (xmlhttp.readyState==4 && xmlhttp.status==200){
var receiver = eval('(' + xmlhttp.responseText + ')');
// Process JSON
alert("Got the info");
}else{
alert("Ready state: "+xmlhttp.readyState);
alert("Status: "+xmlhttp.status);
}
}
xmlhttp.open("GET", "http://www.mysite.com/search.php?"+get_variables, true);
xmlhttp.send();