if (xmlHttp.readyState==4) {
var ResponseData=xmlHttp.responseText;
if (xmlHttp.responseText != '') {
document.getElementById('error').style.display="block";
var emsg = "You are not a Registered User";
alert(typeof emsg);
alert(typeof ResponseData);
alert(emsg);
alert(ResponseData);
if (ResponseData == emsg) {
location.href="example.php";
}
else
{
location.href=xmlHttp.responseText;
}
Here in the above code.....
emsg and ResponseData are same type(strings) and same valued strings...
but "if" condition is not working there....plss help....