rename folder into sub-folder with PHP

Posted by Workoholic on Stack Overflow See other posts from Stack Overflow or by Workoholic
Published on 2010-04-16T14:45:09Z Indexed on 2010/04/16 14:53 UTC
Read the original article Hit count: 261

Filed under:
|
|

Hi. I'm trying to move a folder by renaming it. Both the test1 and test2 folders already exist.

rename(
 "test1",
 "test2/xxx1/xxx2"
);

The error I get is: rename(...): No such file or directory

I assume this is because the directory "xxx1" does not exist. How can I move the test1 directory anyway?

© Stack Overflow or respective owner

Related posts about php

Related posts about rename