Save PHP variables to a text file

后端 未结 7 1572
梦如初夏
梦如初夏 2020-11-29 00:59

I was wondering how to save PHP variables to a txt file and then retrieve them again.

Example:

There is an input box, after submitted the stuff that was writ

7条回答
  •  独厮守ぢ
    2020-11-29 01:37

    Use a combination of of fopen, fwrite and fread. PHP.net has excellent documentation and examples of each of them.

    http://us2.php.net/manual/en/function.fopen.php
    http://us2.php.net/manual/en/function.fwrite.php
    http://us2.php.net/manual/en/function.fread.php

提交回复
热议问题