3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php switch($MyVar): ?> <?php case '1': ?> Step One <?php break; ?> <?php case '2': ?> Step Two <?php break; ?> <?php endswitch; ?>
Output for 5.1.0 - 7.1.0
Notice: Undefined variable: MyVar in /in/fhd00 on line 2 Notice: Undefined variable: MyVar in /in/fhd00 on line 5
Output for 5.0.4 - 5.0.5
Notice: Undefined variable: MyVar in /in/fhd00 on line 1
Output for 4.3.0 - 5.0.3
Notice: Undefined variable: MyVar in /in/fhd00 on line 1