Hi,
There is a very simple way to move an image from one folder to another and the code for that is
<?php
rename("folder_a/image1.jpg","folder_b/image2.jpg");
?>
rename() function folder move from one folder to another.
In this example image1.jpg is moving from folder_a to image2.jpg in folder_b