Upload alternatives and similar libraries
Based on the "Filtering and Validation" category.
Alternatively, view Upload alternatives based on common mentions on social networks and blogs.
-
ISO-codes
PHP library - Validators for standards from ISO, International Finance, Public Administrations, GS1, Manufacturing Industry, Phone numbers & Zipcodes for many countries -
PHP validate
Lightweight and feature-rich PHP validation and filtering library. Support scene grouping, pre-filtering, array checking, custom validators, custom messages. 轻量且功能丰富的PHP验证、过滤库。支持场景分组,前置过滤,数组检查,自定义验证器,自定义消息。 -
Linio Input
Abstracts HTTP request input handling, providing an easy interface for data hydration and validation -
EU VAT Number Validator
:moneybag: A simple and clean PHP library that validates EU VAT registration numbers against the central ec.europa.eu database (using the official europa API) :eu: -
DMS Filter
Library that offers Input Filtering based on Annotations for use with Objects. Check out 2.dev for 2.0 pre-release. -
Cake Validation
[READ-ONLY] Validation library from CakePHP. This repo is a split of the main code that can be found in https://github.com/cakephp/cakephp -
CSV Blueprint
CSV Validator - Strict and automated line-by-line CSV checking tool based on customizable Yaml schemas -
Distributed locks with Redis and ReactPHP
:lock: Asynchronous distributed locks with Redis and ReactPHP
InfluxDB high-performance time series database

* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of Upload or a related project?
README
Upload
This component simplifies file validation and uploading.
Usage
Assume a file is uploaded with this HTML form:
<form method="POST" enctype="multipart/form-data">
<input type="file" name="foo" value=""/>
<input type="submit" value="Upload File"/>
</form>
When the HTML form is submitted, the server-side PHP code can validate and upload the file like this:
<?php
$storage = new \Upload\Storage\FileSystem('/path/to/directory');
$file = new \Upload\File('foo', $storage);
// Optionally you can rename the file on upload
$new_filename = uniqid();
$file->setName($new_filename);
// Validate file upload
// MimeType List => http://www.iana.org/assignments/media-types/media-types.xhtml
$file->addValidations(array(
// Ensure file is of type "image/png"
new \Upload\Validation\Mimetype('image/png'),
//You can also add multi mimetype validation
//new \Upload\Validation\Mimetype(array('image/png', 'image/gif'))
// Ensure file is no larger than 5M (use "B", "K", M", or "G")
new \Upload\Validation\Size('5M')
));
// Access data about the file that has been uploaded
$data = array(
'name' => $file->getNameWithExtension(),
'extension' => $file->getExtension(),
'mime' => $file->getMimetype(),
'size' => $file->getSize(),
'md5' => $file->getMd5(),
'dimensions' => $file->getDimensions()
);
// Try to upload file
try {
// Success!
$file->upload();
} catch (\Exception $e) {
// Fail!
$errors = $file->getErrors();
}
How to Install
Install composer in your project:
curl -s https://getcomposer.org/installer | php
Require the package with composer:
php composer.phar require codeguy/upload
Author
License
MIT Public License
*Note that all licence references and agreements mentioned in the Upload README section above
are relevant to that project's source code only.