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.
You can also do this with a little bit of coding. Instantiate the class first, and then if $foo->uploaded == true, you can read the following variables:
You can also do this with a little bit of coding. Instantiate the class first, and then if $foo->uploaded == true, you can read the following variables:
Then, you can call $foo->process() with different parameters, depending on the variables above.
Note that this will not work if open_basedir restrictions are in place.