Page 1 of 1

dynamically change name of specific directory

Posted: Thu Jun 09, 2005 10:03 am
by lilsavgrad01
Hello,

I need to dynamically change the name of a dynamically chosen directory by a user through php.

Does anyone know if php has a way of changing specific directory names?

Posted: Thu Jun 09, 2005 10:46 am
by anjanesh
Use opendir to open a directory and traverse through all files/directories in it using the readdir function using filetype you can know if its a directory or not - until you find your specific directory and change the directory name using the rename function.

Posted: Thu Jun 09, 2005 12:20 pm
by timvw