activa
May 26th, 2008, 11:34 AM
I have a swf that sends data to a PHP script on my server. The script works fine, sends me an email, and sends a string back to the swf. The swf sees the data, but is behaving strangely. Here's what I mean:
function onComplete (event:Event) {
if (event.target != null) {
if (event.target.data == 'secretString') {
trace ('ok');
} else {
trace (event.target.data);
}
}
}
The PHP script sends the correct string. I know because the swf traces 'secretString.' Why doesn't it recognize the string in the if conditional? I've already checked the dataFormat, and it confirms that the data is text.
function onComplete (event:Event) {
if (event.target != null) {
if (event.target.data == 'secretString') {
trace ('ok');
} else {
trace (event.target.data);
}
}
}
The PHP script sends the correct string. I know because the swf traces 'secretString.' Why doesn't it recognize the string in the if conditional? I've already checked the dataFormat, and it confirms that the data is text.