我有两个文件夹
我需要使用PHP 将iclean文件夹移动到pics文件夹中.
请指导我.
谢谢你提前.
Mic*_*ski 30
使用rename().请注意,如果它在Web服务器上运行,则Web服务器用户必须有权写入目标目录.
rename("oldpath", "newpath");
// in your case, assuming the script calling rename()
// resides in the directory above 'myappdemo.com'
rename("myappdemo.com/VueGuides/services/iclean", "myappdemo.com/VueGuides/services/pics/iclean");
// Or use full absolute paths
rename("/path/myappdemo.com/VueGuides/services/iclean", "/path/myappdemo.com/VueGuides/services/pics/iclean");
Run Code Online (Sandbox Code Playgroud)