niels-nijens/protocol-stream

A library to create stream wrappers in PHP.

1.0.2 2016-04-04 12:24 UTC

README

Latest version on Packagist Software License Build Status Coverage Status SensioLabsInsight StyleCI

A library to create stream wrappers in PHP.

Installation using Composer

Run the following command to add the package to the composer.json of your project:

$ composer require niels-nijens/protocol-stream

Usage

<?php

$stream = new Stream('stream', array('domain' => '/allowed/path'));

StreamManager::create()->registerStream($stream);

readfile('stream://domain/file-in-allowed-path.ext');

Author

Also see the list of contributors who participated in this project.

License

This project licensed under the MIT License. Please see the LICENSE file for details.