Try this feature:
function chpu ($path){return strtr($path,array("«"=>"", "»"=>"", " "=>"_", "-"=>"_", "№"=>"", "є"=>"e", "і"=>"i", "І"=>"i", "$"=>"", ";"=>"", ":"=>"", ","=>"", "."=>"", "["=>"", "'"=>"", "]"=>"", "*"=>"_", "/"=>"_", "|"=>"_", "{"=>"", "}"=>"", "="=>"_", "+"=>"", "?"=>"", "!"=>"", "@"=>"", "#"=>"", "%"=>"", "^"=>"", "&"=>"", "("=>"", ")"=>"", "\""=>"", "а"=>"a", "б"=>"b", "в"=>"v", "г"=>"g", "д"=>"d", "е"=>"e", "ё"=>"jo", "ж"=>"zh", "з"=>"z", "и"=>"i", "й"=>"j", "к"=>"k", "л"=>"l", "м"=>"m", "н"=>"n", "о"=>"o", "п"=>"p", "р"=>"r", "с"=>"s", "т"=>"t", "у"=>"u", "ф"=>"f", "х"=>"x", "ц"=>"c", "ч"=>"ch", "ш"=>"sh", "щ"=>"shh", "ъ"=>"", "ы"=>"y", "ь"=>"", "э"=>"je", "ю"=>"ju", "я"=>"ya", "йо"=>"j/o", "йе"=>"j/e", "А"=>"a", "Б"=>"b", "В"=>"v", "Є"=>"e", "Г"=>"g", "Д"=>"d", "Е"=>"e", "Ё"=>"jo", "Ж"=>"zh", "З"=>"z", "И"=>"i", "Й"=>"j", "К"=>"k", "Л"=>"l", "М"=>"m", "Н"=>"n", "О"=>"o", "П"=>"p", "Р"=>"r", "С"=>"s", "Т"=>"t", "У"=>"u", "Ф"=>"f", "Х"=>"x", "Ц"=>"c", "Ч"=>"ch", "Ш"=>"sh", "Щ"=>"shh", "Ъ"=>"", "Ы"=>"y", "Ь"=>"", "Э"=>"je", "Ю"=>"ju", "Я"=>"ya", "ЙО"=>"", "ЙЕ"=>"")); }
Once I used it to form CNC from the title of the article, but for you it can also be suitable.
$p = chpu($_FILES['filename']['name']);
The name chpu can be changed to your own :)