note 81596 deleted from function.settype by nlopess

From: Date: Wed, 05 Mar 2008 19:51:43 +0000
Subject: note 81596 deleted from function.settype by nlopess
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-136772@lists.php.net to get a copy of this message
Note Submitter: robin at barafranca dot com ---- Just a quick note, as this caught me out very briefly: settype() returns bool, not the typecasted variable - so: $blah = settype($blah, "int"); // is wrong, changes $blah to 0 or 1 settype($blah, "int"); // is correct Hope this helps someone else who makes a mistake.. ;)

« previous php.notes (#136772) next »