3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $QUERYSTRING = "test.php?haha=EPS"; do {$a = $QUERYSTRING; $QUERYSTRING = str_replace(array('..', '~', chr(0), ':', '?'), '', $QUERYSTRING); } while ($a != $QUERYSTRING); if( (substr(strtolower($QUERYSTRING), -3) != ".ai") && (substr(strtolower($QUERYSTRING), -4) != ".eps")) { echo "not allowed"; } else { echo "allowed"; }
based on VAmKW
Output for 4.3.0 - 7.1.0
not allowed