Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
fopenを使わずに文字列を入力ストリームに変換する方法はありますか? 企業ポリシーにより、サーバーで fopen が許可されていないため、ちょっとショックを受けました。
私はこれを使用していました:
$string = "abcdef"; $stream = fopen('data://text/plain,' . $string,'r');
前もって感謝します
これが機能するかどうかはわかりませんが、テストしていませんが、これを行うとどうなりますか:
ob_start(); include('files/path'); $file_string = ob_get_clean();