3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function isStringOnlyAZ($the_string) { $valid_chars = array('A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U',''V','W','X','Y','Z'); $the_string = str_replace($the_string, "", $the_string); return (strlen($the_string)==0) } echo isStringOnlyAZ("St mary's"); ?>
Output for 5.4.0 - 5.4.17
Parse error: syntax error, unexpected 'V' (T_STRING), expecting ')' in /in/HmhDm on line 5
Process exited with code 255.
Output for 5.3.0 - 5.3.27
Parse error: syntax error, unexpected T_STRING, expecting ')' in /in/HmhDm on line 5
Process exited with code 255.