Download the PHP package wenprise/laravel-media-library without Composer
On this page you can find all versions of the php package wenprise/laravel-media-library. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download wenprise/laravel-media-library
More information about wenprise/laravel-media-library
Files in wenprise/laravel-media-library
Package laravel-media-library
Short Description Reusable Laravel media library with upload, metadata, download and protected deletion APIs.
License MIT
Homepage https://github.com/wenprise/laravel-media-library
Informations about the package laravel-media-library
Laravel Media Library
A reusable Laravel media library for uploads, metadata, downloads, polymorphic attachments, and protected deletion.
Requirements
- PHP 8.3 or newer
- Laravel 12 or 13
Installation
Install directly from the public Git repository:
After the package is listed on Packagist, the repository configuration is no longer required:
Publish the Laravel resources:
The package auto-discovers Wenprise\MediaLibrary\MediaLibraryServiceProvider and registers the configured media routes.
Configuration
Configure the host models, tables, upload disk, route middleware, and business-specific usage inspectors in config/media-library.php.
Existing applications can subclass the supplied models and controller to retain their namespaces without copying package logic.
Attachments
Add Wenprise\MediaLibrary\Concerns\HasMediaAttachments to a business model to expose sorted polymorphic media relationships.
Protected deletion
The package blocks deletion when the generic attachment table references an asset. Implement Wenprise\MediaLibrary\Contracts\MediaUsageInspector for direct business foreign keys such as Hero, cover, QR-code, or settings media IDs.
API
The default controller provides list, upload, statistics, detail, metadata update, download, single delete, and atomic batch delete endpoints.
License
MIT
All versions of laravel-media-library with dependencies
illuminate/database Version ^12.0|^13.0
illuminate/filesystem Version ^12.0|^13.0
illuminate/http Version ^12.0|^13.0
illuminate/routing Version ^12.0|^13.0
illuminate/support Version ^12.0|^13.0
illuminate/validation Version ^12.0|^13.0
intervention/image Version ^4.0