Re: [lists.php] [PHP-DEV] Proposal: php://memory/<id> (& ://temp/<id>)
| From: | ALeX | Date: | Thu, 31 Jan 2013 10:12:25 +0000 |
| Subject: | Re: [lists.php] [PHP-DEV] Proposal: php://memory/<id> (& ://temp/<id>) | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-65531@lists.php.net to get a copy of this message | ||
Hi Ivan,
> php://memory/<id>
> php://temp/<id>/maxmemory:<size>
It's not that hard to write such an function in php.
(http://www.php.net/manual/en/function.stream-wrapper-register.php).
I even once wrote an handler like "string://data-right-here" which
allows to read (only) the "data-right-here" as a file. (I used it for
a function which required a file and does not support strings
directly, and instead of php://memory all data is freed when no longer
used)