class.upload.php is a powerful and mature PHP class to manage uploaded files, and manipulate images in many ways. The script is available under a GPL license.
The first two lines are just about getting the file name and path from the database & they work OK.
Nothing apparently happens - the image is not rotated. If I leave file_overwrite as default ( NOT to overwrite) then it works, but the file is renamed like file_1.jpg. I don't want to change the file name when it is rotated.
include('classes/class.upload.php'); $thePic = $pics->getOneRow($_GET['id']); $handle = new upload('/images/small/'.$thePic[0]['image']); $handle->file_overwrite = true; $handle->image_rotate = 180; $handle->process(); unset($handle);The first two lines are just about getting the file name and path from the database & they work OK.
Nothing apparently happens - the image is not rotated. If I leave file_overwrite as default ( NOT to overwrite) then it works, but the file is renamed like file_1.jpg. I don't want to change the file name when it is rotated.
What am I doing wrong ?
rgds
KT