I want to create a conditional that would rename a file on my webserver.
How would I use that properly if for ex:
original file name: /home/server/main/myfile.txt
changed to: /home/server/main/error.txt
I found this command, I don't know if its the right one or not.
Code:
rename($old_file_name, $new_file_name);
My hope is it to call from from a file: myrename.php and call it from a template.
Any help on this would be greatly appreciated.
thx