What is the correct syntax for using the `rename()` function in PHP to move images between folders?

When using the `rename()` function in PHP to move images between folders, you need to provide the current path of the image and the new path where you want to move the image. Make sure to include the file name in both paths. Additionally, ensure that the folders have the necessary permissions for the operation to be successful.

$old_path = 'path/to/current/folder/image.jpg';
$new_path = 'path/to/new/folder/image.jpg';

if(rename($old_path, $new_path)) {
    echo 'Image moved successfully!';
} else {
    echo 'Failed to move image.';
}