Quote:
Originally Posted by Rick
Okay, nevermind, I jumped the gun there by misreading your post... I'll re-edit this post later.
Okay, I've looked at this problem in detail.
evalFIX() works properly, yes.
eval() - the problem may or may not be a problem.
arg ? true : false
arg before it does ?: gets cast to a float -- Objects / arrays get cast to 0.0 obviously, which is why that logic fails with them.
|
Mhmm... Replace eval() by...
PHP Code:
if ( var ) return true;
else return false;
... It does the same as arg ? true: false;
It casts the variable, yes... But that's where the problem is. It should only return false when it is false ("", null, false, "false" ), and in every other occasion, return true ( -1, "foo", {"stuff"}, new Object() ).