protected function strip($urlString, $separator = '-')
    {
        if (is_numeric($urlString)) {
            return $urlString;
        }

        $urlString = iconv('UTF-8', 'ASCII//TRANSLIT//IGNORE', $urlString);
        $urlString = preg_replace('#[^\w \-\.]+#i', null, $urlString);
        $urlString = preg_replace('/[ -\.]+/', $separator, $urlString);
        $urlString = trim($urlString, '-.');

        return $urlString;
    }
protected function strip($urlString, $separator = '-')
    {
        if (is_numeric($urlString)) {
            return $urlString;
        }

        $urlString = iconv('UTF-8', 'ASCII//TRANSLIT//IGNORE', $urlString);
        $urlString = preg_replace('#[^\w \-\.]+#i', null, $urlString);
        $urlString = preg_replace('/[ -\.]+/', $separator, $urlString);
        $urlString = trim($urlString, '-.');

        return $urlString;
    }
protected function strip ( $ urlString , $ separator = '-' ) { if ( is_numeric ( $ urlString ) ) { return $ urlString ; } $ urlString = iconv ( 'UTF-8' , 'ASCII//TRANSLIT//IGNORE' , $ urlString ) ; $ urlString = preg_replace ( '#[^\w \-\.]+#i' , null , $ urlString ) ; $ urlString = preg_replace ( '/[ -\.]+/' , $ separator , $ urlString ) ; $ urlString = trim ( $ urlString , '-.' ) ; return $ urlString ; }
Strips string from non ASCII chars

@param string $urlString string to strip
@param string $separator char replacing non ASCII chars

@return string
Strips string from non ASCII chars