3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $r = '~^(?:(?:https?|ftp)://[^@]+(?:/.*)?|mailto:.+|[/?#].*|[^:]+)\z~i'; var_dump(preg_match($r, "javascript:foo")); var_dump(preg_match($r, "\njavascript:foo"));
Output for 4.3.0 - 7.1.0
int(0) int(0)