PHP code example of nazar-pc / stream-slicer
1. Go to this page and download the library: Download nazar-pc/stream-slicer library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
nazar-pc / stream-slicer example snippets
$stream = fopen('very-huge-multipart.bin', 'rb');
$file = \nazarpc\Stream_slicer::slice(
$stream,
1024 * 1024 * 50,
1024 * 1024 * 1024
);