Drag and Drop File Upload
Drop files onto the dashed area — or a whole folder, or an image pasted from the clipboard. The uploader still owns validation, queueing, progress and cancellation; the drop zone only hands it the files.
Allowed file types: jpg, gif, png, zip. Maximum file size: 10 MB.
upl-dropzoneMultipleFilesUploadMaxSizeKBAllowedFileExtensions
Live demo
Drop files here
or click to browse — folders and pasted screenshots work too
Try it: drag a file from your desktop onto the dashed area, drop a folder to add everything inside it, or press Ctrl+V with an image on the clipboard.
<?php
require_once "phpuploader/include_phpuploader.php";
$uploader = new PhpUploader();
$uploader->Name = "myuploader";
$uploader->MultipleFilesUpload = true;
$uploader->MaxSizeKB = 10240;
$uploader->AllowedFileExtensions = "jpeg,jpg,gif,png,zip";
$uploader->Render();
?>
<div class="upl-dropzone" data-uploader="myuploader">
<p class="upl-dropzone__title">Drop files here</p>
</div>
<link rel="stylesheet" href="/css/uploader-dropzone.css">
<script src="/js/uploader-dropzone.js"></script>
Guide
Uploading multiple files in PHP
How the $_FILES array is shaped and how to process a batch safely.
