October 9th, 2009, 10:06 AM
I am a bit confused as to why this error is happening, but i will try to explain it as best i can, if i don't explain it well enough let me know and i will go over it again in more detail.
i am returning a value either numeric or a string from a db, something like this:
and the js i am using is this:
The problem is that when i go ahead and try and use the xmlhttp.responseText to compare it, it adds a space at the end of everything either a number or a string. Wierdest error i have ever seen, my host uses php5.2.x i am unsure if that is the problem or not, any help with this would be great.
alert ("Browser does not support HTTP Request");
if(xmlhttp.responseText == 1)
October 10th, 2009, 05:41 PM
Re: whitespace issue
I fixed it myself by making the if statements use parsed numbers...
Click Here to Expand Forum to Full Width