input / output

最后更新于:2022-04-02 02:31:33

[TOC] ## php://input ## php://output ### 实例1 ``` $fp = fopen('php://output', 'w'); fwrite($fp, "This is a test.\n"); // 等价于 echo "This is a test.\n"; ``` ### 使用 流处理对输出内容进行过滤 ``` $fp = fopen('php://output', 'w'); // 对流进行过滤 stream_filter_append($fp, 'string.toupper'); fwrite($fp, "This is a test.\n"); // THIS IS A TEST. ```
';