I'm running into some unexpected behavior that I can't figure out.  This is
with PHP version 3, where, to my knowledge, boolean is not built in.

<?php   define ("true", 1);
        define ("false", 0);
        echo gettype(true);
        echo gettype(false); ?>

The type of true is returned as an integer, while the type of false is
returned as a string.  Even if I say (int) 0, it still returns its type as a
string.  Can anyone explain to me why it behaves this way?  Thank you.

-Rob


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to