3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class Test { function getStVar() { static $_stVar; $output = ''; if (!isset($_stVar)) { $_stVar = true; $output = '!'; } return $output; } } $t = new Test(); echo $t->getStVar(); echo $t->getStVar();
Output for 4.3.0 - 7.1.0
!