3v4l.org

run code in 300+ PHP versions simultaneously
<?php echo preg_replace('#[^A-Za-z0-9\-_]#', '-', "The[quick^brown_fox jumps]over the lazy dog."); echo "\n\n"; echo preg_replace('#[^A-z0-9\-_]#', '-', "The[quick^brown_fox jumps]over the lazy dog.");

preferences:
37.36 ms | 402 KiB | 5 Q