note 15233 deleted from language.types.type-juggling by jeroen
| From: | jeroen@php.net | Date: | Sun, 02 Sep 2001 18:30:21 +0000 |
| Subject: | note 15233 deleted from language.types.type-juggling by jeroen | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-17539@lists.php.net to get a copy of this message | ||
Easy way to cast something like the result of a function to a string:
$myString = '' . $db->f('arg');
Concatenating the empty quotes changes the result to a string no matter what type the result is. For
instance the $db object might be returning an int in this case, but $myString will have the string
equivalent in it.
Matt.