dev-master
9999999-dev http://www.verot.net/php_class_upload.htmAlterado para menos arquivos
GPL v2
The Requires
- php >=5.3.0
Alterado para menos arquivos
This package is simply a copy of Verot's PHP Upload class., (*1)
An example will be more useful than any blurb I can write :, (*2)
```php $foo = new Upload($_FILES['form_field']); if ($foo->uploaded) { // save uploaded image with no changes $foo->Process('/home/user/files/'); if ($foo->processed) { echo 'original image copied'; } else { echo 'error : ' . $foo->error; } // save uploaded image with a new name $foo->file_new_name_body = 'foo'; $foo->Process('/home/user/files/'); if ($foo->processed) { echo 'image renamed "foo" copied'; } else { echo 'error : ' . $foo->error; } // save uploaded image with a new name, // resized to 100px wide $foo->file_new_name_body = 'image_resized'; $foo->image_resize = true; $foo->image_convert = gif; $foo->image_x = 100; $foo->image_ratio_y = true; $foo->Process('/home/user/files/'); if ($foo->processed) { echo 'image renamed, resized x=100 and converted to GIF'; $foo->Clean(); } else { echo 'error : ' . $foo->error; } } ```
This example uses a file uploaded via a form. With this single file, it will :, (*3)
The class.upload.php source code has been downloaded well over 100 000 times just in the last three years. It is also a key part of the popular K2 content component for Joomla!, downloaded over 500 000 times, and has been implemented in numerous CMS and frameworks!, (*4)
class.upload.php is featured on HotScripts. If you like the script, please rate it or write a review for it. You can find it here., (*5)
class.upload.php is featured on PHP Classes. If you like the script, please rate it there. You can find it here., (*6)
class.upload.php is featured on Freshmeat. If you like the script, please rate it there. You can find it here., (*7)
Commercial licenses are available here., (*8)
Alterado para menos arquivos
GPL v2