3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $array[something] = "Something is not a string. It's a constant. But because it's not found, PHP will assume you meant a string."; //And if you error reporting is off, you'll never know. echo $array[something];
Output for 4.3.0 - 7.1.0
Notice: Use of undefined constant something - assumed 'something' in /in/Q1ct4 on line 3 Notice: Use of undefined constant something - assumed 'something' in /in/Q1ct4 on line 7 Something is not a string. It's a constant. But because it's not found, PHP will assume you meant a string.