library asset-proxy
Super simple asset proxy.
brianreeve/asset-proxy
Super simple asset proxy.
- Tuesday, October 6, 2015
- by brianreeve
- Repository
- 1 Watchers
- 0 Stars
- 247 Installations
- PHP
- 0 Dependents
- 0 Suggesters
- 0 Forks
- 0 Open issues
- 1 Versions
- 0 % Grown
AssetProxy
Super simple asset (image, audio, video, etc) proxy., (*1)
Usage
$loader = new \BrianReeve\AssetProxy\AssetLoader();
$asset = $loader->getAsset('/absolute/path/to/file.ext');
$asset->getMimeType();
$asset->stream();
Or use a relative path, (*2)
$loader = new \BrianReeve\AssetProxy\AssetLoader();, (*3)
$loader = new \BrianReeve\AssetProxy\AssetLoader('/base/path');
$asset = $loader->getAsset('relative/path/to/file.ext');
$asset->getMimeType();
$asset->stream();
dev-master
9999999-dev
Super simple asset proxy.
Sources
Download
The Requires
by
Brian Christopher Reeve