After file upload, I am renaming with this code (in CI)
rename ( "./upload/temp/{$data1['upload_data']['client_name']}", "./upload/$filename" );
but there are any space in file name it’s gives this massage, like for file name “New Text Document (2).txt” the massage is
Message: rename(./upload/temp/New Text Document (2).txt,./upload/4.txt) [function.rename]: No error
How I can fix this?
You should probably replace all spaces with
\(backslash + space), for example: