3v4l.org

run code in 300+ PHP versions simultaneously
<?php $input = "Wij #^@ & zij !> !-?!"; echo strtolower(preg_replace("/([^a-zA-Z0-9]+)/", "-", $input));

preferences:
40.75 ms | 402 KiB | 5 Q