Creating non-English directories in PHP

I want to be able to create folders for registered users under their names. Their information is stored in my db in Cyrillic characters and pulled out of them when creating the folder. The fact is that the information in English is all right, if in Cyrillic I get something like "ѓ "Њ ј ° ЅѕІ °. Everything is set to utf-8. If I set the name of the folder ie 'fyva', it’s not will create problems.

        $this->load->model('users_model');
    $i=$this->session->userdata('uid');
    $new_name=$this->input->post('doc_name');
    $folder=$this->users_model->getFullName($i); //$folder='' works fine

    if(!is_dir("./uploads/".$folder)){
        mkdir("./uploads/".$folder , 0777);
    }
    $config['file_name'] = $new_name;
    $config['upload_path'] = './uploads/'.$folder.'/';

Thank any help

+5
source share
1 answer

ASCII : , . , , .

( ), , , ( ).

+3

All Articles