cuongsql / laravel-url-uploaded-file
A package to leverage Laravel's UploadedFile functionality from URLs.
dev-master
2022-04-01 11:50 UTC
Requires
- php: ^8.0
- illuminate/http: ^8.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^2.16
- orchestra/testbench: ^6.2
- phpunit/phpunit: ^9.4
- vimeo/psalm: ^4.0
This package is auto-updated.
Last update: 2025-04-29 01:26:32 UTC
README
Read the full post in my blog: https://cuongsql.com
Installation
You can install the package via composer:
composer require cuongsql/laravel-url-uploaded-file
Usage
use Cuongsql\UrlUploadedFile\UrlUploadedFile; $file = UrlUploadedFile::createFromUrl('https://cuongsql.com/logo.png');
Now, because UrlUploadedFile
extends UploadedFile
, you can store it, get its path and extension and use UploadedFile
's functionality with it.
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Roadmap
Version 1.0 provides basic functionality only. It was extracted from a real project I was working on. The plan for version 2.0 is to extend the functionality by adding more downloaders.