ntzrbtr/flysystem-http
最新稳定版本:v1.1.0
Composer 安装命令:
composer require ntzrbtr/flysystem-http
包简介
Flysystem adapter for HTTP (read-only)
README 文档
README
This adapter allows you to read files from a remote HTTP server.
Note that the adapter only supports reading files, not writing (all write operations return false or throw an exception).
Usage
You can choose whether to use the adapter based on PSR-7 (using Guzzle by default) or using pure PHP streams.
When using the PSR-7 adapter, you can directly pass a PSR-7 client to the constructor. Alternatively, you can pass a base URL and the adapter will create a Guzzle client for you.
$adapterFromUrl = \Netzarbeiter\FlysystemHttp\HttpAdapterPsr::fromUrl('http://example.com'); $client = new \GuzzleHttp\Client(['base_uri' => 'http://example.com']); $adapterFromClient = new Netzarbeiter\FlysystemHttp\HttpAdapterPsr($client);
When using the stream adapter, you can pass a base URL and a stream context (optional).
$adapter = new \Netzarbeiter\FlysystemHttp\HttpAdapterStream('http://example.com');
统计信息
- 总下载量: 30.41k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 1
- 依赖项目数: 3
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2023-10-25