- rtrim: documentation ( source)
- preg_replace: documentation ( source)
- strtolower: documentation ( source)
<?php
$input = "Wij #^@ & zij !> !-?! beƫindigen";
echo rtrim(preg_replace('/([^a-z0-9]+)/', '-', iconv('utf8', 'ascii//TRANSLIT', strtolower($input))), '-');