简体   繁体   中英

unable to copy files having space and bracket in filename

I am trying to copy the file name "141 (5).jpg" using the copy() function in PHP but I get constantly get hit by

copy(/home/141 (4).jpg): failed to open stream: No such file or directory in /home/Upload.php on line 506

I tried replacing space with %20 and even url encoded the complete path, but with no success. Anyone has any idea on how to do it.

我不确定,但是我建议将文件路径放在引号中。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM