3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $var = ''; // Evaluates to true because $var is empty if (empty($var)) { echo '$var is either 0, empty, or not set at all'; } // Evaluates as true because $var is set if (isset($var)) { echo '$var is set even though it is empty'; }
Output for 4.3.0 - 7.2.0
$var is either 0, empty, or not set at all$var is set even though it is empty