Dump Contents of Directories Into Directory PHP
I have a directory like this :
/images/
and then I have another directory like this
/waiting/pack1/
but I have a bunch of packs, so I was wo开发者_运维知识库ndering how I could make a script to dump all the contents of these /pack*
directories into the /images/
one.
Use directory recursive iterator to get all the file names. Loop on the result (file names) and move them inside the loop to the desired directory.
You can also try with glob
精彩评论