a-sabagh / simple-file-uploader
Simple and Secure PHP File Upload with great options and very light and easy to use.
Installs: 15
Dependents: 0
Suggesters: 0
Security: 0
Stars: 7
Watchers: 0
Forks: 0
Open Issues: 0
pkg:composer/a-sabagh/simple-file-uploader
Requires
- php: ^5.3.3 || ^7.0
Requires (Dev)
- phpunit/phpunit: 7.4
This package is auto-updated.
Last update: 2025-09-28 06:57:01 UTC
README
simple-file-uploader
🐘 Simple and Secure PHP File Uploader with greate options and very light and easy to use.
Requirement
- php 5.6 >=
Install Package
to install simple-file-uploader in your php project you can using composer
composer require a-sabagh/simple-file-uploader
if you never willing to using composer you can download from Package and require src/Uploader.php and use namespace
Usage
first,use name space and create object from Uploader class
use SimpleUploader\Uploader; $handle = new Uploader(__DIR__ . "/uploads");
Uploader class just accept one parameter as a destination of uploader files
| Method | Parameter | Return | Descriptions | 
|---|---|---|---|
| $handle->setType() | Array | Void | Set acceptable file type for Uploading | 
| $handle->setMaxSize() | Integer | Void | Set max size for file in Byte | 
| $handle->getMessages() | NULL | Array | Get result message of uploading proccess | 
| $handle->upload() | $_FILE['file_name'] | Array | Upload files and return uploading files info | 
License
The MIT License (MIT). Please see License File for more information.