Hi!
I am trying to get AJAX working on multiple browsers and am having a
problem with Firefox.
I have the following code:
function handleState3(){
switch(http.readyState) {
case 0: // Uninitialized
break;
case 1: // Loading
break;
case 2: // Loaded
break;
case 3: // Interactive
break;
case 4: // Finished
var response = http.responseText;
if (!response) {
} else {
alert('No response received from Notify Server.');
}
break;
default:
alert("ERROR: unknown HTTP state: "+http.readyState);
break;
}
}
AND:
function global_subscribe(email) {
if (email!="" && email) {
http.open("post", "notify.php");
http.setRequestHeader("Content-Type",
"application/x-www-form-urlencoded");
http.onreadystatechange = handleState3;
http.send("type=global&email="+email);
}
}
You can test this script on www.dwergpapegaai.com by clicking on the
Email Icon next to the search box in the green area just below the
message edit area.
It seems that responseText is not working in Firefox!
Please Help!
Best Regards,
Snt