stream_copy_to_stream

stream_copy_to_stream

(PHP 5, PHP 7)

stream_copy_to_streamCopies data from one stream to another

Description

int stream_copy_to_stream ( resource $source , resource $dest [, int $maxlength = -1 [, int $offset = 0 ]] )

Makes a copy of up to maxlength bytes of data from the current position (or from the offset position, if specified) in source to dest. If maxlength is not specified, all remaining content in source will be copied.