๐ Simple and Secure PHP File Uploader with greate options and very light and easy to use.
- php 5.6 >=
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
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 |
The MIT License (MIT). Please see License File for more information.