note 25633 deleted from function.var-dump by vincent
| From: | vincent@php.net | Date: | Wed, 13 Aug 2003 18:08:09 +0000 |
| Subject: | note 25633 deleted from function.var-dump by vincent | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-54093@lists.php.net to get a copy of this message | ||
Note Submitter: jounlai at hotmail dot com
----
the source code above has a small bug.
...
else if (is_bool($vInput))
{
===> $return .= "bool(<b>" . $vInput ? "true" : "false" .
"</b>)</td>";
}
else if (is_array($vInput))
{
...
must be like,
===> $return .= "bool(<b>" . ($vInput ? "true" : "false") .
"</b>)</td>";
Because the priority of ?: operator is almost the lowest one. Anyway it's a very convinient
function. I love it.