// Russian translite code if (is_utf8($string)) { $chars = array( "А"=>"a","Б"=>"b","В"=>"v","Г"=>"g", "Д"=>"d","Е"=>"e","Ж"=>"z","З"=>"z","И"=>"i", "Й"=>"j","К"=>"k","Л"=>"l","М"=>"m","Н"=>"n", "О"=>"o","П"=>"p","Р"=>"r","С"=>"s","Т"=>"t", "У"=>"u","Ф"=>"f","Х"=>"h","Ц"=>"c","Ч"=>"ch", "Ш"=>"sh","Щ"=>"w","Ъ"=>"","Ы"=>"i","Ь"=>"", "Э"=>"e","Ю"=>"ju","Я"=>"ja","а"=>"a","б"=>"b", "в"=>"v","г"=>"g","д"=>"d","е"=>"e", "ё"=>"e","ж"=>"z", "з"=>"z","и"=>"i","й"=>"j","к"=>"k","л"=>"l", "м"=>"m","н"=>"n","о"=>"o","п"=>"p","р"=>"r", "с"=>"s","т"=>"t","у"=>"u","ф"=>"f","х"=>"h", "ц"=>"c","ч"=>"ch","ш"=>"sh","щ"=>"w","ъ"=>"y", "ы"=>"i","ь"=>"","э"=>"e","ю"=>"ju","я"=>"ja", " "=> "-", "."=> "", "/"=> "-", "-" => "-"); $string = strtr($string, $chars); } // End Russian translite code