3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $format = 'aside'; switch ($format) { case 'aside' : ?> echo "i equals aside"; <?php break; case 'video': ?> echo "i equals video"; <?php break; case 'gallery':?> echo "i equals gallery"; <?php break; case 'quote':?> echo "i equals quote"; <?php break; case 'audio': ?> echo "i equals audio"; <?php break; case 'status':?> echo "i equals status"; <?php break; case 'link':?> echo "i equals link"; <?php break; case 'standard':?> echo "i equals standard"; <?php break; } ?>
Output for 4.3.0 - 7.1.0
echo "i equals aside";