3v4l.org

run code in 300+ PHP versions simultaneously
<?php function isStringOnlyAZSPACE($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($valid_chars, "", $the_string); return (strlen($the_string)==0); } echo isStringOnlyAZSPACE("ST MARY'S")?"true":"false"; // FALSE echo "\n"; echo isStringOnlyAZSPACE("ST MARYS")?"true":"false"; // TRUE ?>
Output for git.master, git.master_jit, rfc.property-hooks
false true

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
72.73 ms | 401 KiB | 8 Q