The rename() function renames a file or directory.
If successful, the function returns TRUE. If it fails, returns FALSE.
rename(oldname,newname,context)
| parameter | describe |
|---|---|
| oldname | Required. Specifies the file or directory to be renamed. |
| newname | Required. Specifies the new name of the file or directory. |
| context | Optional. Specifies the environment for a file handle. context is a set of options that can modify the behavior of the stream. |
<?phprename("images","pictures");?>